Parser ambiguity on "("
mrkmarron opened this issue · 0 comments
mrkmarron commented
There is an ambiguity in the expression and type parser:
(1 + 2)
and (A&B)::foo()
The current lookahead will always assume the (
corresponds to an expression and then will be confused by the following )
after the B
type.
Need to add a special case lookahead when parsing an expression to see if the (...)
is followed by a ::
. We may also want to deal with the <(...
ambiguity as well where we need to distinguish the <(T)>
case from the < (1+2)
case.