From c5a766f13379e543d2721b610c8eb6f3beb2af69 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafael=20=C3=81vila=20de=20Esp=C3=ADndola?= Date: Mon, 10 Jan 2011 15:56:55 -0500 Subject: Fix two invalid import cases we were not detecting: * If an import was unused we would never print any errors for it. * We would keep the existing environment in scope when descending 'foo.bar' and would find 'bar' in the global environment if there was no 'bar' in 'foo'. --- src/test/run-pass/use.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/test/run-pass') diff --git a/src/test/run-pass/use.rs b/src/test/run-pass/use.rs index 8638d609..ac46061c 100644 --- a/src/test/run-pass/use.rs +++ b/src/test/run-pass/use.rs @@ -3,9 +3,9 @@ use libc(); use zed(name = "std"); use bar(name = "std", ver = "0.0.1"); -import std._str; -import x = std._str; - +// FIXME: commented out since resolve doesn't know how to handle crates yet. +// import std._str; +// import x = std._str; mod baz { use std; @@ -13,8 +13,8 @@ mod baz { use zed(name = "std"); use bar(name = "std", ver = "0.0.1"); - import std._str; - import x = std._str; + // import std._str; + // import x = std._str; } fn main() { -- cgit v1.2.3