Skip to content

Commit dcd44c3

Browse files
committed
---
yaml --- r: 209970 b: refs/heads/try c: 72ee472 h: refs/heads/master v: v3
1 parent 23cc2c6 commit dcd44c3

File tree

141 files changed

+2214
-1678
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

141 files changed

+2214
-1678
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
refs/heads/master: 3e561f05c00cd180ec02db4ccab2840a4aba93d2
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: ba0e1cd8147d452c356aacb29fb87568ca26f111
5-
refs/heads/try: 84ef3b53517e2ed1148e6d4214c0c97c2328ead0
5+
refs/heads/try: 72ee472146681d2a87e9bdce8024da309828dafd
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d
88
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596

branches/try/configure

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -659,9 +659,10 @@ if [ -n "$CFG_ENABLE_DEBUG" ]; then
659659
CFG_DISABLE_OPTIMIZE=1
660660
CFG_DISABLE_OPTIMIZE_CXX=1
661661
fi
662-
CFG_ENABLE_LLVM_ASSERTIONS=1
663662
CFG_ENABLE_DEBUG_ASSERTIONS=1
664663
CFG_ENABLE_DEBUG_JEMALLOC=1
664+
CFG_ENABLE_DEBUGINFO=1
665+
CFG_ENABLE_LLVM_ASSERTIONS=1
665666
fi
666667

667668
# OK, now write the debugging options

branches/try/src/doc/grammar.md

Lines changed: 31 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -96,12 +96,16 @@ explicit codepoint lists. [^inputformat]
9696
## Special Unicode Productions
9797

9898
The following productions in the Rust grammar are defined in terms of Unicode
99-
properties: `ident`, `non_null`, `non_star`, `non_eol`, `non_slash_or_star`,
100-
`non_single_quote` and `non_double_quote`.
99+
properties: `ident`, `non_null`, `non_eol`, `non_single_quote` and
100+
`non_double_quote`.
101101

102102
### Identifiers
103103

104-
The `ident` production is any nonempty Unicode string of the following form:
104+
The `ident` production is any nonempty Unicode[^non_ascii_idents] string of
105+
the following form:
106+
107+
[^non_ascii_idents]: Non-ASCII characters in identifiers are currently feature
108+
gated. This is expected to improve soon.
105109

106110
- The first character has property `XID_start`
107111
- The remaining characters have property `XID_continue`
@@ -118,8 +122,6 @@ Some productions are defined by exclusion of particular Unicode characters:
118122

119123
- `non_null` is any single Unicode character aside from `U+0000` (null)
120124
- `non_eol` is `non_null` restricted to exclude `U+000A` (`'\n'`)
121-
- `non_star` is `non_null` restricted to exclude `U+002A` (`*`)
122-
- `non_slash_or_star` is `non_null` restricted to exclude `U+002F` (`/`) and `U+002A` (`*`)
123125
- `non_single_quote` is `non_null` restricted to exclude `U+0027` (`'`)
124126
- `non_double_quote` is `non_null` restricted to exclude `U+0022` (`"`)
125127

@@ -152,19 +154,19 @@ token : simple_token | ident | literal | symbol | whitespace token ;
152154

153155
<p id="keyword-table-marker"></p>
154156

155-
| | | | | |
156-
|----------|----------|----------|----------|--------|
157-
| abstract | alignof | as | become | box |
158-
| break | const | continue | crate | do |
159-
| else | enum | extern | false | final |
160-
| fn | for | if | impl | in |
161-
| let | loop | match | mod | move |
162-
| mut | offsetof | once | override | priv |
163-
| proc | pub | pure | ref | return |
164-
| sizeof | static | self | struct | super |
165-
| true | trait | type | typeof | unsafe |
166-
| unsized | use | virtual | where | while |
167-
| yield | | | | |
157+
| | | | | |
158+
|----------|----------|----------|----------|---------|
159+
| abstract | alignof | as | become | box |
160+
| break | const | continue | crate | do |
161+
| else | enum | extern | false | final |
162+
| fn | for | if | impl | in |
163+
| let | loop | macro | match | mod |
164+
| move | mut | offsetof | override | priv |
165+
| proc | pub | pure | ref | return |
166+
| Self | self | sizeof | static | struct |
167+
| super | trait | true | type | typeof |
168+
| unsafe | unsized | use | virtual | where |
169+
| while | yield | | | |
168170

169171

170172
Each of these keywords has special meaning in its grammar, and all of them are
@@ -524,6 +526,15 @@ array_elems : [expr [',' expr]*] | [expr ',' ".." expr] ;
524526
idx_expr : expr '[' expr ']' ;
525527
```
526528

529+
### Range expressions
530+
531+
```antlr
532+
range_expr : expr ".." expr |
533+
expr ".." |
534+
".." expr |
535+
".." ;
536+
```
537+
527538
### Unary operator expressions
528539

529540
**FIXME:** grammar?
@@ -610,7 +621,7 @@ lambda_expr : '|' ident_list '|' expr ;
610621
### While loops
611622

612623
```antlr
613-
while_expr : "while" no_struct_literal_expr '{' block '}' ;
624+
while_expr : [ lifetime ':' ] "while" no_struct_literal_expr '{' block '}' ;
614625
```
615626

616627
### Infinite loops
@@ -634,7 +645,7 @@ continue_expr : "continue" [ lifetime ];
634645
### For expressions
635646

636647
```antlr
637-
for_expr : "for" pat "in" no_struct_literal_expr '{' block '}' ;
648+
for_expr : [ lifetime ':' ] "for" pat "in" no_struct_literal_expr '{' block '}' ;
638649
```
639650

640651
### If expressions

0 commit comments

Comments
 (0)