about summary refs log tree commit diff
path: root/src/test/compile-fail/mod_file_with_path_attr.rs
diff options
context:
space:
mode:
authorBrian Anderson <banderson@mozilla.com>2012-11-18 14:14:40 -0800
committerBrian Anderson <banderson@mozilla.com>2012-11-18 18:09:41 -0800
commit74b2e9979738ce413209aa4342fc35afe68c68de (patch)
tree1a6c24b0e8ea072cb651f60170e420e1a64686ae /src/test/compile-fail/mod_file_with_path_attr.rs
parent72cc1aca175044ceb003a8b270940bec1da85460 (diff)
downloadrust-74b2e9979738ce413209aa4342fc35afe68c68de.tar.gz
rust-74b2e9979738ce413209aa4342fc35afe68c68de.zip
Report errors better when failing to open files for sub-parsers
Diffstat (limited to 'src/test/compile-fail/mod_file_with_path_attr.rs')
-rw-r--r--src/test/compile-fail/mod_file_with_path_attr.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/test/compile-fail/mod_file_with_path_attr.rs b/src/test/compile-fail/mod_file_with_path_attr.rs
new file mode 100644
index 00000000000..3baa18be9f1
--- /dev/null
+++ b/src/test/compile-fail/mod_file_with_path_attr.rs
@@ -0,0 +1,6 @@
+#[path = "not_a_real_file.rs"]
+mod m; //~ ERROR not_a_real_file.rs
+
+fn main() {
+    assert m::foo() == 10;
+}
\ No newline at end of file