diff options
Diffstat (limited to 'src/test/ui/traits/trait-or-new-type-instead.stderr')
-rw-r--r-- | src/test/ui/traits/trait-or-new-type-instead.stderr | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/test/ui/traits/trait-or-new-type-instead.stderr b/src/test/ui/traits/trait-or-new-type-instead.stderr new file mode 100644 index 000000000..4726b0668 --- /dev/null +++ b/src/test/ui/traits/trait-or-new-type-instead.stderr @@ -0,0 +1,14 @@ +error[E0116]: cannot define inherent `impl` for a type outside of the crate where the type is defined + --> $DIR/trait-or-new-type-instead.rs:1:1 + | +LL | / impl<T> Option<T> { +LL | | +LL | | pub fn foo(&self) { } +LL | | } + | |_^ impl for type defined outside of crate. + | + = note: define and implement a trait or new type instead + +error: aborting due to previous error + +For more information about this error, try `rustc --explain E0116`. |