Skip to content

Interpolation closing brace is not tokenized  #20

Closed
@mouhannad-sh

Description

@mouhannad-sh

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

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions