Skip to content

Commit b4b71d5

Browse files
committed
Merge branch 'master' of https://github.com/nicokoch/rust
2 parents 834ef9f + eca0da5 commit b4b71d5

Some content is hidden

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

45 files changed

+440
-369
lines changed

src/Cargo.lock

Lines changed: 4 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/doc/unstable-book/src/language-features/macro-lifetime-matcher.md

Lines changed: 0 additions & 14 deletions
This file was deleted.

src/etc/generate-deriving-span-tests.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ def write_file(name, string):
122122

123123
for (trait, supers, errs) in [('Clone', [], 1),
124124
('PartialEq', [], 2),
125-
('PartialOrd', ['PartialEq'], 5),
125+
('PartialOrd', ['PartialEq'], 1),
126126
('Eq', ['PartialEq'], 1),
127127
('Ord', ['Eq', 'PartialOrd', 'PartialEq'], 1),
128128
('Debug', [], 1),

src/librustc/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
#![feature(from_ref)]
5151
#![feature(fs_read_write)]
5252
#![cfg_attr(windows, feature(libc))]
53-
#![feature(macro_lifetime_matcher)]
53+
#![cfg_attr(stage0, feature(macro_lifetime_matcher))]
5454
#![feature(macro_vis_matcher)]
5555
#![feature(never_type)]
5656
#![feature(exhaustive_patterns)]

src/librustc/ty/layout.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -888,6 +888,11 @@ impl<'a, 'tcx> LayoutCx<'tcx, TyCtxt<'a, 'tcx, 'tcx>> {
888888
if x < min { min = x; }
889889
if x > max { max = x; }
890890
}
891+
// We might have no inhabited variants, so pretend there's at least one.
892+
if (min, max) == (i128::max_value(), i128::min_value()) {
893+
min = 0;
894+
max = 0;
895+
}
891896
assert!(min <= max, "discriminant range is {}...{}", min, max);
892897
let (min_ity, signed) = Integer::repr_discr(tcx, ty, &def.repr, min, max);
893898

src/librustc_metadata/lib.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,8 @@
1515
#![feature(box_patterns)]
1616
#![feature(fs_read_write)]
1717
#![feature(libc)]
18-
#![feature(macro_lifetime_matcher)]
18+
#![cfg_attr(stage0, feature(macro_lifetime_matcher))]
1919
#![feature(proc_macro_internals)]
20-
#![feature(macro_lifetime_matcher)]
2120
#![feature(quote)]
2221
#![feature(rustc_diagnostic_macros)]
2322
#![feature(slice_sort_by_cached_key)]

src/librustc_save_analysis/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
html_favicon_url = "https://doc.rust-lang.org/favicon.ico",
1313
html_root_url = "https://doc.rust-lang.org/nightly/")]
1414
#![feature(custom_attribute)]
15-
#![feature(macro_lifetime_matcher)]
15+
#![cfg_attr(stage0, feature(macro_lifetime_matcher))]
1616
#![allow(unused_attributes)]
1717

1818
#[macro_use]

src/librustc_trans/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ crate-type = ["dylib"]
1010
test = false
1111

1212
[dependencies]
13+
bitflags = "1.0.1"
1314
cc = "1.0.1"
1415
flate2 = "1.0"
1516
jobserver = "0.1.5"

src/librustc_trans/abi.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
use llvm::{self, ValueRef, AttributePlace};
1212
use base;
13-
use builder::Builder;
13+
use builder::{Builder, MemFlags};
1414
use common::{ty_fn_sig, C_usize};
1515
use context::CodegenCx;
1616
use mir::place::PlaceRef;
@@ -220,7 +220,8 @@ impl<'a, 'tcx> ArgTypeExt<'a, 'tcx> for ArgType<'tcx, Ty<'tcx>> {
220220
bx.pointercast(dst.llval, Type::i8p(cx)),
221221
bx.pointercast(llscratch, Type::i8p(cx)),
222222
C_usize(cx, self.layout.size.bytes()),
223-
self.layout.align.min(scratch_align));
223+
self.layout.align.min(scratch_align),
224+
MemFlags::empty());
224225

225226
bx.lifetime_end(llscratch, scratch_size);
226227
}

0 commit comments

Comments
 (0)