summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Gomez <guillaume1.gomez@gmail.com>2019-12-04 13:27:17 +0100
committerGuillaume Gomez <guillaume1.gomez@gmail.com>2019-12-04 13:32:37 +0100
commitc2ce7dd756c36cb619c7f231ab6596d6b180afed (patch)
treebe459c648df8b4bebebdf5931a837919805e3159
parentAuto merge of #65947 - eddyb:fn-abi, r=oli-obk,nagisa (diff)
downloadrust-c2ce7dd756c36cb619c7f231ab6596d6b180afed.tar.gz
rust-c2ce7dd756c36cb619c7f231ab6596d6b180afed.tar.bz2
rust-c2ce7dd756c36cb619c7f231ab6596d6b180afed.tar.xz
Clean up E0116 error code long explanation
-rw-r--r--src/librustc_error_codes/error_codes/E0116.md10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/librustc_error_codes/error_codes/E0116.md b/src/librustc_error_codes/error_codes/E0116.md
index 27759a4..ca849c2 100644
--- a/src/librustc_error_codes/error_codes/E0116.md
+++ b/src/librustc_error_codes/error_codes/E0116.md
@@ -1,11 +1,15 @@
1You can only define an inherent implementation for a type in the same crate 1An inherent implementation was defined for a type outside the current crate.
2where the type was defined. For example, an `impl` block as below is not allowed 2
3since `Vec` is defined in the standard library: 3Erroneous code example:
4 4
5```compile_fail,E0116 5```compile_fail,E0116
6impl Vec<u8> { } // error 6impl Vec<u8> { } // error
7``` 7```
8 8
9You can only define an inherent implementation for a type in the same crate
10where the type was defined. For example, an `impl` block as above is not allowed
11since `Vec` is defined in the standard library.
12
9To fix this problem, you can do either of these things: 13To fix this problem, you can do either of these things:
10 14
11 - define a trait that has the desired associated functions/types/constants and 15 - define a trait that has the desired associated functions/types/constants and