Skip to content

Commit 3d6f510

Browse files
committed
Auto merge of #21730 - Manishearth:rollup, r=alexcrichton
Should clear our backlog of rollups from the queue
2 parents bedd810 + 092330c commit 3d6f510

File tree

33 files changed

+93
-118
lines changed

33 files changed

+93
-118
lines changed

AUTHORS.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -516,7 +516,7 @@ Olivier Saut <[email protected]>
516516
Olle Jonsson <[email protected]>
517517
Or Brostovski <[email protected]>
518518
Oren Hazi <[email protected]>
519-
Orphée Lafond-Lummis <o@orftz.com>
519+
Orpheus Lummis <o@orpheuslummis.com>
520520
521521
Pablo Brasero <[email protected]>
522522
Palmer Cox <[email protected]>

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,11 +50,11 @@ example, if it's 2014, and you change a Rust file that was created in
5050
# Coordination and communication
5151

5252
Get feedback from other developers on
53-
[discuss.rust-lang.org][discuss], and
53+
[internals.rust-lang.org][internals], and
5454
[#rust-internals][pound-rust-internals].
5555

5656
[pound-rust-internals]: http://chat.mibbit.com/?server=irc.mozilla.org&channel=%23rust-internals
57-
[discuss]: http://discuss.rust-lang.org
57+
[internals]: http://internals.rust-lang.org
5858

5959
For more details, please refer to
6060
[Note-development-policy](https://github.com/rust-lang/rust/wiki/Note-development-policy).

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@ documentation.
3030

3131
To build from the [tarball] do:
3232

33-
$ curl -O https://static.rust-lang.org/dist/rust-nightly.tar.gz
34-
$ tar -xzf rust-nightly.tar.gz
35-
$ cd rust-nightly
33+
$ curl -O https://static.rust-lang.org/dist/rustc-nightly-src.tar.gz
34+
$ tar -xzf rustc-nightly-src.tar.gz
35+
$ cd rustc-nightly
3636

3737
Or to build from the [repo] do:
3838

@@ -80,7 +80,7 @@ $ pacman -S base-devel
8080
$ make && make install
8181

8282
[repo]: https://github.com/rust-lang/rust
83-
[tarball]: https://static.rust-lang.org/dist/rust-nightly.tar.gz
83+
[tarball]: https://static.rust-lang.org/dist/rustc-nightly-src.tar.gz
8484
[trpl]: http://doc.rust-lang.org/book/index.html
8585

8686
## Notes
@@ -112,11 +112,11 @@ The Rust community congregates in a few places:
112112

113113
* [StackOverflow] - Get help here.
114114
* [/r/rust] - General discussion.
115-
* [discuss.rust-lang.org] - For development of the Rust language itself.
115+
* [internals.rust-lang.org] - For development of the Rust language itself.
116116

117117
[StackOverflow]: http://stackoverflow.com/questions/tagged/rust
118118
[/r/rust]: http://reddit.com/r/rust
119-
[discuss.rust-lang.org]: http://discuss.rust-lang.org/
119+
[internals.rust-lang.org]: http://internals.rust-lang.org/
120120

121121
## License
122122

src/doc/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ problem might reveal someone who has asked it before!
4141
There is an active [subreddit](http://reddit.com/r/rust) with lots of
4242
discussion about Rust.
4343

44-
There is also a [developer forum](http://discuss.rust-lang.org/), where the
44+
There is also a [developer forum](http://internals.rust-lang.org/), where the
4545
development of Rust itself is discussed.
4646

4747
# Specification

src/etc/local_stage0.sh

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,19 +21,16 @@ case $OS in
2121
("Linux"|"FreeBSD"|"DragonFly")
2222
BIN_SUF=
2323
LIB_SUF=.so
24-
break
2524
;;
2625
("Darwin")
2726
BIN_SUF=
2827
LIB_SUF=.dylib
29-
break
3028
;;
3129
(*)
3230
BIN_SUF=.exe
3331
LIB_SUF=.dll
3432
LIB_DIR=bin
3533
LIB_PREFIX=
36-
break
3734
;;
3835
esac
3936

src/liballoc/heap.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11+
#[cfg(not(test))]
1112
use core::ptr::PtrExt;
1213

1314
// FIXME: #13996: mark the `allocate` and `reallocate` return value as `noalias`

src/libcore/cell.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -594,12 +594,6 @@ impl<'b, T> DerefMut for RefMut<'b, T> {
594594
/// The `UnsafeCell<T>` type is the only legal way to obtain aliasable data that is considered
595595
/// mutable. In general, transmuting an `&T` type into an `&mut T` is considered undefined behavior.
596596
///
597-
/// Although it is possible to put an `UnsafeCell<T>` into static item, it is not permitted to take
598-
/// the address of the static item if the item is not declared as mutable. This rule exists because
599-
/// immutable static items are stored in read-only memory, and thus any attempt to mutate their
600-
/// interior can cause segfaults. Immutable static items containing `UnsafeCell<T>` instances are
601-
/// still useful as read-only initializers, however, so we do not forbid them altogether.
602-
///
603597
/// Types like `Cell<T>` and `RefCell<T>` use this type to wrap their internal data.
604598
///
605599
/// `UnsafeCell<T>` doesn't opt-out from any marker traits, instead, types with an `UnsafeCell<T>`

src/libfmt_macros/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -447,7 +447,7 @@ mod tests {
447447
use super::*;
448448

449449
fn same(fmt: &'static str, p: &[Piece<'static>]) {
450-
let mut parser = Parser::new(fmt);
450+
let parser = Parser::new(fmt);
451451
assert!(p == parser.collect::<Vec<Piece<'static>>>());
452452
}
453453

src/liblibc/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -273,6 +273,7 @@ pub use funcs::bsd43::{shutdown};
273273
#[cfg(windows)] pub use funcs::extra::kernel32::{GetOverlappedResult, ConnectNamedPipe};
274274
#[cfg(windows)] pub use funcs::extra::kernel32::{DisconnectNamedPipe, OpenProcess};
275275
#[cfg(windows)] pub use funcs::extra::kernel32::{MoveFileExW, VirtualProtect};
276+
#[cfg(windows)] pub use funcs::extra::kernel32::{RemoveDirectoryW};
276277
#[cfg(windows)] pub use funcs::extra::msvcrt::{get_osfhandle, open_osfhandle};
277278
#[cfg(windows)] pub use funcs::extra::winsock::{ioctlsocket};
278279

src/librustc/metadata/csearch.rs

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@
1010

1111
// Searching for information from the cstore
1212

13-
#![allow(non_camel_case_types)]
14-
15-
pub use self::found_ast::*;
16-
1713
use metadata::common::*;
1814
use metadata::cstore;
1915
use metadata::decoder;
@@ -101,18 +97,18 @@ pub fn get_item_path(tcx: &ty::ctxt, def: ast::DefId) -> Vec<ast_map::PathElem>
10197
r
10298
}
10399

104-
pub enum found_ast<'ast> {
105-
found(&'ast ast::InlinedItem),
106-
found_parent(ast::DefId, &'ast ast::InlinedItem),
107-
not_found,
100+
pub enum FoundAst<'ast> {
101+
Found(&'ast ast::InlinedItem),
102+
FoundParent(ast::DefId, &'ast ast::InlinedItem),
103+
NotFound,
108104
}
109105

110106
// Finds the AST for this item in the crate metadata, if any. If the item was
111107
// not marked for inlining, then the AST will not be present and hence none
112108
// will be returned.
113109
pub fn maybe_get_item_ast<'tcx>(tcx: &ty::ctxt<'tcx>, def: ast::DefId,
114110
decode_inlined_item: decoder::DecodeInlinedItem)
115-
-> found_ast<'tcx> {
111+
-> FoundAst<'tcx> {
116112
let cstore = &tcx.sess.cstore;
117113
let cdata = cstore.get_crate_data(def.krate);
118114
decoder::maybe_get_item_ast(&*cdata, tcx, def.node, decode_inlined_item)

src/librustc/metadata/decoder.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -693,23 +693,23 @@ pub type DecodeInlinedItem<'a> =
693693

694694
pub fn maybe_get_item_ast<'tcx>(cdata: Cmd, tcx: &ty::ctxt<'tcx>, id: ast::NodeId,
695695
mut decode_inlined_item: DecodeInlinedItem)
696-
-> csearch::found_ast<'tcx> {
696+
-> csearch::FoundAst<'tcx> {
697697
debug!("Looking up item: {}", id);
698698
let item_doc = lookup_item(id, cdata.data());
699699
let path = item_path(item_doc).init().to_vec();
700700
match decode_inlined_item(cdata, tcx, path, item_doc) {
701-
Ok(ii) => csearch::found(ii),
701+
Ok(ii) => csearch::FoundAst::Found(ii),
702702
Err(path) => {
703703
match item_parent_item(item_doc) {
704704
Some(did) => {
705705
let did = translate_def_id(cdata, did);
706706
let parent_item = lookup_item(did.node, cdata.data());
707707
match decode_inlined_item(cdata, tcx, path, parent_item) {
708-
Ok(ii) => csearch::found_parent(did, ii),
709-
Err(_) => csearch::not_found
708+
Ok(ii) => csearch::FoundAst::FoundParent(did, ii),
709+
Err(_) => csearch::FoundAst::NotFound
710710
}
711711
}
712-
None => csearch::not_found
712+
None => csearch::FoundAst::NotFound
713713
}
714714
}
715715
}

src/librustc/metadata/encoder.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1577,7 +1577,7 @@ fn encode_info_for_items(ecx: &EncodeContext,
15771577
&krate.module,
15781578
&[],
15791579
ast::CRATE_NODE_ID,
1580-
ast_map::Values([].iter()).chain(None),
1580+
[].iter().cloned().chain(None),
15811581
syntax::parse::token::special_idents::invalid,
15821582
ast::Public);
15831583

@@ -1949,7 +1949,7 @@ fn encode_misc_info(ecx: &EncodeContext,
19491949
}
19501950

19511951
// Encode reexports for the root module.
1952-
encode_reexports(ecx, rbml_w, 0, ast_map::Values([].iter()).chain(None));
1952+
encode_reexports(ecx, rbml_w, 0, [].iter().cloned().chain(None));
19531953

19541954
rbml_w.end_tag();
19551955
rbml_w.end_tag();

src/librustc/middle/astencode.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ pub fn decode_inlined_item<'tcx>(cdata: &cstore::crate_metadata,
130130
debug!("> Decoding inlined fn: {:?}::?",
131131
{
132132
// Do an Option dance to use the path after it is moved below.
133-
let s = ast_map::path_to_string(ast_map::Values(path.iter()));
133+
let s = ast_map::path_to_string(path.iter().cloned());
134134
path_as_str = Some(s);
135135
path_as_str.as_ref().map(|x| &x[])
136136
});

src/librustc/middle/const_eval.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ fn lookup_variant_by_id<'a>(tcx: &'a ty::ctxt,
133133
}
134134
let expr_id = match csearch::maybe_get_item_ast(tcx, enum_def,
135135
box |a, b, c, d| astencode::decode_inlined_item(a, b, c, d)) {
136-
csearch::found(&ast::IIItem(ref item)) => match item.node {
136+
csearch::FoundAst::Found(&ast::IIItem(ref item)) => match item.node {
137137
ast::ItemEnum(ast::EnumDef { ref variants }, _) => {
138138
// NOTE this doesn't do the right thing, it compares inlined
139139
// NodeId's to the original variant_def's NodeId, but they
@@ -173,7 +173,7 @@ pub fn lookup_const_by_id<'a>(tcx: &'a ty::ctxt, def_id: ast::DefId)
173173
}
174174
let expr_id = match csearch::maybe_get_item_ast(tcx, def_id,
175175
box |a, b, c, d| astencode::decode_inlined_item(a, b, c, d)) {
176-
csearch::found(&ast::IIItem(ref item)) => match item.node {
176+
csearch::FoundAst::Found(&ast::IIItem(ref item)) => match item.node {
177177
ast::ItemConst(_, ref const_expr) => Some(const_expr.id),
178178
_ => None
179179
},

src/librustc/middle/ty.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5264,7 +5264,7 @@ pub fn with_path<T, F>(cx: &ctxt, id: ast::DefId, f: F) -> T where
52645264
if id.krate == ast::LOCAL_CRATE {
52655265
cx.map.with_path(id.node, f)
52665266
} else {
5267-
f(ast_map::Values(csearch::get_item_path(cx, id).iter()).chain(None))
5267+
f(csearch::get_item_path(cx, id).iter().cloned().chain(None))
52685268
}
52695269
}
52705270

src/librustc_back/rpath.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,6 @@ fn minimize_rpaths(rpaths: &[String]) -> Vec<String> {
151151
mod test {
152152
use super::{RPathConfig};
153153
use super::{minimize_rpaths, rpaths_to_flags, get_rpath_relative_to_output};
154-
use syntax::abi;
155154

156155
#[test]
157156
fn test_rpaths_to_flags() {

src/librustc_trans/back/link.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ use flate;
3737
use serialize::hex::ToHex;
3838
use syntax::ast;
3939
use syntax::ast_map::{PathElem, PathElems, PathName};
40-
use syntax::ast_map;
4140
use syntax::attr::AttrMetaMethods;
4241
use syntax::codemap::Span;
4342
use syntax::parse::token;
@@ -339,7 +338,7 @@ pub fn mangle_internal_name_by_type_and_seq<'a, 'tcx>(ccx: &CrateContext<'a, 'tc
339338
let path = [PathName(token::intern(&s[])),
340339
gensym_name(name)];
341340
let hash = get_symbol_hash(ccx, t);
342-
mangle(ast_map::Values(path.iter()), Some(&hash[]))
341+
mangle(path.iter().cloned(), Some(&hash[]))
343342
}
344343

345344
pub fn mangle_internal_name_by_path_and_seq(path: PathElems, flav: &str) -> String {

src/librustc_trans/back/write.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1012,6 +1012,9 @@ unsafe fn configure_llvm(sess: &Session) {
10121012
if sess.time_llvm_passes() { add("-time-passes"); }
10131013
if sess.print_llvm_passes() { add("-debug-pass=Structure"); }
10141014

1015+
// FIXME #21627 disable faulty FastISel on AArch64 (even for -O0)
1016+
if sess.target.target.arch.as_slice() == "aarch64" { add("-fast-isel=0"); }
1017+
10151018
for arg in sess.opts.cg.llvm_args.iter() {
10161019
add(&(*arg)[]);
10171020
}

src/librustc_trans/trans/inline.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,11 @@ fn instantiate_inline(ccx: &CrateContext, fn_id: ast::DefId)
4343
box |a,b,c,d| astencode::decode_inlined_item(a, b, c, d));
4444

4545
let inline_def = match csearch_result {
46-
csearch::not_found => {
46+
csearch::FoundAst::NotFound => {
4747
ccx.external().borrow_mut().insert(fn_id, None);
4848
return None;
4949
}
50-
csearch::found(&ast::IIItem(ref item)) => {
50+
csearch::FoundAst::Found(&ast::IIItem(ref item)) => {
5151
ccx.external().borrow_mut().insert(fn_id, Some(item.id));
5252
ccx.external_srcs().borrow_mut().insert(item.id, fn_id);
5353

@@ -90,12 +90,12 @@ fn instantiate_inline(ccx: &CrateContext, fn_id: ast::DefId)
9090

9191
local_def(item.id)
9292
}
93-
csearch::found(&ast::IIForeign(ref item)) => {
93+
csearch::FoundAst::Found(&ast::IIForeign(ref item)) => {
9494
ccx.external().borrow_mut().insert(fn_id, Some(item.id));
9595
ccx.external_srcs().borrow_mut().insert(item.id, fn_id);
9696
local_def(item.id)
9797
}
98-
csearch::found_parent(parent_id, &ast::IIItem(ref item)) => {
98+
csearch::FoundAst::FoundParent(parent_id, &ast::IIItem(ref item)) => {
9999
ccx.external().borrow_mut().insert(parent_id, Some(item.id));
100100
ccx.external_srcs().borrow_mut().insert(item.id, parent_id);
101101

@@ -124,11 +124,11 @@ fn instantiate_inline(ccx: &CrateContext, fn_id: ast::DefId)
124124
trans_item(ccx, &**item);
125125
local_def(my_id)
126126
}
127-
csearch::found_parent(_, _) => {
128-
ccx.sess().bug("maybe_get_item_ast returned a found_parent \
127+
csearch::FoundAst::FoundParent(_, _) => {
128+
ccx.sess().bug("maybe_get_item_ast returned a FoundParent \
129129
with a non-item parent");
130130
}
131-
csearch::found(&ast::IITraitItem(_, ref trait_item)) => {
131+
csearch::FoundAst::Found(&ast::IITraitItem(_, ref trait_item)) => {
132132
match *trait_item {
133133
ast::RequiredMethod(_) => ccx.sess().bug("found RequiredMethod IITraitItem"),
134134
ast::ProvidedMethod(ref mth) => {
@@ -147,7 +147,7 @@ fn instantiate_inline(ccx: &CrateContext, fn_id: ast::DefId)
147147
}
148148
}
149149
}
150-
csearch::found(&ast::IIImplItem(impl_did, ref impl_item)) => {
150+
csearch::FoundAst::Found(&ast::IIImplItem(impl_did, ref impl_item)) => {
151151
match *impl_item {
152152
ast::MethodImplItem(ref mth) => {
153153
ccx.external().borrow_mut().insert(fn_id, Some(mth.id));

0 commit comments

Comments
 (0)