From 1b82060c5e40e0b4e996bcd30deccd2a523c7590 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafael=20=C3=81vila=20de=20Esp=C3=ADndola?= Date: Tue, 25 Jan 2011 18:15:19 -0500 Subject: Print an error if we try to refer to a module in an expr_path. --- src/test/compile-fail/bad-expr-path2.rs | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 src/test/compile-fail/bad-expr-path2.rs (limited to 'src/test') diff --git a/src/test/compile-fail/bad-expr-path2.rs b/src/test/compile-fail/bad-expr-path2.rs new file mode 100644 index 00000000..a2f58f8e --- /dev/null +++ b/src/test/compile-fail/bad-expr-path2.rs @@ -0,0 +1,10 @@ +// error-pattern: can't refer to a module as a first-class value + +mod m1 { + mod a { + } +} + +fn main(vec[str] args) { + log m1.a; +} -- cgit v1.2.3