added the 'x.p[:T]' notation for explicit generic instantiations in combination with the ddot calling syntax
This commit is contained in:
parent
651c0e45da
commit
212fdc5946
9 changed files with 81 additions and 53 deletions
|
|
@ -60,7 +60,7 @@ type
|
|||
tkCurlyDotLe, tkCurlyDotRi, # {. and .}
|
||||
tkParDotLe, tkParDotRi, # (. and .)
|
||||
tkComma, tkSemiColon,
|
||||
tkColon, tkColonColon, tkEquals, tkDot, tkDotDot,
|
||||
tkColon, tkColonColon, tkEquals, tkDot, tkDotDot, tkBracketLeColon,
|
||||
tkOpr, tkComment, tkAccent,
|
||||
tkSpaces, tkInfixOpr, tkPrefixOpr, tkPostfixOpr
|
||||
|
||||
|
|
@ -98,7 +98,7 @@ const
|
|||
"tkTripleStrLit", "tkGStrLit", "tkGTripleStrLit", "tkCharLit", "(",
|
||||
")", "[", "]", "{", "}", "[.", ".]", "{.", ".}", "(.", ".)",
|
||||
",", ";",
|
||||
":", "::", "=", ".", "..",
|
||||
":", "::", "=", ".", "..", "[:",
|
||||
"tkOpr", "tkComment", "`",
|
||||
"tkSpaces", "tkInfixOpr",
|
||||
"tkPrefixOpr", "tkPostfixOpr"]
|
||||
|
|
@ -1119,6 +1119,9 @@ proc rawGetTok*(L: var TLexer, tok: var TToken) =
|
|||
if L.buf[L.bufpos] == '.' and L.buf[L.bufpos+1] != '.':
|
||||
tok.tokType = tkBracketDotLe
|
||||
inc(L.bufpos)
|
||||
elif L.buf[L.bufpos] == ':':
|
||||
tok.tokType = tkBracketLeColon
|
||||
inc(L.bufpos)
|
||||
else:
|
||||
tok.tokType = tkBracketLe
|
||||
of ']':
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue