-
Notifications
You must be signed in to change notification settings - Fork 12.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make feature
negative_bounds
internal
- Loading branch information
Showing
11 changed files
with
28 additions
and
75 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
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
20 changes: 6 additions & 14 deletions
20
tests/ui/traits/negative-bounds/associated-constraints.stderr
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 |
---|---|---|
@@ -1,40 +1,32 @@ | ||
error: associated type constraints not allowed on negative bounds | ||
--> $DIR/associated-constraints.rs:8:19 | ||
--> $DIR/associated-constraints.rs:7:19 | ||
| | ||
LL | fn test<T: !Trait<Assoc = i32>>() {} | ||
| ^^^^^^^^^^^ | ||
|
||
error: associated type constraints not allowed on negative bounds | ||
--> $DIR/associated-constraints.rs:11:31 | ||
--> $DIR/associated-constraints.rs:10:31 | ||
| | ||
LL | fn test2<T>() where T: !Trait<Assoc = i32> {} | ||
| ^^^^^^^^^^^ | ||
|
||
error: associated type constraints not allowed on negative bounds | ||
--> $DIR/associated-constraints.rs:14:20 | ||
--> $DIR/associated-constraints.rs:13:20 | ||
| | ||
LL | fn test3<T: !Trait<Assoc: Send>>() {} | ||
| ^^^^^^^^^^^ | ||
|
||
error: associated type constraints not allowed on negative bounds | ||
--> $DIR/associated-constraints.rs:17:31 | ||
--> $DIR/associated-constraints.rs:16:31 | ||
| | ||
LL | fn test4<T>() where T: !Trait<Assoc: Send> {} | ||
| ^^^^^^^^^^^ | ||
|
||
error: parenthetical notation may not be used for negative bounds | ||
--> $DIR/associated-constraints.rs:20:25 | ||
--> $DIR/associated-constraints.rs:19:25 | ||
| | ||
LL | fn test5<T>() where T: !Fn() -> i32 {} | ||
| ^^^^^^^^^^^ | ||
|
||
warning: the feature `negative_bounds` is incomplete and may not be safe to use and/or cause compiler crashes | ||
--> $DIR/associated-constraints.rs:1:12 | ||
| | ||
LL | #![feature(negative_bounds, associated_type_bounds)] | ||
| ^^^^^^^^^^^^^^^ | ||
| | ||
= note: `#[warn(incomplete_features)]` on by default | ||
|
||
error: aborting due to 5 previous errors; 1 warning emitted | ||
error: aborting due to 5 previous errors | ||
|
1 change: 0 additions & 1 deletion
1
tests/ui/traits/negative-bounds/opaque-type-unsatisfied-bound.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
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
1 change: 0 additions & 1 deletion
1
tests/ui/traits/negative-bounds/opaque-type-unsatisfied-fn-bound.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
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
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
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
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
This file was deleted.
Oops, something went wrong.