After some discussion we decided to make a quasi-quote look like
[pads| ...blah... |]
rather than
[$pads| ...blah... |]
as before. The new syntax is quieter, although it does not signal
quite as clearly that there is a splice going on.
\$ @varid / { ifExtension thEnabled } { skip_one_varid ITidEscape }
"$(" / { ifExtension thEnabled } { token ITparenEscape }
\$ @varid / { ifExtension thEnabled } { skip_one_varid ITidEscape }
"$(" / { ifExtension thEnabled } { token ITparenEscape }
- "[$" @varid "|" / { ifExtension qqEnabled }
+ "[" @varid "|" / { ifExtension qqEnabled }
lex_quasiquote_tok :: Action
lex_quasiquote_tok span buf len = do
lex_quasiquote_tok :: Action
lex_quasiquote_tok span buf len = do
- let quoter = reverse $ takeWhile (/= '$')
- $ reverse $ lexemeToString buf (len - 1)
+ let quoter = tail (lexemeToString buf (len - 1))
+ -- 'tail' drops the initial '[',
+ -- while the -1 drops the trailing '|'
quoteStart <- getSrcLoc
quote <- lex_quasiquote ""
end <- getSrcLoc
quoteStart <- getSrcLoc
quote <- lex_quasiquote ""
end <- getSrcLoc