aboutsummaryrefslogtreecommitdiff
path: root/src/test/compile-fail
diff options
context:
space:
mode:
authorMarijn Haverbeke <[email protected]>2011-05-13 16:46:20 +0200
committerMarijn Haverbeke <[email protected]>2011-05-13 17:20:46 +0200
commitae26b775b4ae4a1405effefb015ec44f0311c29f (patch)
tree33b7104df2b9fcebca3b74a6b319a8a695a3c907 /src/test/compile-fail
parentExtend crate format to allow multiple definitions for a single name (diff)
downloadrust-ae26b775b4ae4a1405effefb015ec44f0311c29f.tar.xz
rust-ae26b775b4ae4a1405effefb015ec44f0311c29f.zip
Implement module namespaces
Module names no longer clash with type and value names. The tokenizer/parser still needs to be taught to be more careful in identifying keywords, so that we can use 'str' and 'vec' and so as module names.
Diffstat (limited to 'src/test/compile-fail')
-rw-r--r--src/test/compile-fail/bad-expr-path2.rs4
-rw-r--r--src/test/compile-fail/import2.rs2
-rw-r--r--src/test/compile-fail/import3.rs3
3 files changed, 6 insertions, 3 deletions
diff --git a/src/test/compile-fail/bad-expr-path2.rs b/src/test/compile-fail/bad-expr-path2.rs
index 607c9173..1ace6295 100644
--- a/src/test/compile-fail/bad-expr-path2.rs
+++ b/src/test/compile-fail/bad-expr-path2.rs
@@ -1,4 +1,6 @@
-// error-pattern: is a module, not a
+// xfail-boot
+// xfail-stage0
+// error-pattern: unresolved name: a
mod m1 {
mod a {
diff --git a/src/test/compile-fail/import2.rs b/src/test/compile-fail/import2.rs
index beb704ca..ef3a79d1 100644
--- a/src/test/compile-fail/import2.rs
+++ b/src/test/compile-fail/import2.rs
@@ -1,5 +1,5 @@
// xfail-boot
-// error-pattern: unresolved name
+// error-pattern: unresolved modulename
import baz::zed::bar;
mod baz {
}
diff --git a/src/test/compile-fail/import3.rs b/src/test/compile-fail/import3.rs
index ba7a178c..95f10845 100644
--- a/src/test/compile-fail/import3.rs
+++ b/src/test/compile-fail/import3.rs
@@ -1,5 +1,6 @@
// xfail-boot
-// error-pattern: main is not a module or crate
+// xfail-stage0
+// error-pattern: unresolved modulename
import main::bar;
fn main(vec[str] args) {