Skip to content

Commit 359ac36

Browse files
committed
Register new snapshots
This enables the parser error for `extern mod` => `extern crate` transitions.
1 parent 3496e93 commit 359ac36

File tree

8 files changed

+18
-39
lines changed

8 files changed

+18
-39
lines changed

src/libstd/hashmap.rs

+2-4
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ use container::{Container, Mutable, Map, MutableMap, Set, MutableSet};
5656
use clone::Clone;
5757
use cmp::{Eq, Equiv, max};
5858
use default::Default;
59-
#[cfg(not(stage0))] use fmt;
59+
use fmt;
6060
use hash::Hash;
6161
use iter;
6262
use iter::{Iterator, FromIterator, Extendable};
@@ -66,7 +66,7 @@ use num;
6666
use option::{None, Option, Some};
6767
use rand::Rng;
6868
use rand;
69-
#[cfg(not(stage0))] use result::{Ok, Err};
69+
use result::{Ok, Err};
7070
use vec::{ImmutableVector, MutableVector, OwnedVector, Items, MutItems};
7171
use vec_ng;
7272
use vec_ng::Vec;
@@ -597,7 +597,6 @@ impl<K:Hash + Eq + Clone,V:Clone> Clone for HashMap<K,V> {
597597
}
598598
}
599599

600-
#[cfg(not(stage0))]
601600
impl<A: fmt::Show + Hash + Eq, B: fmt::Show> fmt::Show for HashMap<A, B> {
602601
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
603602
if_ok!(write!(f.buf, r"\{"))
@@ -876,7 +875,6 @@ impl<T:Hash + Eq + Clone> Clone for HashSet<T> {
876875
}
877876
}
878877

879-
#[cfg(not(stage0))]
880878
impl<A: fmt::Show + Hash + Eq> fmt::Show for HashSet<A> {
881879
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
882880
if_ok!(write!(f.buf, r"\{"))

src/libstd/rt/env.rs

-11
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@
1010

1111
//! Runtime environment settings
1212
13-
// NOTE: remove `POISON_ON_FREE` after a snapshot
14-
1513
use from_str::from_str;
1614
use option::{Some, None};
1715
use os;
@@ -23,7 +21,6 @@ static mut MIN_STACK: uint = 2 * 1024 * 1024;
2321
/// This default corresponds to 20M of cache per scheduler (at the default size).
2422
static mut MAX_CACHED_STACKS: uint = 10;
2523
static mut DEBUG_BORROW: bool = false;
26-
static mut POISON_ON_FREE: bool = false;
2724

2825
pub fn init() {
2926
unsafe {
@@ -43,10 +40,6 @@ pub fn init() {
4340
Some(_) => DEBUG_BORROW = true,
4441
None => ()
4542
}
46-
match os::getenv("RUST_POISON_ON_FREE") {
47-
Some(_) => POISON_ON_FREE = true,
48-
None => ()
49-
}
5043
}
5144
}
5245

@@ -61,7 +54,3 @@ pub fn max_cached_stacks() -> uint {
6154
pub fn debug_borrow() -> bool {
6255
unsafe { DEBUG_BORROW }
6356
}
64-
65-
pub fn poison_on_free() -> bool {
66-
unsafe { POISON_ON_FREE }
67-
}

src/libstd/rt/local_heap.rs

-3
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ use ops::Drop;
1717
use option::{Option, None, Some};
1818
use ptr;
1919
use ptr::RawPtr;
20-
use rt::env;
2120
use rt::global_heap;
2221
use rt::local::Local;
2322
use rt::task::Task;
@@ -41,7 +40,6 @@ pub struct MemoryRegion {
4140
pub struct LocalHeap {
4241
priv memory_region: MemoryRegion,
4342

44-
priv poison_on_free: bool,
4543
priv live_allocs: *mut raw::Box<()>,
4644
}
4745

@@ -54,7 +52,6 @@ impl LocalHeap {
5452
};
5553
LocalHeap {
5654
memory_region: region,
57-
poison_on_free: env::poison_on_free(),
5855
live_allocs: ptr::mut_null(),
5956
}
6057
}

src/libstd/vec.rs

+2-4
Original file line numberDiff line numberDiff line change
@@ -108,15 +108,15 @@ use container::{Container, Mutable};
108108
use cmp::{Eq, TotalOrd, Ordering, Less, Equal, Greater};
109109
use cmp;
110110
use default::Default;
111-
#[cfg(not(stage0))] use fmt;
111+
use fmt;
112112
use iter::*;
113113
use num::{Integer, CheckedAdd, Saturating, checked_next_power_of_two};
114114
use option::{None, Option, Some};
115115
use ptr::to_unsafe_ptr;
116116
use ptr;
117117
use ptr::RawPtr;
118118
use rt::global_heap::{malloc_raw, realloc_raw, exchange_free};
119-
#[cfg(not(stage0))] use result::{Ok, Err};
119+
use result::{Ok, Err};
120120
use mem;
121121
use mem::size_of;
122122
use kinds::marker;
@@ -2643,7 +2643,6 @@ impl<A: DeepClone> DeepClone for ~[A] {
26432643
}
26442644
}
26452645

2646-
#[cfg(not(stage0))]
26472646
impl<'a, T: fmt::Show> fmt::Show for &'a [T] {
26482647
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
26492648
if_ok!(write!(f.buf, "["));
@@ -2660,7 +2659,6 @@ impl<'a, T: fmt::Show> fmt::Show for &'a [T] {
26602659
}
26612660
}
26622661

2663-
#[cfg(not(stage0))]
26642662
impl<T: fmt::Show> fmt::Show for ~[T] {
26652663
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
26662664
self.as_slice().fmt(f)

src/libsyntax/parse/parser.rs

+6-7
Original file line numberDiff line numberDiff line change
@@ -4566,13 +4566,12 @@ impl Parser {
45664566
let next_is_mod = self.eat_keyword(keywords::Mod);
45674567

45684568
if next_is_mod || self.eat_keyword(keywords::Crate) {
4569-
// NOTE(flaper87): Uncomment this when this changes gets into stage0
4570-
//
4571-
// if next_is_mod {
4572-
// self.span_err(self.span,
4573-
// format!("`extern mod` is obsolete, use `extern crate` instead \
4574-
// to refer to external crates."))
4575-
// }
4569+
if next_is_mod {
4570+
self.span_err(self.span,
4571+
format!("`extern mod` is obsolete, use \
4572+
`extern crate` instead \
4573+
to refer to external crates."))
4574+
}
45764575
return self.parse_item_extern_crate(lo, visibility, attrs);
45774576
}
45784577

src/snapshots.txt

+8
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
S 2014-02-14 18477ac
2+
freebsd-x86_64 102df7dfab2a1c59d9e2f16a3f02f368310dd022
3+
linux-i386 fcf5891e9b3c7c9ef5ee5ea37e62089346099425
4+
linux-x86_64 d7c2df185fd2e25b4b8f5b2caad277b5ba664b81
5+
macos-i386
6+
macos-x86_64
7+
winnt-i386 f78a892f47627f34233e44c2ff4a00b68063a2ce
8+
19
S 2014-02-12 c62f6ce
210
freebsd-x86_64 737a423c5f803119ff5a692eac432fa9d0c595a8
311
linux-i386 a7e90e27e8b6a3fa79ddc15f0ed217ccbade875d

src/test/auxiliary/crateresolve_calories-1.rs

-5
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,6 @@
99
// except according to those terms.
1010

1111
#[crate_id="crateresolve_calories#0.1"];
12-
// NOTE: remove after the next snapshot
13-
#[link(name = "crateresolve_calories",
14-
vers = "0.1",
15-
calories = "100")];
16-
1712
#[crate_type = "lib"];
1813

1914
pub fn f() -> int { 100 }

src/test/auxiliary/crateresolve_calories-2.rs

-5
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,6 @@
99
// except according to those terms.
1010

1111
#[crate_id="crateresolve_calories#0.1"];
12-
// NOTE: remove after the next snapshot
13-
#[link(name = "crateresolve_calories",
14-
vers = "0.1",
15-
calories = "200")];
16-
1712
#[crate_type = "lib"];
1813

1914
pub fn f() -> int { 200 }

0 commit comments

Comments
 (0)