File tree 1 file changed +12
-2
lines changed
1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -8,11 +8,22 @@ Language
8
8
9
9
** Syntax only changes**
10
10
- [ Allow ` type Foo: Ord ` syntactically.] [ 69361 ]
11
- - [ Unify item parsing & filter illegal item kinds.] [ 69366 ]
12
11
- [ Fuse associated and extern items up to defaultness.] [ 69194 ]
13
12
- [ Permit attributes on ` if ` expressions.] [ 69201 ]
14
13
- [ Syntactically allow ` self ` in all ` fn ` contexts.] [ 68764 ]
15
14
- [ Merge ` fn ` syntax + cleanup item parsing.] [ 68728 ]
15
+ - [ ` item ` macro fragments can be interpolated into ` trait ` s, ` impl ` s, and ` extern ` blocks.] [ 69366 ]
16
+ For example, you may now write:
17
+ ``` rust
18
+ macro_rules! mac_trait {
19
+ ($ i : item ) => {
20
+ trait T { $ i }
21
+ }
22
+ }
23
+ mac_trait! {
24
+ fn foo () {}
25
+ }
26
+ ```
16
27
17
28
These are still rejected * semantically* , so you will likely receive an error but
18
29
these changes can be seen and parsed by macros and
@@ -79,7 +90,6 @@ Compatibility Notes
79
90
has been a warning since 1.36.0.
80
91
- [ Fixed ` Self ` not having the correctly inferred type.] [ 69340 ] This incorrectly
81
92
led to some instances being accepted, and now correctly emits a hard error.
82
- - [ ] [ ]
83
93
84
94
[ 69340 ] : https://github.com/rust-lang/rust/pull/69340
85
95
You can’t perform that action at this time.
0 commit comments