Skip to content

Commit 3e9df41

Browse files
committed
---
yaml --- r: 172198 b: refs/heads/beta c: bdc1bfd h: refs/heads/master v: v3
1 parent 42dfc9e commit 3e9df41

File tree

651 files changed

+4546
-5936
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

651 files changed

+4546
-5936
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,5 @@ refs/heads/automation-fail: 1bf06495443584539b958873e04cc2f864ab10e4
3131
refs/heads/issue-18208-method-dispatch-3-quick-reject: 2009f85b9f99dedcec4404418eda9ddba90258a2
3232
refs/heads/batch: b5571ed71a5879c0495a982506258d5d267744ed
3333
refs/heads/building: 126db549b038c84269a1e4fe46f051b2c15d6970
34-
refs/heads/beta: 373cbab5b08d6630da58f28d2166c19afc327fa6
34+
refs/heads/beta: bdc1bfd8f1740461d2ee39ba41f5245ed8913a2a
3535
refs/heads/windistfix: 7608dbad651f02e837ed05eef3d74a6662a6e928

branches/beta/configure

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -599,18 +599,6 @@ then
599599
fi
600600
putvar CFG_RELEASE_CHANNEL
601601

602-
# A magic value that allows the compiler to use unstable features
603-
# during the bootstrap even when doing so would normally be an error
604-
# because of feature staging or because the build turns on
605-
# warnings-as-errors and unstable features default to warnings. The
606-
# build has to match this key in an env var. Meant to be a mild
607-
# deterrent from users just turning on unstable features on the stable
608-
# channel.
609-
# Basing CFG_BOOTSTRAP_KEY on CFG_BOOTSTRAP_KEY lets it get picked up
610-
# during a Makefile reconfig.
611-
CFG_BOOTSTRAP_KEY="${CFG_BOOTSTRAP_KEY-`date +%N`}"
612-
putvar CFG_BOOTSTRAP_KEY
613-
614602
step_msg "looking for build programs"
615603

616604
probe_need CFG_PERL perl

branches/beta/mk/main.mk

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,11 @@ ifeq ($(CFG_RELEASE_CHANNEL),stable)
2525
CFG_RELEASE=$(CFG_RELEASE_NUM)
2626
# This is the string used in dist artifact file names, e.g. "0.12.0", "nightly"
2727
CFG_PACKAGE_VERS=$(CFG_RELEASE_NUM)
28-
CFG_DISABLE_UNSTABLE_FEATURES=1
2928
endif
3029
ifeq ($(CFG_RELEASE_CHANNEL),beta)
3130
# The beta channel is temporarily called 'alpha'
3231
CFG_RELEASE=$(CFG_RELEASE_NUM)-alpha$(CFG_BETA_CYCLE)
3332
CFG_PACKAGE_VERS=$(CFG_RELEASE_NUM)-alpha$(CFG_BETA_CYCLE)
34-
CFG_DISABLE_UNSTABLE_FEATURES=1
3533
endif
3634
ifeq ($(CFG_RELEASE_CHANNEL),nightly)
3735
CFG_RELEASE=$(CFG_RELEASE_NUM)-nightly
@@ -123,9 +121,11 @@ CFG_JEMALLOC_FLAGS += $(JEMALLOC_FLAGS)
123121

124122
ifdef CFG_DISABLE_DEBUG
125123
CFG_RUSTC_FLAGS += --cfg ndebug
124+
CFG_GCCISH_CFLAGS += -DRUST_NDEBUG
126125
else
127126
$(info cfg: enabling more debugging (CFG_ENABLE_DEBUG))
128127
CFG_RUSTC_FLAGS += --cfg debug
128+
CFG_GCCISH_CFLAGS += -DRUST_DEBUG
129129
endif
130130

131131
ifdef SAVE_TEMPS
@@ -319,20 +319,11 @@ export CFG_VERSION_WIN
319319
export CFG_RELEASE
320320
export CFG_PACKAGE_NAME
321321
export CFG_BUILD
322-
export CFG_RELEASE_CHANNEL
323322
export CFG_LLVM_ROOT
324323
export CFG_PREFIX
325324
export CFG_LIBDIR
326325
export CFG_LIBDIR_RELATIVE
327326
export CFG_DISABLE_INJECT_STD_VERSION
328-
ifdef CFG_DISABLE_UNSTABLE_FEATURES
329-
CFG_INFO := $(info cfg: disabling unstable features (CFG_DISABLE_UNSTABLE_FEATURES))
330-
# Turn on feature-staging
331-
export CFG_DISABLE_UNSTABLE_FEATURES
332-
endif
333-
# Subvert unstable feature lints to do the self-build
334-
export CFG_BOOTSTRAP_KEY
335-
export RUSTC_BOOTSTRAP_KEY:=$(CFG_BOOTSTRAP_KEY)
336327

337328
######################################################################
338329
# Per-stage targets and runner

branches/beta/src/compiletest/compiletest.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,7 @@
99
// except according to those terms.
1010

1111
#![crate_type = "bin"]
12-
#![allow(unknown_features)]
1312
#![feature(slicing_syntax, unboxed_closures)]
14-
#![feature(box_syntax)]
1513

1614
#![deny(warnings)]
1715

branches/beta/src/compiletest/runtest.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -908,7 +908,8 @@ fn check_error_patterns(props: &TestProps,
908908
}
909909
if done { return; }
910910

911-
let missing_patterns = &props.error_patterns[next_err_idx..];
911+
let missing_patterns =
912+
props.error_patterns.index(&(next_err_idx..));
912913
if missing_patterns.len() == 1u {
913914
fatal_proc_rec(format!("error pattern '{}' not found!",
914915
missing_patterns[0]).as_slice(),

branches/beta/src/doc/footer.inc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<footer><p>
2-
Copyright &copy; 2011-2015 The Rust Project Developers. Licensed under the
2+
Copyright &copy; 2011-2014 The Rust Project Developers. Licensed under the
33
<a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>
44
or the <a href="http://opensource.org/licenses/MIT">MIT license</a>, at your option.
55
</p><p>

branches/beta/src/doc/guide-ownership.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -458,7 +458,7 @@ lifetime, and so if you elide a lifetime (like `&T` instead of `&'a T`), Rust
458458
will do three things to determine what those lifetimes should be.
459459

460460
When talking about lifetime elision, we use the term 'input lifetime' and
461-
'output lifetime'. An 'input lifetime' is a lifetime associated with a parameter
461+
'output lifetime'. An 'input liftime' is a lifetime associated with a parameter
462462
of a function, and an 'output lifetime' is a lifetime associated with the return
463463
value of a function. For example, this function has an input lifetime:
464464

branches/beta/src/doc/intro.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -542,7 +542,7 @@ use std::thread::Thread;
542542
fn main() {
543543
let vec = vec![1i, 2, 3];
544544
545-
for i in range(0u, 3) {
545+
for i in range(1u, 3) {
546546
Thread::spawn(move || {
547547
println!("{}", vec[i]);
548548
}).detach();
@@ -558,7 +558,7 @@ a vector:
558558
```{rust}
559559
let vec = vec![1i, 2, 3];
560560
561-
for i in range(0u, vec.len()) {
561+
for i in range(1u, vec.len()) {
562562
println!("{}", vec[i]);
563563
}
564564
```

branches/beta/src/liballoc/arc.rs

Lines changed: 8 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -67,20 +67,21 @@
6767
//! }
6868
//! ```
6969
70-
use core::prelude::*;
71-
7270
use core::atomic;
7371
use core::atomic::Ordering::{Relaxed, Release, Acquire, SeqCst};
7472
use core::borrow::BorrowFrom;
73+
use core::clone::Clone;
7574
use core::fmt::{self, Show};
76-
use core::cmp::{Ordering};
75+
use core::cmp::{Eq, Ord, PartialEq, PartialOrd, Ordering};
7776
use core::default::Default;
78-
use core::mem::{min_align_of, size_of};
77+
use core::marker::{Sync, Send};
78+
use core::mem::{min_align_of, size_of, drop};
7979
use core::mem;
8080
use core::nonzero::NonZero;
81-
use core::ops::Deref;
82-
use core::ptr;
83-
use core::hash::{Hash, Hasher};
81+
use core::ops::{Drop, Deref};
82+
use core::option::Option;
83+
use core::option::Option::{Some, None};
84+
use core::ptr::{self, PtrExt};
8485
use heap::deallocate;
8586

8687
/// An atomically reference counted wrapper for shared state.
@@ -584,25 +585,12 @@ impl<T: fmt::Show> fmt::Show for Arc<T> {
584585
}
585586
}
586587

587-
#[stable]
588-
impl<T: fmt::String> fmt::String for Arc<T> {
589-
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
590-
fmt::String::fmt(&**self, f)
591-
}
592-
}
593-
594588
#[stable]
595589
impl<T: Default + Sync + Send> Default for Arc<T> {
596590
#[stable]
597591
fn default() -> Arc<T> { Arc::new(Default::default()) }
598592
}
599593

600-
impl<H: Hasher, T: Hash<H>> Hash<H> for Arc<T> {
601-
fn hash(&self, state: &mut H) {
602-
(**self).hash(state)
603-
}
604-
}
605-
606594
#[cfg(test)]
607595
#[allow(experimental)]
608596
mod tests {

branches/beta/src/liballoc/boxed.rs

Lines changed: 13 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2012-2015 The Rust Project Developers. See the COPYRIGHT
1+
// Copyright 2012-2014 The Rust Project Developers. See the COPYRIGHT
22
// file at the top-level directory of this distribution and at
33
// http://rust-lang.org/COPYRIGHT.
44
//
@@ -49,15 +49,6 @@ pub static HEAP: () = ();
4949
#[stable]
5050
pub struct Box<T>(Unique<T>);
5151

52-
#[unstable]
53-
impl<T> Box<T> {
54-
/// Moves `x` into a freshly allocated box on the global exchange heap.
55-
#[unstable]
56-
pub fn new(x: T) -> Box<T> {
57-
box x
58-
}
59-
}
60-
6152
#[stable]
6253
impl<T: Default> Default for Box<T> {
6354
#[stable]
@@ -111,24 +102,16 @@ impl<T: ?Sized + Ord> Ord for Box<T> {
111102
fn cmp(&self, other: &Box<T>) -> Ordering {
112103
Ord::cmp(&**self, &**other)
113104
}
114-
}
115-
#[stable]
105+
106+
#[stable]}
116107
impl<T: ?Sized + Eq> Eq for Box<T> {}
117108

118-
#[cfg(stage0)]
119109
impl<S: hash::Writer, T: ?Sized + Hash<S>> Hash<S> for Box<T> {
120110
#[inline]
121111
fn hash(&self, state: &mut S) {
122112
(**self).hash(state);
123113
}
124114
}
125-
#[cfg(not(stage0))]
126-
impl<S: hash::Hasher, T: ?Sized + Hash<S>> Hash<S> for Box<T> {
127-
#[inline]
128-
fn hash(&self, state: &mut S) {
129-
(**self).hash(state);
130-
}
131-
}
132115

133116
/// Extension methods for an owning `Any` trait object.
134117
#[unstable = "post-DST and coherence changes, this will not be a trait but \
@@ -166,7 +149,6 @@ impl<T: ?Sized + fmt::Show> fmt::Show for Box<T> {
166149
}
167150
}
168151

169-
#[stable]
170152
impl<T: ?Sized + fmt::String> fmt::String for Box<T> {
171153
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
172154
fmt::String::fmt(&**self, f)
@@ -195,36 +177,36 @@ impl<T: ?Sized> DerefMut for Box<T> {
195177
mod test {
196178
#[test]
197179
fn test_owned_clone() {
198-
let a = Box::new(5i);
180+
let a = box 5i;
199181
let b: Box<int> = a.clone();
200182
assert!(a == b);
201183
}
202184

203185
#[test]
204186
fn any_move() {
205-
let a = Box::new(8u) as Box<Any>;
206-
let b = Box::new(Test) as Box<Any>;
187+
let a = box 8u as Box<Any>;
188+
let b = box Test as Box<Any>;
207189

208190
match a.downcast::<uint>() {
209-
Ok(a) => { assert!(a == Box::new(8u)); }
191+
Ok(a) => { assert!(a == box 8u); }
210192
Err(..) => panic!()
211193
}
212194
match b.downcast::<Test>() {
213-
Ok(a) => { assert!(a == Box::new(Test)); }
195+
Ok(a) => { assert!(a == box Test); }
214196
Err(..) => panic!()
215197
}
216198

217-
let a = Box::new(8u) as Box<Any>;
218-
let b = Box::new(Test) as Box<Any>;
199+
let a = box 8u as Box<Any>;
200+
let b = box Test as Box<Any>;
219201

220202
assert!(a.downcast::<Box<Test>>().is_err());
221203
assert!(b.downcast::<Box<uint>>().is_err());
222204
}
223205

224206
#[test]
225207
fn test_show() {
226-
let a = Box::new(8u) as Box<Any>;
227-
let b = Box::new(Test) as Box<Any>;
208+
let a = box 8u as Box<Any>;
209+
let b = box Test as Box<Any>;
228210
let a_str = a.to_str();
229211
let b_str = b.to_str();
230212
assert_eq!(a_str, "Box<Any>");
@@ -241,6 +223,6 @@ mod test {
241223
#[test]
242224
fn deref() {
243225
fn homura<T: Deref<Target=i32>>(_: T) { }
244-
homura(Box::new(765i32));
226+
homura(box 765i32);
245227
}
246228
}

branches/beta/src/liballoc/heap.rs

Lines changed: 16 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -115,20 +115,16 @@ unsafe fn exchange_free(ptr: *mut u8, old_size: uint, align: uint) {
115115
// The minimum alignment guaranteed by the architecture. This value is used to
116116
// add fast paths for low alignment values. In practice, the alignment is a
117117
// constant at the call site and the branch will be optimized out.
118-
#[cfg(all(not(feature = "external_funcs"),
119-
not(feature = "external_crate"),
120-
any(target_arch = "arm",
121-
target_arch = "mips",
122-
target_arch = "mipsel")))]
118+
#[cfg(any(target_arch = "arm",
119+
target_arch = "mips",
120+
target_arch = "mipsel"))]
123121
const MIN_ALIGN: uint = 8;
124-
#[cfg(all(not(feature = "external_funcs"),
125-
not(feature = "external_crate"),
126-
any(target_arch = "x86",
127-
target_arch = "x86_64",
128-
target_arch = "aarch64"))]
122+
#[cfg(any(target_arch = "x86",
123+
target_arch = "x86_64",
124+
target_arch = "aarch64"))]
129125
const MIN_ALIGN: uint = 16;
130126

131-
#[cfg(feature = "external_funcs")]
127+
#[cfg(external_funcs)]
132128
mod imp {
133129
extern {
134130
fn rust_allocate(size: uint, align: uint) -> *mut u8;
@@ -146,13 +142,14 @@ mod imp {
146142
}
147143

148144
#[inline]
149-
pub unsafe fn deallocate(ptr: *mut u8, old_size: uint, align: uint) {
150-
rust_deallocate(ptr, old_size, align)
145+
pub unsafe fn reallocate_inplace(ptr: *mut u8, old_size: uint, size: uint,
146+
align: uint) -> uint {
147+
rust_reallocate_inplace(ptr, old_size, size, align)
151148
}
152149

153150
#[inline]
154-
pub unsafe fn reallocate(ptr: *mut u8, old_size: uint, size: uint, align: uint) -> *mut u8 {
155-
rust_reallocate(ptr, old_size, size, align)
151+
pub unsafe fn deallocate(ptr: *mut u8, old_size: uint, align: uint) {
152+
rust_deallocate(ptr, old_size, align)
156153
}
157154

158155
#[inline]
@@ -172,16 +169,14 @@ mod imp {
172169
}
173170
}
174171

175-
#[cfg(feature = "external_crate")]
172+
#[cfg(external_crate)]
176173
mod imp {
177174
extern crate external;
178175
pub use self::external::{allocate, deallocate, reallocate_inplace, reallocate};
179176
pub use self::external::{usable_size, stats_print};
180177
}
181178

182-
#[cfg(all(not(feature = "external_funcs"),
183-
not(feature = "external_crate"),
184-
jemalloc))]
179+
#[cfg(all(not(external_funcs), not(external_crate), jemalloc))]
185180
mod imp {
186181
use core::option::Option;
187182
use core::option::Option::None;
@@ -258,10 +253,7 @@ mod imp {
258253
}
259254
}
260255

261-
#[cfg(all(not(feature = "external_funcs"),
262-
not(feature = "external_crate"),
263-
not(jemalloc),
264-
unix))]
256+
#[cfg(all(not(external_funcs), not(external_crate), not(jemalloc), unix))]
265257
mod imp {
266258
use core::cmp;
267259
use core::ptr;
@@ -322,10 +314,7 @@ mod imp {
322314
pub fn stats_print() {}
323315
}
324316

325-
#[cfg(all(not(feature = "external_funcs"),
326-
not(feature = "external_crate"),
327-
not(jemalloc),
328-
windows))]
317+
#[cfg(all(not(external_funcs), not(external_crate), not(jemalloc), windows))]
329318
mod imp {
330319
use libc::{c_void, size_t};
331320
use libc;

0 commit comments

Comments
 (0)