Change tests to use self instead of mod in use items

This commit is contained in:
Nick Cameron 2014-12-31 17:29:22 +13:00
parent 74d11d26f4
commit f003b43823
5 changed files with 14 additions and 14 deletions

View File

@ -9,10 +9,10 @@
// except according to those terms.
mod foo {
use self::{mod};
use self::{self};
//~^ ERROR unresolved import `self`. There is no `self` in `???`
use super::{mod};
use super::{self};
//~^ ERROR unresolved import `super`. There is no `super` in `???`
}

View File

@ -9,7 +9,7 @@
// except according to those terms.
use foo::bar::{
mod //~ ERROR module `bar` is private
self //~ ERROR module `bar` is private
};
use foo::bar::{
Bar //~ ERROR type `Bar` is inaccessible

View File

@ -9,18 +9,18 @@
// except according to those terms.
use foo::bar::{
mod,
//~^ ERROR `mod` import can only appear once in the list
self,
//~^ ERROR `self` import can only appear once in the list
Bar,
mod
//~^ NOTE another `mod` import appears here
self
//~^ NOTE another `self` import appears here
};
use {mod};
//~^ ERROR `mod` import can only appear in an import list with a non-empty prefix
use {self};
//~^ ERROR `self` import can only appear in an import list with a non-empty prefix
use foo::mod;
//~^ ERROR `mod` imports are only allowed within a { } list
use foo::self;
//~^ ERROR `self` imports are only allowed within a { } list
mod foo {
pub mod bar {

View File

@ -13,7 +13,7 @@ extern crate collections;
extern crate serialize;
use std::collections::HashMap;
use serialize::json::{mod, Json};
use serialize::json::{self, Json};
use std::option;
enum object {

View File

@ -8,11 +8,11 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
pub use foo::bar::{mod, First};
pub use foo::bar::{self, First};
use self::bar::Second;
mod foo {
pub use self::bar::baz::{mod};
pub use self::bar::baz::{self};
pub mod bar {
pub mod baz {