You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit contains a few syntax/parsing changes:
1) Old head :- body rule syntax is no longer supported. All rules must
be declared as: head { body } now.
2) Semicolon has replaced comma as the conjunction operator. This avoids
the ambiguity between set literals and curly-brace enclosed bodies.
3) ast.ParseBody will concatenate bodies that it receives from the
parser. This way, callers can invoke ast.ParseBody without enclosing
multiple expressions in braces.
4) Trailing commas are allowed in sets, arrays, and objects. To declare
a set of size one a trailing comma must be used, e.g., {foo,} =>
set(foo) where as {foo} => body(expr(foo)).
The following commit will update all of the existing test cases to bring
them into compliance with the new syntax.
Fixesopen-policy-agent#253
The new syntax allows for brace-enclosed bodies to separate expressions with newlines.
Is equivalent to
p[x], q[x]
.Currently, the grammar only allows brace-enclosed bodies for rules. They are not supported on their own:
Build info:
The text was updated successfully, but these errors were encountered: