Implementation of incompatible features error

If two features are defined as incompatible, using them together would
result in an error
This commit is contained in:
Amjad Alsharafi 2020-09-04 01:47:35 +08:00
parent 08deb863bd
commit 8f2d9069a8
5 changed files with 60 additions and 1 deletions

View file

@ -0,0 +1,7 @@
#![feature(const_generics)]
//~^ ERROR features `const_generics` and `min_const_generics` are incompatible
#![allow(incomplete_features)]
#![feature(min_const_generics)]
fn main() {}

View file

@ -0,0 +1,13 @@
error: features `const_generics` and `min_const_generics` are incompatible, using them at the same time is not allowed
--> $DIR/min-and-full-same-time.rs:1:12
|
LL | #![feature(const_generics)]
| ^^^^^^^^^^^^^^
...
LL | #![feature(min_const_generics)]
| ^^^^^^^^^^^^^^^^^^
|
= help: remove one of these features
error: aborting due to previous error