parent
e0bc267512
commit
9b2c8d866e
7 changed files with 10 additions and 6 deletions
|
|
@ -1,4 +1,5 @@
|
|||
// run-pass
|
||||
#![feature(const_type_id)]
|
||||
#![feature(core_intrinsics)]
|
||||
|
||||
use std::any::TypeId;
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@
|
|||
// will be properly rejected. This test will ensure that monomorphic use of these
|
||||
// would not be wrongly rejected in patterns.
|
||||
|
||||
#![feature(const_type_id)]
|
||||
#![feature(const_type_name)]
|
||||
|
||||
use std::any::{self, TypeId};
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@
|
|||
// This test case should either run-pass or be rejected at compile time.
|
||||
// Currently we just disallow this usage and require pattern is monomorphic.
|
||||
|
||||
#![feature(const_type_id)]
|
||||
#![feature(const_type_name)]
|
||||
|
||||
use std::any::{self, TypeId};
|
||||
|
|
|
|||
|
|
@ -1,23 +1,23 @@
|
|||
error: constant pattern depends on a generic parameter
|
||||
--> $DIR/issue-73976-polymorphic.rs:19:37
|
||||
--> $DIR/issue-73976-polymorphic.rs:20:37
|
||||
|
|
||||
LL | matches!(GetTypeId::<T>::VALUE, GetTypeId::<T>::VALUE)
|
||||
| ^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
error: constant pattern depends on a generic parameter
|
||||
--> $DIR/issue-73976-polymorphic.rs:31:42
|
||||
--> $DIR/issue-73976-polymorphic.rs:32:42
|
||||
|
|
||||
LL | matches!(GetTypeNameLen::<T>::VALUE, GetTypeNameLen::<T>::VALUE)
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
error: constant pattern depends on a generic parameter
|
||||
--> $DIR/issue-73976-polymorphic.rs:19:37
|
||||
--> $DIR/issue-73976-polymorphic.rs:20:37
|
||||
|
|
||||
LL | matches!(GetTypeId::<T>::VALUE, GetTypeId::<T>::VALUE)
|
||||
| ^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
error: constant pattern depends on a generic parameter
|
||||
--> $DIR/issue-73976-polymorphic.rs:31:42
|
||||
--> $DIR/issue-73976-polymorphic.rs:32:42
|
||||
|
|
||||
LL | matches!(GetTypeNameLen::<T>::VALUE, GetTypeNameLen::<T>::VALUE)
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue