Make effects an incomplete feature

This commit is contained in:
Deadbeef 2024-06-21 12:22:29 +00:00
parent a6a83d3d4e
commit 81da6a6d40
123 changed files with 774 additions and 111 deletions

View File

@ -449,7 +449,7 @@ declare_features! (
/// Allows `dyn* Trait` objects.
(incomplete, dyn_star, "1.65.0", Some(102425)),
/// Uses generic effect parameters for ~const bounds
(unstable, effects, "1.72.0", Some(102090)),
(incomplete, effects, "1.72.0", Some(102090)),
/// Allows exhaustive pattern matching on types that contain uninhabited types.
(unstable, exhaustive_patterns, "1.13.0", Some(51085)),
/// Allows explicit tail calls via `become` expression.

View File

@ -18,7 +18,7 @@ All intrinsic fallback bodies are automatically made cross-crate inlineable (lik
by the codegen backend, but not the MIR inliner.
```rust
#![feature(rustc_attrs, effects)]
#![feature(rustc_attrs)]
#![allow(internal_features)]
#[rustc_intrinsic]
@ -28,7 +28,7 @@ const unsafe fn const_deallocate(_ptr: *mut u8, _size: usize, _align: usize) {}
Since these are just regular functions, it is perfectly ok to create the intrinsic twice:
```rust
#![feature(rustc_attrs, effects)]
#![feature(rustc_attrs)]
#![allow(internal_features)]
#[rustc_intrinsic]

View File

@ -1,4 +1,4 @@
#![feature(rustc_attrs, effects)]
#![feature(rustc_attrs)]
#[rustc_intrinsic]
#[rustc_nounwind]

View File

@ -2,6 +2,7 @@
#![crate_name = "foo"]
#![feature(effects, const_trait_impl)]
#![allow(incomplete_features)]
#[const_trait]
pub trait Tr {

View File

@ -1,5 +1,6 @@
#![crate_name = "foo"]
#![feature(effects)]
#![allow(incomplete_features)]
// @has foo/fn.bar.html
// @has - '//pre[@class="rust item-decl"]' 'pub const fn bar() -> '

View File

@ -7,6 +7,7 @@
// not remove this test.
//
// FIXME(effects) add `const_trait` to `Fn` so we use `~const`
// FIXME(effects) restore `const_trait` to `Destruct`
#![feature(const_trait_impl)]
#![crate_name = "foo"]
@ -24,9 +25,9 @@ pub trait Tr<T> {
// @has - '//section[@id="method.a"]/h4[@class="code-header"]/a[@class="trait"]' 'Fn'
// @!has - '//section[@id="method.a"]/h4[@class="code-header"]/span[@class="where"]' '~const'
// @has - '//section[@id="method.a"]/h4[@class="code-header"]/div[@class="where"]' ': Fn'
fn a<A: /* ~const */ Fn() + ~const Destruct>()
fn a<A: /* ~const */ Fn() /* + ~const Destruct */>()
where
Option<A>: /* ~const */ Fn() + ~const Destruct,
Option<A>: /* ~const */ Fn() /* + ~const Destruct */,
{
}
}
@ -36,13 +37,13 @@ pub trait Tr<T> {
// @has - '//section[@id="impl-Tr%3CT%3E-for-T"]/h3[@class="code-header"]/a[@class="trait"]' 'Fn'
// @!has - '//section[@id="impl-Tr%3CT%3E-for-T"]/h3[@class="code-header"]/span[@class="where"]' '~const'
// @has - '//section[@id="impl-Tr%3CT%3E-for-T"]/h3[@class="code-header"]/div[@class="where"]' ': Fn'
impl<T: /* ~const */ Fn() + ~const Destruct> const Tr<T> for T
impl<T: /* ~const */ Fn() /* + ~const Destruct */> const Tr<T> for T
where
Option<T>: /* ~const */ Fn() + ~const Destruct,
Option<T>: /* ~const */ Fn() /* + ~const Destruct */,
{
fn a<A: /* ~const */ Fn() + ~const Destruct>()
fn a<A: /* ~const */ Fn() /* + ~const Destruct */>()
where
Option<A>: /* ~const */ Fn() + ~const Destruct,
Option<A>: /* ~const */ Fn() /* + ~const Destruct */,
{
}
}
@ -51,9 +52,9 @@ where
// @has - '//pre[@class="rust item-decl"]/code/a[@class="trait"]' 'Fn'
// @!has - '//pre[@class="rust item-decl"]/code/div[@class="where"]' '~const'
// @has - '//pre[@class="rust item-decl"]/code/div[@class="where"]' ': Fn'
pub const fn foo<F: /* ~const */ Fn() + ~const Destruct>()
pub const fn foo<F: /* ~const */ Fn() /* + ~const Destruct */>()
where
Option<F>: /* ~const */ Fn() + ~const Destruct,
Option<F>: /* ~const */ Fn() /* + ~const Destruct */,
{
F::a()
}
@ -63,9 +64,9 @@ impl<T> S<T> {
// @has - '//section[@id="method.foo"]/h4[@class="code-header"]/a[@class="trait"]' 'Fn'
// @!has - '//section[@id="method.foo"]/h4[@class="code-header"]/span[@class="where"]' '~const'
// @has - '//section[@id="method.foo"]/h4[@class="code-header"]/div[@class="where"]' ': Fn'
pub const fn foo<B, C: /* ~const */ Fn() + ~const Destruct>()
pub const fn foo<B, C: /* ~const */ Fn() /* + ~const Destruct */>()
where
B: /* ~const */ Fn() + ~const Destruct,
B: /* ~const */ Fn() /* + ~const Destruct */,
{
B::a()
}

View File

@ -1,6 +1,6 @@
//@ build-pass
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
trait Func<T> {

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/const_trait_fn-issue-88433.rs:3:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -1,5 +1,5 @@
#![crate_type = "lib"]
#![feature(const_closures, const_trait_impl, effects)]
#![feature(const_closures, const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
pub const fn test() {
let cl = const || {};

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/const-float-classify.rs:7:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: const `impl` for trait `PartialEq` which is not marked with `#[const_trait]`
--> $DIR/const-float-classify.rs:12:12
|
@ -208,7 +217,7 @@ LL | impl const PartialEq<NonDet> for bool {
| unsatisfied trait bound introduced here
= note: this error originates in the macro `const_assert` which comes from the expansion of the macro `suite` (in Nightly builds, run with -Z macro-backtrace for more info)
error: aborting due to 10 previous errors
error: aborting due to 10 previous errors; 1 warning emitted
Some errors have detailed explanations: E0207, E0284.
For more information about an error, try `rustc --explain E0207`.

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/const_cmp_type_id.rs:3:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0131]: `main` function is not allowed to have generic parameters
--> $DIR/const_cmp_type_id.rs:7:14
|
@ -10,7 +19,7 @@ error[E0080]: evaluation of constant value failed
LL | const _A: bool = TypeId::of::<u8>() < TypeId::of::<u16>();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ calling non-const function `<TypeId as PartialOrd>::lt`
error: aborting due to 2 previous errors
error: aborting due to 2 previous errors; 1 warning emitted
Some errors have detailed explanations: E0080, E0131.
For more information about an error, try `rustc --explain E0080`.

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/rustc-impl-const-stability.rs:5:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: const `impl` for trait `Default` which is not marked with `#[const_trait]`
--> $DIR/rustc-impl-const-stability.rs:15:12
|
@ -16,6 +25,6 @@ LL | impl const Default for Data {
= note: expressions using a const parameter must map each value to a distinct output value
= note: proving the result of expressions other than the parameter are unique is not supported
error: aborting due to 2 previous errors
error: aborting due to 2 previous errors; 1 warning emitted
For more information about this error, try `rustc --explain E0207`.

View File

@ -1,7 +1,7 @@
// Regression test for part of issue #119924.
//@ check-pass
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
trait Trait {

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/impls-nested-within-fns-semantic-1.rs:4:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/assoc-type-const-bound-usage-0.rs:6:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0277]: the trait bound `T: Trait` is not satisfied
--> $DIR/assoc-type-const-bound-usage-0.rs:21:6
|
@ -9,6 +18,6 @@ help: consider further restricting this bound
LL | const fn qualified<T: ~const Trait + Trait>() -> i32 {
| +++++++
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0277`.

View File

@ -3,7 +3,7 @@
//@[unqualified] check-pass
//@[qualified] known-bug: unknown
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //[unqualified]~ WARN the feature `effects` is incomplete
#[const_trait]
trait Trait {

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/assoc-type-const-bound-usage-0.rs:6:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -1,5 +1,5 @@
// FIXME(effects): Replace `Add` with `std::ops::Add` once the latter a `#[const_trait]` again.
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
trait Add<Rhs = Self> {

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/assoc-type.rs:2:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0277]: the trait bound `NonConstAdd: ~const Add` is not satisfied
--> $DIR/assoc-type.rs:35:16
|
@ -11,6 +20,6 @@ note: required by a bound in `Foo::Bar`
LL | type Bar: ~const Add;
| ^^^^^^^^^^ required by this bound in `Foo::Bar`
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0277`.

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
pub trait MyTrait {

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#![feature(staged_api)]
#![stable(feature = "rust1", since = "1.0.0")]

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
pub trait Plus {

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/call-const-trait-method-fail.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0277]: the trait bound `u32: ~const Plus` is not satisfied
--> $DIR/call-const-trait-method-fail.rs:25:5
|
@ -6,6 +15,6 @@ LL | a.plus(b)
|
= help: the trait `Plus` is implemented for `u32`
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0277`.

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/call-generic-method-chain.rs:6:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: const `impl` for trait `PartialEq` which is not marked with `#[const_trait]`
--> $DIR/call-generic-method-chain.rs:10:12
|
@ -56,7 +65,7 @@ LL | impl const PartialEq for S {
| |
| unsatisfied trait bound introduced here
error: aborting due to 6 previous errors
error: aborting due to 6 previous errors; 1 warning emitted
Some errors have detailed explanations: E0207, E0284.
For more information about an error, try `rustc --explain E0207`.

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/call-generic-method-dup-bound.rs:4:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: const `impl` for trait `PartialEq` which is not marked with `#[const_trait]`
--> $DIR/call-generic-method-dup-bound.rs:8:12
|
@ -70,7 +79,7 @@ LL | impl const PartialEq for S {
| |
| unsatisfied trait bound introduced here
error: aborting due to 7 previous errors
error: aborting due to 7 previous errors; 1 warning emitted
Some errors have detailed explanations: E0207, E0284.
For more information about an error, try `rustc --explain E0207`.

View File

@ -1,6 +1,6 @@
//@ check-pass
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
pub const fn equals_self<T: PartialEq>(t: &T) -> bool {
*t == *t

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/call-generic-method-fail.rs:3:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
struct S;

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/call-generic-method-nonconst.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0277]: the trait bound `S: const Foo` is not satisfied
--> $DIR/call-generic-method-nonconst.rs:23:34
|
@ -13,6 +22,6 @@ note: required by a bound in `equals_self`
LL | const fn equals_self<T: ~const Foo>(t: &T) -> bool {
| ^^^^^^^^^^ required by this bound in `equals_self`
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0277`.

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/call-generic-method-pass.rs:6:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: const `impl` for trait `PartialEq` which is not marked with `#[const_trait]`
--> $DIR/call-generic-method-pass.rs:10:12
|
@ -50,7 +59,7 @@ LL | impl const PartialEq for S {
| |
| unsatisfied trait bound introduced here
error: aborting due to 5 previous errors
error: aborting due to 5 previous errors; 1 warning emitted
Some errors have detailed explanations: E0207, E0284.
For more information about an error, try `rustc --explain E0207`.

View File

@ -1,5 +1,5 @@
// Regression test for issue #117244.
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
trait NonConst {}

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/const-bounds-non-const-trait.rs:2:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: `~const` can only be applied to `#[const_trait]` traits
--> $DIR/const-bounds-non-const-trait.rs:6:28
|
@ -10,5 +19,5 @@ error: `const` can only be applied to `#[const_trait]` traits
LL | fn operate<T: const NonConst>() {}
| ^^^^^^^^
error: aborting due to 2 previous errors
error: aborting due to 2 previous errors; 1 warning emitted

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
struct S;
#[const_trait]

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/const-check-fns-in-const-impl.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0015]: cannot call non-const fn `non_const` in constant functions
--> $DIR/const-check-fns-in-const-impl.rs:12:16
|
@ -6,6 +15,6 @@ LL | fn foo() { non_const() }
|
= note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0015`.

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
trait ConstDefaultFn: Sized {

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/const-default-method-bodies.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0277]: the trait bound `NonConstImpl: ~const ConstDefaultFn` is not satisfied
--> $DIR/const-default-method-bodies.rs:24:18
|
@ -6,6 +15,6 @@ LL | NonConstImpl.a();
|
= help: the trait `ConstDefaultFn` is implemented for `NonConstImpl`
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0277`.

View File

@ -7,7 +7,7 @@
#![feature(
auto_traits,
const_trait_impl,
effects,
effects, //~ WARN the feature `effects` is incomplete
lang_items,
no_core,
staged_api,

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/const-fns-are-early-bound.rs:10:5
|
LL | effects,
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/const-impl-requires-const-trait.rs:3:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: const `impl` for trait `A` which is not marked with `#[const_trait]`
--> $DIR/const-impl-requires-const-trait.rs:8:12
|
@ -19,6 +28,6 @@ LL | impl const A for () {}
= note: expressions using a const parameter must map each value to a distinct output value
= note: proving the result of expressions other than the parameter are unique is not supported
error: aborting due to 2 previous errors
error: aborting due to 2 previous errors; 1 warning emitted
For more information about this error, try `rustc --explain E0207`.

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
//@ edition: 2021
#[const_trait]

View File

@ -26,5 +26,14 @@ LL | const fn take(_: &dyn ~const NonConst) {}
|
= note: trait objects cannot have `~const` trait bounds
error: aborting due to 4 previous errors
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/const-trait-bounds-trait-objects.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: aborting due to 4 previous errors; 1 warning emitted

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/derive-const-non-const-type.rs:2:26
|
LL | #![feature(derive_const, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: const `impl` for trait `Default` which is not marked with `#[const_trait]`
--> $DIR/derive-const-non-const-type.rs:10:16
|
@ -13,6 +22,6 @@ error[E0207]: the const parameter `host` is not constrained by the impl trait, s
= note: expressions using a const parameter must map each value to a distinct output value
= note: proving the result of expressions other than the parameter are unique is not supported
error: aborting due to 2 previous errors
error: aborting due to 2 previous errors; 1 warning emitted
For more information about this error, try `rustc --explain E0207`.

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/derive-const-use.rs:3:76
|
LL | #![feature(const_trait_impl, const_cmp, const_default_impls, derive_const, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0635]: unknown feature `const_cmp`
--> $DIR/derive-const-use.rs:3:30
|
@ -137,7 +146,7 @@ LL | impl const PartialEq for A {
| unsatisfied trait bound introduced here
= note: this error originates in the derive macro `PartialEq` (in Nightly builds, run with -Z macro-backtrace for more info)
error: aborting due to 14 previous errors
error: aborting due to 14 previous errors; 1 warning emitted
Some errors have detailed explanations: E0207, E0284, E0635.
For more information about an error, try `rustc --explain E0207`.

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/derive-const-with-params.rs:5:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: const `impl` for trait `PartialEq` which is not marked with `#[const_trait]`
--> $DIR/derive-const-with-params.rs:7:16
|
@ -34,7 +43,7 @@ LL | #[derive_const(PartialEq)]
| ^^^^^^^^^ unsatisfied trait bound introduced in this `derive` macro
= note: this error originates in the derive macro `PartialEq` (in Nightly builds, run with -Z macro-backtrace for more info)
error: aborting due to 4 previous errors
error: aborting due to 4 previous errors; 1 warning emitted
Some errors have detailed explanations: E0207, E0284.
For more information about an error, try `rustc --explain E0207`.

View File

@ -3,7 +3,7 @@
//
//@ check-pass
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
//@ aux-build: cross-crate.rs
extern crate cross_crate;

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/cross-crate-default-method-body-is-const.rs:6:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/cross-crate.rs:3:60
|
LL | #![cfg_attr(any(gated, gatednc), feature(const_trait_impl, effects))]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -1,11 +1,20 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/cross-crate.rs:3:60
|
LL | #![cfg_attr(any(gated, gatednc), feature(const_trait_impl, effects))]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0277]: the trait bound `cross_crate::NonConst: ~const cross_crate::MyTrait` is not satisfied
--> $DIR/cross-crate.rs:17:14
--> $DIR/cross-crate.rs:18:14
|
LL | NonConst.func();
| ^^^^ the trait `~const cross_crate::MyTrait` is not implemented for `cross_crate::NonConst`
|
= help: the trait `cross_crate::MyTrait` is implemented for `cross_crate::NonConst`
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0277`.

View File

@ -1,6 +1,7 @@
//@ revisions: stock gated stocknc gatednc
//@ [gated] check-pass
#![cfg_attr(any(gated, gatednc), feature(const_trait_impl, effects))]
//[gated,gatednc]~^ WARN the feature `effects` is incomplete
//@ aux-build: cross-crate.rs
extern crate cross_crate;

View File

@ -1,5 +1,5 @@
error[E0015]: cannot call non-const fn `<cross_crate::Const as cross_crate::MyTrait>::func` in constant functions
--> $DIR/cross-crate.rs:20:11
--> $DIR/cross-crate.rs:21:11
|
LL | Const.func();
| ^^^^^^

View File

@ -1,5 +1,5 @@
error[E0015]: cannot call non-const fn `<cross_crate::NonConst as cross_crate::MyTrait>::func` in constant functions
--> $DIR/cross-crate.rs:17:14
--> $DIR/cross-crate.rs:18:14
|
LL | NonConst.func();
| ^^^^^^
@ -11,7 +11,7 @@ LL + #![feature(const_trait_impl)]
|
error[E0015]: cannot call non-const fn `<cross_crate::Const as cross_crate::MyTrait>::func` in constant functions
--> $DIR/cross-crate.rs:20:11
--> $DIR/cross-crate.rs:21:11
|
LL | Const.func();
| ^^^^^^

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
pub trait Tr {

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/default-method-body-is-const-same-trait-ck.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0277]: the trait bound `(): ~const Tr` is not satisfied
--> $DIR/default-method-body-is-const-same-trait-ck.rs:8:12
|
@ -6,6 +15,6 @@ LL | ().a()
|
= help: the trait `Tr` is implemented for `()`
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0277`.

View File

@ -1,5 +1,5 @@
//@ check-pass
#![feature(const_trait_impl, rustc_attrs, effects)]
#![feature(const_trait_impl, rustc_attrs, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
trait Foo {

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/do-not-const-check-override.rs:2:43
|
LL | #![feature(const_trait_impl, rustc_attrs, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
pub const fn foo() {}

View File

@ -3,7 +3,7 @@
//
//@ check-pass
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
pub trait Foo<Rhs: ?Sized = Self> {

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/effect-param-infer.rs:6:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -1,6 +1,6 @@
//@ check-pass
#![feature(effects)]
#![feature(effects)] //~ WARN the feature `effects` is incomplete
pub const fn owo() {}

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/fallback.rs:3:12
|
LL | #![feature(effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -3,7 +3,12 @@
// gate-test-effects
// ^ effects doesn't have a gate so we will trick tidy into thinking this is a gate test
#![feature(const_trait_impl, effects, core_intrinsics, const_eval_select)]
#![feature(
const_trait_impl,
effects, //~ WARN the feature `effects` is incomplete
core_intrinsics,
const_eval_select
)]
// ensure we are passing in the correct host effect in always const contexts.

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/helloworld.rs:8:5
|
LL | effects,
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
const fn test() -> impl ~const Fn() {
//~^ ERROR `~const` can only be applied to `#[const_trait]` traits

View File

@ -8,6 +8,15 @@ LL | const move || {
= help: add `#![feature(const_closures)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/ice-112822-expected-type-for-param.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: `~const` can only be applied to `#[const_trait]` traits
--> $DIR/ice-112822-expected-type-for-param.rs:3:32
|
@ -31,7 +40,7 @@ LL | assert_eq!(first, &b'f');
= note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
= note: this error originates in the macro `assert_eq` (in Nightly builds, run with -Z macro-backtrace for more info)
error: aborting due to 4 previous errors
error: aborting due to 4 previous errors; 1 warning emitted
Some errors have detailed explanations: E0015, E0658.
For more information about an error, try `rustc --explain E0015`.

View File

@ -1,5 +1,5 @@
//@ check-pass
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
const fn a() {}

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/infer-fallback.rs:2:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -1,9 +1,18 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/minicore.rs:8:30
|
LL | #![feature(const_trait_impl, effects, const_mut_refs)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0094]: intrinsic has wrong number of const parameters: found 1, expected 0
--> $DIR/minicore.rs:517:27
|
LL | const fn const_eval_select<ARG: Tuple, F, G, RET>(
| ^^^^^^^^^^^^^^^^^^^^^^^ expected 0 const parameters
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0094`.

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
const fn foo() {}

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/no-explicit-const-params.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0107]: function takes 0 generic arguments but 1 generic argument was supplied
--> $DIR/no-explicit-const-params.rs:22:5
|
@ -63,7 +72,7 @@ note: trait defined here, with 0 generic parameters
LL | trait Bar {
| ^^^
error: aborting due to 5 previous errors
error: aborting due to 5 previous errors; 1 warning emitted
Some errors have detailed explanations: E0107, E0308.
For more information about an error, try `rustc --explain E0107`.

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/project.rs:4:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0277]: the trait bound `Self: Uwu` is not satisfied
--> $DIR/project.rs:12:1
|
@ -60,6 +69,6 @@ help: consider further restricting `Self`
LL | pub trait Uwu: Owo + Uwu {
| +++++
error: aborting due to 5 previous errors
error: aborting due to 5 previous errors; 1 warning emitted
For more information about this error, try `rustc --explain E0277`.

View File

@ -1,5 +1,5 @@
#![feature(const_trait_impl)]
#![feature(effects)]
#![feature(effects)] //~ WARN the feature `effects` is incomplete
struct S;
trait T {}

View File

@ -8,6 +8,15 @@ LL | impl const dyn T {
|
= note: only trait implementations may be annotated with `const`
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/span-bug-issue-121418.rs:2:12
|
LL | #![feature(effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0207]: the const parameter `host` is not constrained by the impl trait, self type, or predicates
--> $DIR/span-bug-issue-121418.rs:7:6
|
@ -39,7 +48,7 @@ note: required because it appears within the type `Mutex<(dyn T + 'static)>`
--> $SRC_DIR/std/src/sync/mutex.rs:LL:COL
= note: the return type of a function must have a statically known size
error: aborting due to 4 previous errors
error: aborting due to 4 previous errors; 1 warning emitted
Some errors have detailed explanations: E0207, E0277, E0308.
For more information about an error, try `rustc --explain E0207`.

View File

@ -1,7 +1,7 @@
//@ check-fail
// Fixes #119830
#![feature(effects)]
#![feature(effects)] //~ WARN the feature `effects` is incomplete
#![feature(min_specialization)]
#![feature(const_trait_impl)]

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/spec-effectvar-ice.rs:4:12
|
LL | #![feature(effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: const `impl` for trait `Foo` which is not marked with `#[const_trait]`
--> $DIR/spec-effectvar-ice.rs:12:15
|
@ -55,7 +64,7 @@ LL | impl<T> const Foo for T where T: const Specialize {}
= note: expressions using a const parameter must map each value to a distinct output value
= note: proving the result of expressions other than the parameter are unique is not supported
error: aborting due to 6 previous errors
error: aborting due to 6 previous errors; 1 warning emitted
Some errors have detailed explanations: E0119, E0207.
For more information about an error, try `rustc --explain E0119`.

View File

@ -1,5 +1,5 @@
// Regression test for issue #113378.
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
trait Trait {

View File

@ -54,6 +54,15 @@ LL + #[const_trait]
LL | trait NonConst {
|
error: aborting due to 4 previous errors
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/trait-fn-const.rs:2:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: aborting due to 4 previous errors; 1 warning emitted
For more information about this error, try `rustc --explain E0379`.

View File

@ -1,6 +1,6 @@
// Regression test for #69615.
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
pub trait MyTrait {

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/hir-const-check.rs:3:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0658]: `?` is not allowed in a `const fn`
--> $DIR/hir-const-check.rs:12:9
|
@ -8,6 +17,6 @@ LL | Some(())?;
= help: add `#![feature(const_try)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0658`.

View File

@ -1,5 +1,5 @@
//@ edition: 2021
#![feature(effects)]
#![feature(effects)] //~ WARN the feature `effects` is incomplete
trait MyTrait {}

View File

@ -46,6 +46,15 @@ LL | |
LL | | }
| |_____^ not a member of trait `MyTrait`
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/ice-120503-async-const-method.rs:2:12
|
LL | #![feature(effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0425]: cannot find function `main8` in this scope
--> $DIR/ice-120503-async-const-method.rs:13:9
|
@ -86,7 +95,7 @@ LL | async const fn bar(&self) {
| ^^^^^^^^^^^^^^^^^^^^^^^^^
= note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
error: aborting due to 6 previous errors
error: aborting due to 6 previous errors; 1 warning emitted
Some errors have detailed explanations: E0379, E0391, E0407, E0425.
For more information about an error, try `rustc --explain E0379`.

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
pub struct Vec3;

View File

@ -14,6 +14,15 @@ help: ... and declare the impl to be const instead
LL | impl const Add for Vec3 {
| +++++
error: aborting due to 1 previous error
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/ice-121536-const-method.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0379`.

View File

@ -1,5 +1,5 @@
#![feature(const_fmt_arguments_new)]
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#[const_trait]
trait Tr {

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/issue-79450.rs:2:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0015]: cannot call non-const fn `_print` in constant functions
--> $DIR/issue-79450.rs:9:9
|
@ -7,6 +16,6 @@ LL | println!("lul");
= note: calls in constant functions are limited to constant functions, tuple structs and tuple variants
= note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0015`.

View File

@ -3,7 +3,7 @@
//@ run-pass
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#![feature(min_specialization)]
#[const_trait]

View File

@ -0,0 +1,11 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/const-default-const-specialized.rs:6:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
warning: 1 warning emitted

View File

@ -1,6 +1,6 @@
// Tests that specializing trait impls must be at least as const as the default impl.
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#![feature(min_specialization)]
#[const_trait]

View File

@ -1,8 +1,17 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/const-default-impl-non-const-specialized-impl.rs:3:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: cannot specialize on const impl with non-const impl
--> $DIR/const-default-impl-non-const-specialized-impl.rs:19:1
|
LL | impl Value for FortyTwo {
| ^^^^^^^^^^^^^^^^^^^^^^^
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/non-const-default-const-specialized.rs:6:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0119]: conflicting implementations of trait `Value` for type `FortyTwo`
--> $DIR/non-const-default-const-specialized.rs:27:1
|
@ -7,6 +16,6 @@ LL | impl<T> Value for T {
LL | impl const Value for FortyTwo {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for `FortyTwo`
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0119`.

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/specializing-constness-2.rs:1:30
|
LL | #![feature(const_trait_impl, effects, min_specialization, rustc_attrs)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0119]: conflicting implementations of trait `A`
--> $DIR/specializing-constness-2.rs:20:1
|
@ -16,7 +25,7 @@ LL | <T as A>::a();
= note: expected constant `host`
found constant `true`
error: aborting due to 2 previous errors
error: aborting due to 2 previous errors; 1 warning emitted
Some errors have detailed explanations: E0119, E0308.
For more information about an error, try `rustc --explain E0119`.

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects, min_specialization, rustc_attrs)]
#![feature(const_trait_impl, effects, min_specialization, rustc_attrs)] //~ WARN the feature `effects` is incomplete
#[rustc_specialization_trait]
#[const_trait]

View File

@ -1,8 +1,17 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/specializing-constness.rs:1:30
|
LL | #![feature(const_trait_impl, effects, min_specialization, rustc_attrs)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: cannot specialize on const impl with non-const impl
--> $DIR/specializing-constness.rs:23:1
|
LL | impl<T: Spec + Sup> A for T {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted

View File

@ -1,7 +1,7 @@
//@ revisions: stable unstable
#![cfg_attr(unstable, feature(unstable))] // The feature from the ./auxiliary/staged-api.rs file.
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
#![feature(staged_api)]
#![stable(feature = "rust1", since = "1.0.0")]

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/staged-api.rs:4:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: trait implementations cannot be const stable yet
--> $DIR/staged-api.rs:19:1
|
@ -45,5 +54,5 @@ LL | Unstable::func();
|
= help: const-stable functions can only call other const-stable functions
error: aborting due to 5 previous errors
error: aborting due to 5 previous errors; 1 warning emitted

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/staged-api.rs:4:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: `<Foo as staged_api::MyTrait>::func` is not yet stable as a const fn
--> $DIR/staged-api.rs:34:5
|
@ -38,5 +47,5 @@ LL | const_context_not_const_stable()
|
= help: const-stable functions can only call other const-stable functions
error: aborting due to 5 previous errors
error: aborting due to 5 previous errors; 1 warning emitted

View File

@ -10,6 +10,15 @@ note: this trait is not a `#[const_trait]`, so it cannot have `~const` trait bou
LL | trait Bar: ~const Foo {}
| ^^^^^^^^^^^^^^^^^^^^^^^^
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/super-traits-fail-2.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: `~const` can only be applied to `#[const_trait]` traits
--> $DIR/super-traits-fail-2.rs:10:19
|
@ -32,5 +41,5 @@ LL | trait Bar: ~const Foo {}
|
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: aborting due to 4 previous errors
error: aborting due to 4 previous errors; 1 warning emitted

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/super-traits-fail-2.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error: `~const` can only be applied to `#[const_trait]` traits
--> $DIR/super-traits-fail-2.rs:10:19
|
@ -20,5 +29,5 @@ LL | trait Bar: ~const Foo {}
|
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
error: aborting due to 3 previous errors
error: aborting due to 3 previous errors; 1 warning emitted

View File

@ -1,4 +1,4 @@
#![feature(const_trait_impl, effects)]
#![feature(const_trait_impl, effects)] //~ WARN the feature `effects` is incomplete
//@ revisions: yy yn ny nn
#[cfg_attr(any(yy, yn), const_trait)]

View File

@ -10,6 +10,15 @@ note: this trait is not a `#[const_trait]`, so it cannot have `~const` trait bou
LL | trait Bar: ~const Foo {}
| ^^^^^^^^^^^^^^^^^^^^^^^^
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/super-traits-fail-2.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0308]: mismatched types
--> $DIR/super-traits-fail-2.rs:17:5
|
@ -19,6 +28,6 @@ LL | x.a();
= note: expected constant `host`
found constant `true`
error: aborting due to 2 previous errors
error: aborting due to 2 previous errors; 1 warning emitted
For more information about this error, try `rustc --explain E0308`.

View File

@ -1,3 +1,12 @@
warning: the feature `effects` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/super-traits-fail-2.rs:1:30
|
LL | #![feature(const_trait_impl, effects)]
| ^^^^^^^
|
= note: see issue #102090 <https://github.com/rust-lang/rust/issues/102090> for more information
= note: `#[warn(incomplete_features)]` on by default
error[E0308]: mismatched types
--> $DIR/super-traits-fail-2.rs:17:5
|
@ -7,6 +16,6 @@ LL | x.a();
= note: expected constant `host`
found constant `true`
error: aborting due to 1 previous error
error: aborting due to 1 previous error; 1 warning emitted
For more information about this error, try `rustc --explain E0308`.

Some files were not shown because too many files have changed in this diff Show More