Skip to content
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

Single quotes in comments break compilation #14

Open
Anaphase opened this issue Jun 1, 2016 · 1 comment
Open

Single quotes in comments break compilation #14

Anaphase opened this issue Jun 1, 2016 · 1 comment

Comments

@Anaphase
Copy link
Contributor

Anaphase commented Jun 1, 2016

For some reason single quotes in comments break compilation. For example:

div
  // this is a valid comment
  p 'This is a paragraph.'

compiles fine, but this doesn't:

div
  // this isn't a valid comment
  p 'This is a paragraph.'

It returns this error:
SyntaxError: SIML: Line 2, column 3: Expected "(", ":", "[", "}", AttributeName, Directive, HTML, String, [#.], [\r\n\t ], [a-z0-9_\-]i or [a-zA-Z_$] but "/" found.

I took a look through the source and I think the issue is caused by having the string tokens replaced before the comments are removed. Would it brealk anything to move the comment removal before the string tokens are replaced?

@chronologicaldot
Copy link

Same issue happens with double-quotes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants