@@ -190,7 +190,7 @@ with any other legal whitespace element, such as a single space character.
190
190
## Tokens
191
191
192
192
~~~~~~~~ {.ebnf .gram}
193
- simple_token : keyword | reserved | unop | binop ;
193
+ simple_token : keyword | reserved | unop | binop ;
194
194
token : simple_token | ident | literal | symbol | whitespace token ;
195
195
~~~~~~~~
196
196
@@ -511,7 +511,7 @@ from the source file name, with the `.rs` extension removed.
511
511
## Crate files
512
512
513
513
~~~~~~~~ {.ebnf .gram}
514
- crate : attribute [ ';' | attribute* directive ]
514
+ crate : attribute [ ';' | attribute* directive ]
515
515
| directive ;
516
516
directive : view_item | dir_directive | source_directive ;
517
517
~~~~~~~~
@@ -730,7 +730,7 @@ independently declared with [`use` declarations](#use-declarations).
730
730
731
731
Imports support a number of "convenience" notations:
732
732
733
- * Importing as a different name than the imported name, using the
733
+ * Importing as a different name than the imported name, using the
734
734
syntax ` import x = p::q::r; ` .
735
735
* Importing a list of paths differing only in final element, using
736
736
the glob-like brace syntax ` import a::b::{c,d,e,f}; `
@@ -1153,7 +1153,7 @@ An _implementation item_ provides an implementation of an
1153
1153
1154
1154
~~~~
1155
1155
type circle = {radius: float, center: point};
1156
-
1156
+
1157
1157
impl circle_shape of shape for circle {
1158
1158
fn draw(s: surface) { do_draw_circle(s, self); }
1159
1159
fn bounding_box() -> bounding_box {
@@ -1313,7 +1313,7 @@ declaring a function-local item.
1313
1313
1314
1314
~~~~~~~~ {.ebnf .gram}
1315
1315
let_decl : "let" pat [':' type ] ? [ init ] ? ';' ;
1316
- init : [ '=' | '<-' ] expr ;
1316
+ init : [ '=' | '<-' ] expr ;
1317
1317
~~~~~~~~
1318
1318
1319
1319
@@ -1941,7 +1941,7 @@ for e: foo in v {
1941
1941
~~~~~~~~ {.ebnf .gram}
1942
1942
if_expr : "if" expr '{' block '}'
1943
1943
[ "else" else_tail ] ? ;
1944
-
1944
+
1945
1945
else_tail : "else" [ if_expr
1946
1946
| '{' block '} ] ;
1947
1947
~~~~~~~~
@@ -2331,11 +2331,11 @@ introduced inline in source code using the `macro` extension, may be used. The
2331
2331
current built-in syntax extensions are:
2332
2332
2333
2333
2334
- * ` fmt ` expands into code to produce a formatted string, similar to
2334
+ * ` fmt ` expands into code to produce a formatted string, similar to
2335
2335
` printf ` from C.
2336
2336
* ` env ` expands into a string literal containing the value of that
2337
2337
environment variable at compile-time.
2338
- * ` concat_idents ` expands into an identifier which is the
2338
+ * ` concat_idents ` expands into an identifier which is the
2339
2339
concatenation of its arguments.
2340
2340
* ` ident_to_str ` expands into a string literal containing the name of
2341
2341
its argument (which must be a literal).
@@ -2750,7 +2750,7 @@ A _constraint_ is a predicate applied to specific slots.
2750
2750
For example, consider the following code:
2751
2751
2752
2752
~~~~~~~~
2753
- pure fn is_less_than(int a, int b ) -> bool {
2753
+ pure fn is_less_than(a: int, b: int ) -> bool {
2754
2754
ret a < b;
2755
2755
}
2756
2756
0 commit comments