-
Notifications
You must be signed in to change notification settings - Fork 467
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
:nth-of-type(2n - 1) space in argument results in error #1650
Comments
OK, this is pretty odd. :nth-of-type(2n-1),
:nth-of-type(2n- 1),
:nth-of-type(2n -1),
:nth-of-type(2n - 1),
:nth-of-type( 2n - 1 )
{ color: red; }
:nth-of-type(2n+1),
:nth-of-type(2n+ 1),
:nth-of-type(2n +1),
:nth-of-type(2n + 1),
:nth-of-type( 2n + 1 )
{ color: red; } In compressed mode this produces: :nth-of-type(2n-1),
:nth-of-type(2n- 1),
:nth-of-type(2n -1),
:nth-of-type(2n - 1),
:nth-of-type(2n - 1)
{color:red}
:nth-of-type(2n+1),
:nth-of-type(2n+1),
:nth-of-type(2n+1),
:nth-of-type(2n+1),
:nth-of-type(2n+1)
{color:red} My current fix which gets it parsed correctly outputs: :nth-of-type(2n-1),
:nth-of-type(2n-1),
:nth-of-type(2n-1),
:nth-of-type(2n-1),
:nth-of-type(2n-1)
{color:red}
:nth-of-type(2n+1),
:nth-of-type(2n+1),
:nth-of-type(2n+1),
:nth-of-type(2n+1),
:nth-of-type(2n+1)
{color:red} No idea why ruby sass does not apply the same logic here. Looks like a bug to me ... |
The white space being preserved looks like the work of a static value parser. |
Looks like Ruby Sass' |
That's a ruby bug, not a high priority one, but definitely a bug. |
@chriseppstein thanks for the confirmation, I guess it's a one byte fix on the ruby side ... |
This should be fixed on master for release 3.3.3. |
Updated to new libsass/node-sass recently and noticed regression (or intended?) with the code:
outputs an error
While code with no spaces works:
spacing around minus sign makes libsass complain.
The text was updated successfully, but these errors were encountered: