first steps for the 'export' feature
This commit is contained in:
parent
c43bf78000
commit
0d19de18cc
5 changed files with 114 additions and 175 deletions
|
|
@ -1148,6 +1148,14 @@ proc gsub(g: var TSrcGen, n: PNode, c: TContext) =
|
|||
putWithSpace(g, tkImport, "import")
|
||||
gcomma(g, n, emptyContext, 1)
|
||||
putNL(g)
|
||||
of nkImportExceptStmt:
|
||||
putWithSpace(g, tkImport, "import")
|
||||
gsub(g, n.sons[0])
|
||||
put(g, tkSpaces, Space)
|
||||
putWithSpace(g, tkExcept, "except")
|
||||
gcommaAux(g, n, g.indent, 1)
|
||||
gcoms(g)
|
||||
putNL(g)
|
||||
of nkIncludeStmt:
|
||||
putWithSpace(g, tkInclude, "include")
|
||||
gcoms(g)
|
||||
|
|
@ -1155,6 +1163,13 @@ proc gsub(g: var TSrcGen, n: PNode, c: TContext) =
|
|||
gcommaAux(g, n, g.indent)
|
||||
dedent(g)
|
||||
putNL(g)
|
||||
of nkExportStmt:
|
||||
putWithSpace(g, tkExport, "export")
|
||||
gcoms(g)
|
||||
indentNL(g)
|
||||
gcommaAux(g, n, g.indent)
|
||||
dedent(g)
|
||||
putNL(g)
|
||||
of nkCommentStmt:
|
||||
gcoms(g)
|
||||
optNL(g)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue