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

Interpolation closing brace is not tokenized #20

Closed
mouhannad-sh opened this issue Dec 2, 2018 · 2 comments
Closed

Interpolation closing brace is not tokenized #20

mouhannad-sh opened this issue Dec 2, 2018 · 2 comments
Assignees
Labels

Comments

@mouhannad-sh
Copy link

Hi I've tried the following example:

tokenize(' #{$var +20} 10')

the output is

[ [ 'space', ' ' ],
  [ 'startInterpolant', '#{', 1, 3 ],
  [ '$', '$', 1, 4 ],
  [ 'ident', 'var', 1, 5, 1, 7 ],
  [ 'space', ' ' ],
  [ '+', '+', 1, 9 ],
  [ 'number', '20', 1, 10, 1, 11 ], // closing brace should be after this
  [ 'space', ' ' ],
  [ 'number', '10', 1, 14, 1, 15 ] ]

as you can see there's a startInterpolant token but the output doesn't indicate anything about the the closing brace.

Am I missing anything ? is there a different way to handle this syntax #{ } ?

Thanks

@xzyfer
Copy link
Member

xzyfer commented Dec 2, 2018 via email

xzyfer added a commit that referenced this issue Dec 3, 2018
xzyfer added a commit that referenced this issue Dec 3, 2018
@xzyfer xzyfer closed this as completed in #21 Dec 3, 2018
xzyfer added a commit that referenced this issue Dec 3, 2018
@xzyfer
Copy link
Member

xzyfer commented Dec 3, 2018

Fixed in 0.4.0

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

No branches or pull requests

2 participants