(_declare_item): accept pragmas
Assert pragmas (and other "executable" pragmas) are specifically allowed
in declare expressions, thanks to a recent AI22-0045. They are accepted
by the latest GNAT compilers.
Regenerate grammar using tree-sitter-linux-x64-0.20.7; add test.
The existing grammar was causing simple expressions to be incorrectly
parsed as a subtype indication. This change raises the precedence for
a discrete choice expression to address that issue.
Updated the test corpus to reflect the parsing correction. Additional
test cases were added for discrete choice.
Since upstream tree-sitter hasn't been released yet (nor the node
package updated), it is cumbersome to build things. For now keep
the old regexp.
This reverts commit 99d845cd94.
Instead, package_declaration replaces it. This provides
better folding in nvim: otherwise, the final ';' was not
part of the tree node, and thus the last line "end P;" was
not folded.
This was copied from ada_mode, but results in
confusion when we have statements after the pragma
Fix allocates with if-expression, which no longer
needs double-parenthesis.