summaryrefslogtreecommitdiffstats
path: root/src/test/ui/type-alias-impl-trait/no_inferrable_concrete_type.stderr
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/test/ui/type-alias-impl-trait/no_inferrable_concrete_type.stderr20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/test/ui/type-alias-impl-trait/no_inferrable_concrete_type.stderr b/src/test/ui/type-alias-impl-trait/no_inferrable_concrete_type.stderr
new file mode 100644
index 000000000..337708b87
--- /dev/null
+++ b/src/test/ui/type-alias-impl-trait/no_inferrable_concrete_type.stderr
@@ -0,0 +1,20 @@
+error: unconstrained opaque type
+ --> $DIR/no_inferrable_concrete_type.rs:7:20
+ |
+LL | pub type Foo = impl Copy;
+ | ^^^^^^^^^
+ |
+ = note: `Foo` must be used in combination with a concrete type within the same module
+
+error[E0512]: cannot transmute between types of different sizes, or dependently-sized types
+ --> $DIR/no_inferrable_concrete_type.rs:17:23
+ |
+LL | let _: foo::Foo = std::mem::transmute(0u8);
+ | ^^^^^^^^^^^^^^^^^^^
+ |
+ = note: source type: `u8` (8 bits)
+ = note: target type: `Foo` (size can vary because of [type error])
+
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0512`.