Commit Graph

30 Commits

Author SHA1 Message Date
gluax
11c78da916 formatted string -> renamed format string 2021-04-14 16:15:27 -04:00
gluax
91634d6479 implicit input, removed from function input 2021-04-14 16:00:19 -04:00
Alessandro Coglio
f26114afa5 [ABNF] Make ** right-associative.
As agreed on Slack.
2021-04-09 13:01:59 -07:00
Alessandro Coglio
f19af30f0e [ABNF] Fix rule for affine group literals.
This was

affine-group-literal = "(" group-coordinate "," group-coordinate ")" %s"group"

instead of

affine-group-literal = "(" group-coordinate "," group-coordinate %s")group"

(note the different ending).

This change should have been part of the PR for whitespace in group literals,
but apparently I failed to do that, along with the other changes.

This commit rectifies that omission.
2021-04-06 16:39:07 -07:00
Alessandro Coglio
7da8a3c033 [ABNF] Improve consistency of documentation. 2021-04-06 16:37:18 -07:00
Alessandro Coglio
5f85308444 [ABNF] Improve the syntactic grammar section documentation.
Update some comments that were now out of date.

Clarify some text.

Fix some typos.
2021-04-06 16:35:47 -07:00
Alessandro Coglio
f0bac48093 [ABNF] Improve lexical grammar documentation.
Fix some typos, clarify some text, remove/update some obsolete references.
2021-04-06 16:03:28 -07:00
Alessandro Coglio
e035743f96 [ABNF] Improve naming convention section of documentation.
Some tweaks and some clarifications.
2021-04-06 15:19:41 -07:00
Alessandro Coglio
fdaab572f9 [ABNF] Improve operator precedence section of documentation.
Fix a typo. Tweak some text layout.
2021-04-06 15:14:08 -07:00
Alessandro Coglio
11c0d60021 [ABNF] Improve structure section of documentation.
Make this more concise and clear by just presenting the lexical and syntactic
grammar as the way we define the Leo syntax, as opposed to discussing
alternatives like PEGs.
2021-04-06 14:59:52 -07:00
Alessandro Coglio
c7fb2905c0 [ABNF] Improve background section of documentation.
Explicate references to RFCs a bit.

Use the term 'sequence of terminals' instead of 'string' to avoid any confusion.

(Still use 'string' to refer to the actual strings in double quotes that are
part of the ABNF notation itself.)
2021-04-06 14:45:23 -07:00
Alessandro Coglio
742e3b33ea [ABNF] Improve introduction section of documentation.
Update to say that grammar is no longer just a draft.

Put primary motivation and purpose of grammar first.

Mention use in formalization second, and slightly simplify that part, given that
the formalization is not public yet.
2021-04-06 14:43:55 -07:00
Alessandro Coglio
48635e5dbe [ABNF] Fix typos in documentation. 2021-04-06 14:22:15 -07:00
Alessandro Coglio
880f2cd200 [ABNF] Remove explicit author info, as discussed. 2021-04-05 21:55:19 -07:00
Alessandro Coglio
797e8ceffd [ABNF] Tweak some layout.
Just for consistency with the rest of the file.
2021-04-05 21:54:18 -07:00
Alessandro Coglio
c0ea8798a2 [ABNF] Remove leftover reference.
This was uncovered by running the grammar through the ACL2 build: among other
things, the build checks that every nonterminal referenced in the right side of
each rule has a definition in the grammar.
2021-04-05 21:47:28 -07:00
Alessandro Coglio
5f875a4e93 [ABNF] Allow const self.
This still needed to be updated. The rules only supported self and mut self.
2021-04-05 21:27:37 -07:00
Alessandro Coglio
b535a5fde3 [ABNF] Allow spaces in affine group literals. 2021-04-05 13:55:05 -07:00
gluax
f9d8f48577 clean up last bit of leftover access 2021-03-25 16:24:01 -04:00
gluax
001056f8bd rename-access expression rule and parse function to postfix 2021-03-25 14:34:16 -04:00
gluax
3571fa2080 I think this is the best way to handle access_expressions in ABNF to reflect the parser 2021-03-24 15:25:56 -04:00
gluax
5ed7582b22 tentative parse expression grammar rule 2021-03-24 13:54:53 -04:00
gluax
5ae7771050 cast-expression in abnf 2021-03-24 13:38:45 -04:00
gluax
f71d77762c comment out bitwise, mod, &&= and ||= for now 2021-03-24 13:28:01 -04:00
gluax
e0200ff789 tentative cast-expression abnf rule, refactor fuzzy rule to conditional expression 2021-03-24 12:33:52 -04:00
gluax
600cf120f9 idents in annotation name and for arguements, no white space between @ and annotation-name 2021-03-24 12:08:07 -04:00
gluax
fd52192d58 _ token in parser and symbol in abnf 2021-03-24 11:40:26 -04:00
gluax
0663227741 order tokens to try and match ABNF 2021-03-23 13:45:57 -04:00
gluax
1adc8cee14 consistent keyword order and names 2021-03-23 12:11:42 -04:00
gluax
dde8ab59fa initial commit, so I can open retroactive pr 2021-03-22 14:38:38 -04:00