Rollup merge of #98782 - compiler-errors:specialization-error-span, r=oli-obk
Improve spans for specialization error Fixes #98777
This commit is contained in:
commit
da630de3bd
6 changed files with 31 additions and 18 deletions
|
|
@ -1,8 +1,8 @@
|
|||
error: cannot specialize on `Binder(ProjectionPredicate(ProjectionTy { substs: [V], item_def_id: DefId(0:6 ~ repeated_projection_type[54ea]::Id::This) }, Ty((I,))), [])`
|
||||
--> $DIR/repeated_projection_type.rs:19:1
|
||||
error: cannot specialize on associated type `<V as Id>::This == (I,)`
|
||||
--> $DIR/repeated_projection_type.rs:19:15
|
||||
|
|
||||
LL | impl<I, V: Id<This = (I,)>> X for V {
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
| ^^^^^^^^^^^
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
error: cannot specialize on trait `HasMethod`
|
||||
--> $DIR/spec-marker-supertraits.rs:22:1
|
||||
--> $DIR/spec-marker-supertraits.rs:22:9
|
||||
|
|
||||
LL | impl<T: Marker> Spec for T {
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
| ^^^^^^
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
error: cannot specialize on trait `Default`
|
||||
--> $DIR/specialization_super_trait.rs:13:1
|
||||
--> $DIR/specialization_super_trait.rs:13:9
|
||||
|
|
||||
LL | impl<T: Default> SpecMarker for T {
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
| ^^^^^^^
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
|
|
|||
|
|
@ -11,10 +11,10 @@ LL | impl<T> SpecMarker for (T, T) {
|
|||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
error: cannot specialize on trait `Clone`
|
||||
--> $DIR/specialization_trait.rs:21:1
|
||||
--> $DIR/specialization_trait.rs:21:9
|
||||
|
|
||||
LL | impl<T: Clone> SpecMarker for [T] {
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
| ^^^^^
|
||||
|
||||
error: aborting due to 3 previous errors
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
error: cannot specialize on trait `SpecMarker`
|
||||
--> $DIR/specialize_on_trait.rs:15:1
|
||||
--> $DIR/specialize_on_trait.rs:15:9
|
||||
|
|
||||
LL | impl<T: SpecMarker> X for T {
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
| ^^^^^^^^^^
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue