forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
normalize env constness for nested obligations
- Loading branch information
Showing
2 changed files
with
47 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
src/test/ui/rfc-2632-const-trait-impl/issue-92230-wf-super-trait-env.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// Regression test for #92230. | ||
// | ||
// check-pass | ||
|
||
#![feature(const_fn_trait_bound)] | ||
#![feature(const_trait_impl)] | ||
|
||
pub trait Super {} | ||
pub trait Sub: Super {} | ||
|
||
impl<A> const Super for &A where A: ~const Super {} | ||
impl<A> const Sub for &A where A: ~const Sub {} | ||
|
||
fn main() {} |