about summary refs log tree commit diff
path: root/src/librustc_error_codes
diff options
context:
space:
mode:
authorNathan Corbyn <me@nathancorbyn.com>2020-06-08 11:57:56 +0100
committerNathan Corbyn <me@nathancorbyn.com>2020-06-08 12:00:12 +0100
commita1eeaddf3f7aad9e82196d338613593e4e000762 (patch)
tree5b9c9faa37cbde9d37b6e7fd1195717d0bbf41b6 /src/librustc_error_codes
parent73558160933b2764ed9a84b1b2b647e128eac3f8 (diff)
Resolve E0584 conflict
Diffstat (limited to 'src/librustc_error_codes')
-rw-r--r--src/librustc_error_codes/error_codes.rs1
-rw-r--r--src/librustc_error_codes/error_codes/E0761.md25
2 files changed, 26 insertions, 0 deletions
diff --git a/src/librustc_error_codes/error_codes.rs b/src/librustc_error_codes/error_codes.rs
index 7abe75a375a..a5b896ab19a 100644
--- a/src/librustc_error_codes/error_codes.rs
+++ b/src/librustc_error_codes/error_codes.rs
@@ -438,6 +438,7 @@ E0752: include_str!("./error_codes/E0752.md"),
 E0753: include_str!("./error_codes/E0753.md"),
 E0754: include_str!("./error_codes/E0754.md"),
 E0760: include_str!("./error_codes/E0760.md"),
+E0761: include_str!("./error_codes/E0761.md"),
 ;
 //  E0006, // merged with E0005
 //  E0008, // cannot bind by-move into a pattern guard
diff --git a/src/librustc_error_codes/error_codes/E0761.md b/src/librustc_error_codes/error_codes/E0761.md
new file mode 100644
index 00000000000..e22ebcdc431
--- /dev/null
+++ b/src/librustc_error_codes/error_codes/E0761.md
@@ -0,0 +1,25 @@
+Multiple candidate files were found for an out-of-line module.
+
+Erroneous code example:
+
+```rust
+// file: ambiguous_module/mod.rs
+
+fn foo() {}
+```
+
+```rust
+// file: ambiguous_module.rs
+
+fn foo() {}
+```
+
+```ignore (compile_fail not working here; see Issue #43707)
+mod ambiguous_module; // error: file for module `ambiguous_module`
+                      // found at both ambiguous_module.rs and
+                      // ambiguous_module.rs/mod.rs
+
+fn main() {}
+```
+
+Please remove this ambiguity by deleting/renaming one of the candidate files.