1. 24 9月, 2020 17 次提交
  2. 23 9月, 2020 23 次提交
    • B
      Auto merge of #77090 - rust-lang:revert-76110-convert-openoptions-cint, r=dtolnay · a6008fac
      bors 提交于
      Revert "Function to convert OpenOptions to c_int"
      
      Reverts rust-lang/rust#76110. This broke Rust's stability guarantees.
      
      Closes https://github.com/rust-lang/rust/issues/77089.
      
      r? `@joshtriplett`
      a6008fac
    • D
      Rollup merge of #77055 - est31:more_track_caller, r=Mark-Simulacrum · c3c03f2f
      Dylan DPC 提交于
      Add #[track_caller] to more panicking Cell functions
      
      Continuation of #74526
      
      Adds the #[track_caller] attribute to almost all panicking Cell
      functions. The ones that borrow two Cells in their function
      body are spared, because the panic location helps pinpoint
      which of the two borrows failed. You'd need to have
      full debuginfo and backtraces enabled together with column
      info in order to be able to discern the cases.
      Column info in debuginfo is only available on non-Windows platforms.
      c3c03f2f
    • D
      Rollup merge of #77047 - RalfJung:miri-dealloc, r=oli-obk · f8dec3d0
      Dylan DPC 提交于
      Miri: more informative deallocation error messages
      
      Make sure we show the affected AllocId.
      
      r? @oli-obk
      f8dec3d0
    • D
      Rollup merge of #77042 - imbolc:patch-2, r=kennytm · 049ba0c6
      Dylan DPC 提交于
      Improve documentation for ToSocketAddrs
      
      I little clarification
      049ba0c6
    • D
      Rollup merge of #77017 - GuillaumeGomez:vec-missing-examples-iter, r=Dylan-DPC · b7634364
      Dylan DPC 提交于
      Add missing examples on Vec iter types
      
      r? @Dylan-DPC
      b7634364
    • D
      Rollup merge of #76994 - yuk1ty:fix-small-typo, r=estebank · bcdbe79f
      Dylan DPC 提交于
      fix small typo in docs and comments
      
      Fixed `the the` to `the`, as far as I found.
      bcdbe79f
    • D
      Rollup merge of #76993 - blitzerr:alloc-ref, r=Amanieu · a40d79c9
      Dylan DPC 提交于
      Changing the alloc() to accept &self instead of &mut self
      
      Fixes: [#55](https://github.com/rust-lang/wg-allocators/issues/55)
      
      This is the first cut. It only makes the change for `alloc` method.
      a40d79c9
    • D
      Rollup merge of #76965 - fusion-engineering-forks:fix-atomic-from-mut, r=Amanieu · eaaf5d7e
      Dylan DPC 提交于
      Add cfg(target_has_atomic_equal_alignment) and use it for Atomic::from_mut.
      
      Fixes some platform-specific problems with #74532 by using the actual alignment of the types instead of hardcoding a few `target_arch`s.
      
      r? @RalfJung
      eaaf5d7e
    • D
      Rollup merge of #76939 - lcnr:const-evaluatable-cont, r=oli-obk · 98e5ee7d
      Dylan DPC 提交于
      emit errors during AbstractConst building
      
      There changes are currently still untested, so I don't expect this to pass CI 😆
      
      It seems to me like this is the direction we want to go in, though we didn't have too much of a discussion about this.
      
      r? @oli-obk
      98e5ee7d
    • D
      Rollup merge of #76898 - Aaron1011:fix/item-def-span, r=oli-obk · a22eb316
      Dylan DPC 提交于
      Record `tcx.def_span` instead of `item.span` in crate metadata
      
      This was missed in PR #75465. As a result, a few places have been using
      the full body span of functions, instead of just the header span.
      a22eb316
    • B
      Auto merge of #76864 - est31:downloaded_llvm_no_clone_sources, r=Mark-Simulacrum · 33aa8be8
      bors 提交于
      Don't download/sync llvm-project submodule if download-ci-llvm is set
      
      llvm-project takes > 1GB storage space and a long time to download.
      It's better to not download it unless needed.
      33aa8be8
    • B
      Auto merge of #76659 - simonvandel:76432, r=oli-obk · feca2c22
      bors 提交于
      SimplifyComparisonIntegral: fix miscompilation
      
      Fixes #76432
      Only insert StorageDeads if we actually removed one.
      Fixes an issue where we added StorageDead to a place with no StorageLive
      
      r? `@oli-obk`
      feca2c22
    • A
      Move MiniSet to data_structures · 6586c37b
      Andreas Jonson 提交于
      remove the need for T to be copy from MiniSet as was done for MiniMap
      6586c37b
    • B
      Auto merge of #76850 - ecstatic-morse:const-checking-refactor, r=oli-obk · f6d59207
      bors 提交于
      Remove `qualify_min_const_fn`
      
      ~~Blocked on #76807 (the first six commits).~~
      
      With this PR, all checks in `qualify_min_const_fn` are replicated in `check_consts`, and the former is no longer invoked. My goal was to have as few changes to test output as possible, since making sweeping changes to the code *while* doing big batches of diagnostics updates turned out to be a headache. To this end, there's a few `HACK`s in `check_consts` to achieve parity with `qualify_min_const_fn`.
      
      The new system that replaces `is_min_const_fn` is referred to as "const-stability"  My end goal for the const-stability rules is this:
      * Const-stability is only applicable to functions defined in `staged_api` crates.
      * All functions not marked `rustc_const_unstable` are considered "const-stable".
          - NB. This is currently not implemented. `#[unstable]` functions are also const-unstable. This causes problems when searching for feature gates.
          - All "const-unstable" functions have an associated feature gate
      * const-stable functions can only call other const-stable functions
           - `allow_internal_unstable` can be used to circumvent this.
      * All const-stable functions are subject to some additional checks (the ones that were unique to `qualify_min_const_fn`)
      
      The plan is to remove each `HACK` individually in subsequent PRs. That way, changes to error message output can be reviewed in isolation.
      f6d59207
    • B
      a few more &mut self -> self changes · 2b19b14c
      blitzerr 提交于
      2b19b14c
    • B
      fixing the test failure · 985dff9e
      blitzerr 提交于
      985dff9e
    • J
      Revert "Function to convert OpenOptions to c_int" · 15f08d6d
      Joshua Nelson 提交于
      15f08d6d
    • B
      Auto merge of #77063 - cuviper:llvm-11.0.0-rc3, r=nikic · e62323df
      bors 提交于
      Rebase LLVM onto 11.0.0-rc3
      
      r? `@nikic`
      e62323df
    • A
      revert const_type_id stabilization · 9b2c8d86
      Ashley Mannix 提交于
      This reverts commit e3856616.
      9b2c8d86
    • B
      Auto merge of #76928 - lcnr:opaque-types-cache, r=tmandry · 6d3acf51
      bors 提交于
      cache types during normalization
      
      partially fixes #75992
      
      reduces the following test from 14 to 3 seconds locally.
      
      cc `@Mark-Simulacrum` would it make sense to add that test to `perf`?
      ```rust
      #![recursion_limit="2048"]
      #![type_length_limit="112457564"]
      
      pub async fn h0(v: &String, x: &u64) { println!("{} {}", v, x) }
      pub async fn h1(v: &String, x: &u64) { h0(v, x).await }
      pub async fn h2(v: &String, x: &u64) { h1(v, x).await }
      pub async fn h3(v: &String, x: &u64) { h2(v, x).await }
      pub async fn h4(v: &String, x: &u64) { h3(v, x).await }
      pub async fn h5(v: &String, x: &u64) { h4(v, x).await }
      pub async fn h6(v: &String, x: &u64) { h5(v, x).await }
      pub async fn h7(v: &String, x: &u64) { h6(v, x).await }
      pub async fn h8(v: &String, x: &u64) { h7(v, x).await }
      pub async fn h9(v: &String, x: &u64) { h8(v, x).await }
      
      pub async fn h10(v: &String, x: &u64) { h9(v, x).await }
      pub async fn h11(v: &String, x: &u64) { h10(v, x).await }
      pub async fn h12(v: &String, x: &u64) { h11(v, x).await }
      pub async fn h13(v: &String, x: &u64) { h12(v, x).await }
      pub async fn h14(v: &String, x: &u64) { h13(v, x).await }
      pub async fn h15(v: &String, x: &u64) { h14(v, x).await }
      pub async fn h16(v: &String, x: &u64) { h15(v, x).await }
      pub async fn h17(v: &String, x: &u64) { h16(v, x).await }
      pub async fn h18(v: &String, x: &u64) { h17(v, x).await }
      pub async fn h19(v: &String, x: &u64) { h18(v, x).await }
      
      macro_rules! async_recursive {
          (29, $inner:expr) => { async { async_recursive!(28, $inner) }.await };
          (28, $inner:expr) => { async { async_recursive!(27, $inner) }.await };
          (27, $inner:expr) => { async { async_recursive!(26, $inner) }.await };
          (26, $inner:expr) => { async { async_recursive!(25, $inner) }.await };
          (25, $inner:expr) => { async { async_recursive!(24, $inner) }.await };
          (24, $inner:expr) => { async { async_recursive!(23, $inner) }.await };
          (23, $inner:expr) => { async { async_recursive!(22, $inner) }.await };
          (22, $inner:expr) => { async { async_recursive!(21, $inner) }.await };
          (21, $inner:expr) => { async { async_recursive!(20, $inner) }.await };
          (20, $inner:expr) => { async { async_recursive!(19, $inner) }.await };
      
          (19, $inner:expr) => { async { async_recursive!(18, $inner) }.await };
          (18, $inner:expr) => { async { async_recursive!(17, $inner) }.await };
          (17, $inner:expr) => { async { async_recursive!(16, $inner) }.await };
          (16, $inner:expr) => { async { async_recursive!(15, $inner) }.await };
          (15, $inner:expr) => { async { async_recursive!(14, $inner) }.await };
          (14, $inner:expr) => { async { async_recursive!(13, $inner) }.await };
          (13, $inner:expr) => { async { async_recursive!(12, $inner) }.await };
          (12, $inner:expr) => { async { async_recursive!(11, $inner) }.await };
          (11, $inner:expr) => { async { async_recursive!(10, $inner) }.await };
          (10, $inner:expr) => { async { async_recursive!(9, $inner) }.await };
      
          (9, $inner:expr) => { async { async_recursive!(8, $inner) }.await };
          (8, $inner:expr) => { async { async_recursive!(7, $inner) }.await };
          (7, $inner:expr) => { async { async_recursive!(6, $inner) }.await };
          (6, $inner:expr) => { async { async_recursive!(5, $inner) }.await };
          (5, $inner:expr) => { async { async_recursive!(4, $inner) }.await };
          (4, $inner:expr) => { async { async_recursive!(3, $inner) }.await };
          (3, $inner:expr) => { async { async_recursive!(2, $inner) }.await };
          (2, $inner:expr) => { async { async_recursive!(1, $inner) }.await };
          (1, $inner:expr) => { async { async_recursive!(0, $inner) }.await };
          (0, $inner:expr) => { async { h19(&String::from("owo"), &0).await; $inner }.await };
      }
      
      async fn f() {
          async_recursive!(14, println!("hello"));
      }
      
      fn main() {
          let _ = f();
      }
      ```
      r? `@EddyB` requires a perf run.
      6d3acf51
    • S
      rebless after rebase · ff241633
      Simon Vandel Sillesen 提交于
      ff241633
    • S
      cleanup cfg after optimization · b6f51d6d
      Simon Vandel Sillesen 提交于
      b6f51d6d
    • S
      f472303a