wellington / sass

Pure Go sass lexer, parser, and compiler
http://getwt.io
Other
79 stars 5 forks source link

interpolation #14

Closed drewwells closed 8 years ago

drewwells commented 8 years ago

currently interpolations are eaten as a whole #{3 + 11} is one token. Instead, these should be treated as paran statements that require resolution. In addition, interpolations can appear anywhere, so it will need to be taken in account across all areas where syntactic analysis occurs.

drewwells commented 8 years ago

We may need to transition to a multi-pass parser to make this work. Syntax analysis will fail with interpolation gunking up the tokens, so all interpolations should be expanded and resolved prior to analysis.

drewwells commented 8 years ago

Interpolation is supported in lhs/rhs and selectors. It also supports selector merging.