solidity-parser-antlr icon indicating copy to clipboard operation
solidity-parser-antlr copied to clipboard

type: ASTNode types have incorrect optional properties

Open yxliang01 opened this issue 5 years ago • 2 comments

There are some properties of ASTNode types declared as optional via adding ? to ``PROPERTY_NAME (PROPERTY_NAME?). However, marking optional in this way results in saying such property having value TYPE | undefined | nullwhile they are in fact of typeTYPE | null` (or correct me if wrong). e.g. https://github.com/federicobond/solidity-parser-antlr/blob/f0ef77034c467c06c383b621aa305093af3a0621/index.d.ts#L201

CC: @Leeleo3x

yxliang01 avatar May 07 '19 15:05 yxliang01

It is true. Will this introduce any side effect?

aoli-al avatar May 10 '19 09:05 aoli-al

I see. Side effect as in? @Leeleo3x

yxliang01 avatar May 10 '19 14:05 yxliang01