diff options
| author | bors <bors@rust-lang.org> | 2021-03-03 08:36:46 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2021-03-03 08:36:46 +0000 |
| commit | 770ed1cf4bff98345df4f9f54754d6f4bc84559f (patch) | |
| tree | 3dc1b1fa3dd555c339d458ff473362e1e5b041b4 /compiler | |
| parent | cbca5689a5a0c63c6c5fda22bb0678164b52fec3 (diff) | |
| parent | 374c90b4c6d9c0c2532b525ac4b4a8d1408e097d (diff) | |
| download | rust-770ed1cf4bff98345df4f9f54754d6f4bc84559f.tar.gz rust-770ed1cf4bff98345df4f9f54754d6f4bc84559f.zip | |
Auto merge of #82718 - JohnTitor:rollup-vpfx3j2, r=JohnTitor
Rollup of 10 pull requests Successful merges: - #81223 ([rustdoc] Generate redirect map file) - #82439 (BTree: fix untrue safety) - #82469 (Use a crate to produce rustdoc tree comparisons instead of the `diff` command) - #82589 (unix: Non-mutable bufs in send_vectored_with_ancillary_to) - #82689 (meta: Notify Zulip for rustdoc nominated issues) - #82695 (Revert non-power-of-two vector restriction) - #82706 (use outer_expn_data() instead of outer_expn().expn_data()) - #82710 (FloatToInit: Replacing round_unchecked_to --> to_int_unchecked) - #82712 (Remove unnecessary conditional `cfg(target_os)` for `redox` and `vxworks`) - #82713 (Update cargo) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'compiler')
| -rw-r--r-- | compiler/rustc_middle/src/ty/layout.rs | 5 | ||||
| -rw-r--r-- | compiler/rustc_resolve/src/lib.rs | 2 | ||||
| -rw-r--r-- | compiler/rustc_typeck/src/check/check.rs | 9 |
3 files changed, 1 insertions, 15 deletions
diff --git a/compiler/rustc_middle/src/ty/layout.rs b/compiler/rustc_middle/src/ty/layout.rs index 725c144257c..6d2ab0e5f5a 100644 --- a/compiler/rustc_middle/src/ty/layout.rs +++ b/compiler/rustc_middle/src/ty/layout.rs @@ -732,11 +732,6 @@ impl<'tcx> LayoutCx<'tcx, TyCtxt<'tcx>> { // Can't be caught in typeck if the array length is generic. if e_len == 0 { tcx.sess.fatal(&format!("monomorphising SIMD type `{}` of zero length", ty)); - } else if !e_len.is_power_of_two() { - tcx.sess.fatal(&format!( - "monomorphising SIMD type `{}` of non-power-of-two length", - ty - )); } else if e_len > MAX_SIMD_LANES { tcx.sess.fatal(&format!( "monomorphising SIMD type `{}` of length greater than {}", diff --git a/compiler/rustc_resolve/src/lib.rs b/compiler/rustc_resolve/src/lib.rs index e63fd4ce635..7aee718bfa9 100644 --- a/compiler/rustc_resolve/src/lib.rs +++ b/compiler/rustc_resolve/src/lib.rs @@ -1422,7 +1422,7 @@ impl<'a> Resolver<'a> { fn macro_def(&self, mut ctxt: SyntaxContext) -> DefId { loop { - match ctxt.outer_expn().expn_data().macro_def_id { + match ctxt.outer_expn_data().macro_def_id { Some(def_id) => return def_id, None => ctxt.remove_mark(), }; diff --git a/compiler/rustc_typeck/src/check/check.rs b/compiler/rustc_typeck/src/check/check.rs index 5d7f5bf1c7b..0010d59f710 100644 --- a/compiler/rustc_typeck/src/check/check.rs +++ b/compiler/rustc_typeck/src/check/check.rs @@ -1161,15 +1161,6 @@ pub fn check_simd(tcx: TyCtxt<'_>, sp: Span, def_id: LocalDefId) { if len == 0 { struct_span_err!(tcx.sess, sp, E0075, "SIMD vector cannot be empty").emit(); return; - } else if !len.is_power_of_two() { - struct_span_err!( - tcx.sess, - sp, - E0075, - "SIMD vector length must be a power of two" - ) - .emit(); - return; } else if len > MAX_SIMD_LANES { struct_span_err!( tcx.sess, |
