File tree Expand file tree Collapse file tree 2 files changed +25
-4
lines changed Expand file tree Collapse file tree 2 files changed +25
-4
lines changed Original file line number Diff line number Diff line change @@ -526,7 +526,6 @@ module.exports = grammar({
526
526
$ . _type ,
527
527
$ . lifetime ,
528
528
$ . higher_ranked_trait_bound ,
529
- $ . removed_trait_bound ,
530
529
) ) ,
531
530
) ,
532
531
@@ -711,6 +710,7 @@ module.exports = grammar({
711
710
$ . never_type ,
712
711
$ . dynamic_type ,
713
712
$ . bounded_type ,
713
+ $ . removed_trait_bound ,
714
714
alias ( choice ( ...primitiveTypes ) , $ . primitive_type ) ,
715
715
) ,
716
716
@@ -851,6 +851,7 @@ module.exports = grammar({
851
851
field ( 'trait' , choice (
852
852
$ . _type_identifier ,
853
853
$ . scoped_type_identifier ,
854
+ $ . removed_trait_bound ,
854
855
$ . generic_type ,
855
856
$ . function_type ,
856
857
) ) ,
Original file line number Diff line number Diff line change @@ -269,8 +269,7 @@ fn triples(a: impl B) -> impl Iterator<Item=(usize)> {
269
269
Diverging functions
270
270
================================================================================
271
271
272
- fn aborts() -> ! {
273
- }
272
+ fn aborts() -> ! {}
274
273
275
274
--------------------------------------------------------------------------------
276
275
@@ -1634,6 +1633,8 @@ Unsized types in trait bounds
1634
1633
trait Foo<T: ?Sized> {
1635
1634
}
1636
1635
1636
+ fn univariant(this: &impl ?Sized, that: &(impl LayoutCalculator + ?Sized)) {}
1637
+
1637
1638
--------------------------------------------------------------------------------
1638
1639
1639
1640
(source_file
@@ -1645,7 +1646,26 @@ trait Foo<T: ?Sized> {
1645
1646
(trait_bounds
1646
1647
(removed_trait_bound
1647
1648
(type_identifier)))))
1648
- (declaration_list)))
1649
+ (declaration_list))
1650
+ (function_item
1651
+ (identifier)
1652
+ (parameters
1653
+ (parameter
1654
+ (identifier)
1655
+ (reference_type
1656
+ (abstract_type
1657
+ (removed_trait_bound
1658
+ (type_identifier)))))
1659
+ (parameter
1660
+ (identifier)
1661
+ (reference_type
1662
+ (tuple_type
1663
+ (bounded_type
1664
+ (abstract_type
1665
+ (type_identifier))
1666
+ (removed_trait_bound
1667
+ (type_identifier)))))))
1668
+ (block)))
1649
1669
1650
1670
================================================================================
1651
1671
Macro invocations inside trait declarations
You can’t perform that action at this time.
0 commit comments