File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -17,8 +17,8 @@ impl<T: 'static> GetTypeId<T> {
1717
1818const fn check_type_id < T : ' static > ( ) -> bool {
1919 matches ! ( GetTypeId :: <T >:: VALUE , GetTypeId :: <T >:: VALUE )
20- //~^ ERROR could not evaluate constant pattern
21- //~| ERROR could not evaluate constant pattern
20+ //~^ ERROR constant pattern depends on a generic parameter
21+ //~| ERROR constant pattern depends on a generic parameter
2222}
2323
2424pub struct GetTypeNameLen < T > ( T ) ;
@@ -29,8 +29,8 @@ impl<T: 'static> GetTypeNameLen<T> {
2929
3030const fn check_type_name_len < T : ' static > ( ) -> bool {
3131 matches ! ( GetTypeNameLen :: <T >:: VALUE , GetTypeNameLen :: <T >:: VALUE )
32- //~^ ERROR could not evaluate constant pattern
33- //~| ERROR could not evaluate constant pattern
32+ //~^ ERROR constant pattern depends on a generic parameter
33+ //~| ERROR constant pattern depends on a generic parameter
3434}
3535
3636fn main ( ) {
Original file line number Diff line number Diff line change 1- error: could not evaluate constant pattern
1+ error: constant pattern depends on a generic parameter
22 --> $DIR/issue-73976-polymorphic.rs:19:37
33 |
44LL | matches!(GetTypeId::<T>::VALUE, GetTypeId::<T>::VALUE)
55 | ^^^^^^^^^^^^^^^^^^^^^
66
7- error: could not evaluate constant pattern
7+ error: constant pattern depends on a generic parameter
88 --> $DIR/issue-73976-polymorphic.rs:31:42
99 |
1010LL | matches!(GetTypeNameLen::<T>::VALUE, GetTypeNameLen::<T>::VALUE)
1111 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
1212
13- error: could not evaluate constant pattern
13+ error: constant pattern depends on a generic parameter
1414 --> $DIR/issue-73976-polymorphic.rs:19:37
1515 |
1616LL | matches!(GetTypeId::<T>::VALUE, GetTypeId::<T>::VALUE)
1717 | ^^^^^^^^^^^^^^^^^^^^^
1818
19- error: could not evaluate constant pattern
19+ error: constant pattern depends on a generic parameter
2020 --> $DIR/issue-73976-polymorphic.rs:31:42
2121 |
2222LL | matches!(GetTypeNameLen::<T>::VALUE, GetTypeNameLen::<T>::VALUE)
You can’t perform that action at this time.
0 commit comments