| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Changed: The []= operator for strings and sequences is now capable of splicing
|
|
|
|
|
|
|
|
| |
Added: PNimrodNode.lineinfo for better error messages from macros
Added: seq.splice
For easier use from templates and macros, except stament now supports
the list of exception types to be supplied in nkBraket node (array literal).
|
| |
|
|
|
|
| |
evaluation
|
|
|
|
| |
optimized; tstringinterp.nim now works
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Added string interpolation helper routines in parserutils
Added a proof-of-concept string interpolation user-land macros (currently, only as a test case):
the interpolated expression could either be transformed to
concat("literal string ", $(interpolated), " end") or
"literal string $1 end" % [$(interpolated)]
Added a very initial definition of Optional[T] generic type
A new overload of ParseIdent was added in hope to get around the fact that the
old one doesn't work correctly in macros, but the problem persists.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
proc parseExpr*(s: string) : expr {.magic: "ParseExprToAst".}
## Compiles the passed string to its AST representation
## Expects a single expression
proc parseStmt*(s: string) : stmt {.magic: "ParseStmtToAst".}
## Compiles the passed string to its AST representation
## Expects one or more statements
proc getAst*(macroOrTemplate: expr): expr {.magic: "ExpandMacroToAst".}
## Obtains the AST nodes returned from a macro or template invocation
## example:
## macro FooMacro() =
## var ast = getAst(BarTemplate())
Handling of the node.toYaml magic moved to the evaluation engine.
|
| |
|
| |
|
|
|
|
| |
generated C code)
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|