Add comment, potentially fix linux test
This commit is contained in:
parent
0ff18278f0
commit
baaba7881b
2 changed files with 12 additions and 1 deletions
|
|
@ -106,7 +106,7 @@ proc newConstDef(gState: State, node: TSNode, fname = "", fval = ""): PNode =
|
|||
if not maybeTyNode.isNil:
|
||||
let name = maybeTyNode.getName()
|
||||
case name
|
||||
of "type_descriptor", "sized_type_specifier":
|
||||
of "type_descriptor", "sized_type_specifier", "primitive_type":
|
||||
discard
|
||||
else:
|
||||
# Can't do gState.parseCExpression(root) here for some reason?
|
||||
|
|
|
|||
|
|
@ -549,6 +549,17 @@ proc processTSNode(gState: State, node: TSNode, typeofNode: var PNode): PNode =
|
|||
# Output -> true, false
|
||||
result = gState.parseString(node.val)
|
||||
of "type_descriptor":
|
||||
# Input => int*
|
||||
# (type_descriptor 1 2 4 "int*"
|
||||
# (type_identifier 1 2 3 "int")
|
||||
# (abstract_pointer_declarator 1 3 1 "*")
|
||||
# )
|
||||
#
|
||||
# Output => ptr int
|
||||
#
|
||||
# nkPtrTy(
|
||||
# nkIdent("int")
|
||||
# )
|
||||
let pointerDecl = node.anyChildInTree("abstract_pointer_declarator")
|
||||
|
||||
if pointerDecl.isNil:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue