It appears that Expr represents a binary expression used in a condition, and in the Cast node, it seems more appropriate to use ExpressionValue instead of Expr.
I dump the AST and found that the expr in the Cast node is indeed ExpressionValue not Expr:
It appears that
Expr
represents a binary expression used in a condition, and in theCast
node, it seems more appropriate to useExpressionValue
instead ofExpr
.I dump the AST and found that the
expr
in theCast
node is indeedExpressionValue
notExpr
: