Function references conflict with a few things. It seems like this is already
known for the most part, since there are already rules for type specifiers and
expressions (including with type specifiers and themselves). I have simply
modified this conflict to include function pointers.
There is a genuine ambiguity that this introduces between function calls and
calls to function references. These are semantically identical, so I'm not that
worried about it, and in order to make existing tests pass I have lowered the
precedence for function pointers so that they will only parse if function calls
(and other expressions) do not.
Fixes #35
Requirements (place an x in each [ ])
[x] I've added tests for any new code and ran npm run test-corpus to make sure all tests pass.
[x] I've read and understood the Contributing Guidelines and have done my best effort to follow them.
Function references conflict with a few things. It seems like this is already known for the most part, since there are already rules for type specifiers and expressions (including with type specifiers and themselves). I have simply modified this conflict to include function pointers.
There is a genuine ambiguity that this introduces between function calls and calls to function references. These are semantically identical, so I'm not that worried about it, and in order to make existing tests pass I have lowered the precedence for function pointers so that they will only parse if function calls (and other expressions) do not.
Fixes #35
Requirements (place an
x
in each[ ]
)npm run test-corpus
to make sure all tests pass.