Skip to content

Commit c5c4a63

Browse files
committed
insert space
in the rust grammar to avoid error messages like this: Exception: non-alpha apparent keyword: pub" when using extract_grammar.py: python2.7 src/etc/extract_grammar.py <doc/rust.md Signed-off-by: Jan Kobler <[email protected]>
1 parent 87761c1 commit c5c4a63

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

doc/rust.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -788,7 +788,7 @@ extern mod complicated_mod = "some-file/in/the-rust/path";
788788
##### Use declarations
789789

790790
~~~~~~~~ {.ebnf .gram}
791-
use_decl : "pub"? "use" ident [ '=' path
791+
use_decl : "pub" ? "use" ident [ '=' path
792792
| "::" path_glob ] ;
793793
794794
path_glob : ident [ "::" path_glob ] ?
@@ -1920,7 +1920,7 @@ it is automatically derferenced to make the field access possible.
19201920
### Vector expressions
19211921

19221922
~~~~~~~~{.ebnf .gram}
1923-
vec_expr : '[' "mut"? vec_elems? ']'
1923+
vec_expr : '[' "mut" ? vec_elems? ']'
19241924
19251925
vec_elems : [expr [',' expr]*] | [expr ',' ".." expr]
19261926
~~~~~~~~

0 commit comments

Comments
 (0)