Skip to content

Commit

Permalink
Auto merge of #67104 - Centril:rollup-07vahh9, r=Centril
Browse files Browse the repository at this point in the history
Rollup of 10 pull requests

Successful merges:

 - #66606 (Add feature gate for mut refs in const fn)
 - #66841 (Add `{f32,f64}::approx_unchecked_to<Int>` unsafe methods)
 - #67009 (Emit coercion suggestions in more places)
 - #67052 (Ditch `parse_in_attr`)
 - #67071 (Do not ICE on closure typeck)
 - #67078 (accept union inside enum if not followed by identifier)
 - #67090 (Change "either" to "any" in Layout::from_size_align's docs)
 - #67092 (Fix comment typos in src/libcore/alloc.rs)
 - #67094 (get rid of __ in field names)
 - #67102 (Add note to src/ci/docker/README.md about multiple docker images)

Failed merges:

 - #67101 (use `#[allow(unused_attributes)]` to paper over incr.comp problem)

r? @ghost
  • Loading branch information
bors committed Dec 6, 2019
2 parents ae1b871 + dbc9f30 commit 41601a8
Show file tree
Hide file tree
Showing 80 changed files with 1,278 additions and 688 deletions.
7 changes: 7 additions & 0 deletions src/ci/docker/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,13 @@ for example:

Images will output artifacts in an `obj` dir at the root of a repository.

**NOTE**: Re-using the same `obj` dir with different docker images with
the same target triple (e.g. `dist-x86_64-linux` and `dist-various-1`)
may result in strange linker errors, due shared library versions differing between platforms.

If you encounter any issues when using multiple Docker images, try deleting your `obj` directory
before running your command.

## Filesystem layout

- Each directory, excluding `scripts` and `disabled`, corresponds to a docker image
Expand Down
6 changes: 3 additions & 3 deletions src/libcore/alloc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ pub struct Layout {

impl Layout {
/// Constructs a `Layout` from a given `size` and `align`,
/// or returns `LayoutErr` if either of the following conditions
/// or returns `LayoutErr` if any of the following conditions
/// are not met:
///
/// * `align` must not be zero,
Expand Down Expand Up @@ -137,7 +137,7 @@ impl Layout {
#[inline]
pub fn for_value<T: ?Sized>(t: &T) -> Self {
let (size, align) = (mem::size_of_val(t), mem::align_of_val(t));
// See rationale in `new` for why this us using an unsafe variant below
// See rationale in `new` for why this is using an unsafe variant below
debug_assert!(Layout::from_size_align(size, align).is_ok());
unsafe {
Layout::from_size_align_unchecked(size, align)
Expand Down Expand Up @@ -196,7 +196,7 @@ impl Layout {
// valid.
//
// 2. `len + align - 1` can overflow by at most `align - 1`,
// so the &-mask wth `!(align - 1)` will ensure that in the
// so the &-mask with `!(align - 1)` will ensure that in the
// case of overflow, `len_rounded_up` will itself be 0.
// Thus the returned padding, when added to `len`, yields 0,
// which trivially satisfies the alignment `align`.
Expand Down
5 changes: 5 additions & 0 deletions src/libcore/convert.rs → src/libcore/convert/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@
#![stable(feature = "rust1", since = "1.0.0")]

mod num;

#[unstable(feature = "convert_float_to_int", issue = "67057")]
pub use num::FloatToInt;

/// The identity function.
///
/// Two things are important to note about this function:
Expand Down
Loading

0 comments on commit 41601a8

Please sign in to comment.