diff options
| author | Brian Anderson <banderson@mozilla.com> | 2012-11-28 12:38:53 -0800 |
|---|---|---|
| committer | Brian Anderson <banderson@mozilla.com> | 2012-11-28 13:17:33 -0800 |
| commit | fc06114ddfd2bcdbc4f29076c226a7a1d66ea8d6 (patch) | |
| tree | bd9de2c450f23b8ff0e09130ab59d784ace5b5e3 /src/librustc/driver | |
| parent | 669fbddc4435a9ab152332df06a7fcca789c8059 (diff) | |
| parent | 8179e268efd86ae5c1bcf21b4f8d4e01eea7c193 (diff) | |
| download | rust-fc06114ddfd2bcdbc4f29076c226a7a1d66ea8d6.tar.gz rust-fc06114ddfd2bcdbc4f29076c226a7a1d66ea8d6.zip | |
Merge remote-tracking branch 'brson/companion' into incoming
Conflicts: src/compiletest/compiletest.rs src/libcargo/cargo.rs src/libcore/core.rs src/librustc/rustc.rs src/librustdoc/rustdoc.rc
Diffstat (limited to 'src/librustc/driver')
| -rw-r--r-- | src/librustc/driver/driver.rs | 10 | ||||
| -rw-r--r-- | src/librustc/driver/mod.rs | 5 | ||||
| -rw-r--r-- | src/librustc/driver/session.rs | 31 |
3 files changed, 5 insertions, 41 deletions
diff --git a/src/librustc/driver/driver.rs b/src/librustc/driver/driver.rs index 3d27c75f548..ba6b34ac5e6 100644 --- a/src/librustc/driver/driver.rs +++ b/src/librustc/driver/driver.rs @@ -141,19 +141,9 @@ enum compile_upto { } impl compile_upto : cmp::Eq { - #[cfg(stage0)] - pure fn eq(other: &compile_upto) -> bool { - (self as uint) == ((*other) as uint) - } - #[cfg(stage1)] - #[cfg(stage2)] pure fn eq(&self, other: &compile_upto) -> bool { ((*self) as uint) == ((*other) as uint) } - #[cfg(stage0)] - pure fn ne(other: &compile_upto) -> bool { !self.eq(other) } - #[cfg(stage1)] - #[cfg(stage2)] pure fn ne(&self, other: &compile_upto) -> bool { !(*self).eq(other) } } diff --git a/src/librustc/driver/mod.rs b/src/librustc/driver/mod.rs new file mode 100644 index 00000000000..7d9a55571d4 --- /dev/null +++ b/src/librustc/driver/mod.rs @@ -0,0 +1,5 @@ +#[legacy_exports]; +#[legacy_exports] +mod driver; +#[legacy_exports] +mod session; diff --git a/src/librustc/driver/session.rs b/src/librustc/driver/session.rs index d1ec992bc53..7614bdbb25b 100644 --- a/src/librustc/driver/session.rs +++ b/src/librustc/driver/session.rs @@ -13,38 +13,18 @@ use middle::lint; enum os { os_win32, os_macos, os_linux, os_freebsd, } impl os : cmp::Eq { - #[cfg(stage0)] - pure fn eq(other: &os) -> bool { - (self as uint) == ((*other) as uint) - } - #[cfg(stage1)] - #[cfg(stage2)] pure fn eq(&self, other: &os) -> bool { ((*self) as uint) == ((*other) as uint) } - #[cfg(stage0)] - pure fn ne(other: &os) -> bool { !self.eq(other) } - #[cfg(stage1)] - #[cfg(stage2)] pure fn ne(&self, other: &os) -> bool { !(*self).eq(other) } } enum arch { arch_x86, arch_x86_64, arch_arm, } impl arch : cmp::Eq { - #[cfg(stage0)] - pure fn eq(other: &arch) -> bool { - (self as uint) == ((*other) as uint) - } - #[cfg(stage1)] - #[cfg(stage2)] pure fn eq(&self, other: &arch) -> bool { ((*self) as uint) == ((*other) as uint) } - #[cfg(stage0)] - pure fn ne(other: &arch) -> bool { !self.eq(other) } - #[cfg(stage1)] - #[cfg(stage2)] pure fn ne(&self, other: &arch) -> bool { !(*self).eq(other) } } @@ -111,19 +91,9 @@ enum OptLevel { } impl OptLevel : cmp::Eq { - #[cfg(stage0)] - pure fn eq(other: &OptLevel) -> bool { - (self as uint) == ((*other) as uint) - } - #[cfg(stage1)] - #[cfg(stage2)] pure fn eq(&self, other: &OptLevel) -> bool { ((*self) as uint) == ((*other) as uint) } - #[cfg(stage0)] - pure fn ne(other: &OptLevel) -> bool { !self.eq(other) } - #[cfg(stage1)] - #[cfg(stage2)] pure fn ne(&self, other: &OptLevel) -> bool { !(*self).eq(other) } } @@ -357,7 +327,6 @@ mod test { if with_bin { attrs += ~[make_crate_type_attr(~"bin")]; } if with_lib { attrs += ~[make_crate_type_attr(~"lib")]; } @ast_util::respan(ast_util::dummy_sp(), { - directives: ~[], module: {view_items: ~[], items: ~[]}, attrs: attrs, config: ~[] |
