improved support for typedesc values
* can be stored in constants and variables (including in containers like sequences) * can be passed to and returned from macros
This commit is contained in:
parent
92b0d64018
commit
badb6c0f66
11 changed files with 90 additions and 79 deletions
|
|
@ -163,6 +163,7 @@ proc genConstStmt(p: BProc, t: PNode) =
|
|||
if it.kind == nkCommentStmt: continue
|
||||
if it.kind != nkConstDef: InternalError(t.info, "genConstStmt")
|
||||
var c = it.sons[0].sym
|
||||
if c.typ.containsCompileTimeOnly: continue
|
||||
if sfFakeConst in c.flags:
|
||||
genSingleVar(p, it)
|
||||
elif c.typ.kind in ConstantDataTypes and lfNoDecl notin c.loc.flags and
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue