- 24 9月, 2020 2 次提交
-
-
由 bors 提交于
MIR pass to remove unneeded drops on types not needing drop This is heavily dependent on MIR inlining running to actually see the drop statement. Do we want to special case replacing a call to std::mem::drop with a goto aswell?
-
由 Simon Vandel Sillesen 提交于
-
- 23 9月, 2020 28 次提交
-
-
由 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`
-
由 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.
-
由 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`
-
由 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.
-
由 Joshua Nelson 提交于
-
由 bors 提交于
Rebase LLVM onto 11.0.0-rc3 r? `@nikic`
-
由 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.
-
由 Simon Vandel Sillesen 提交于
-
由 Simon Vandel Sillesen 提交于
-
由 Simon Vandel Sillesen 提交于
-
由 Simon Vandel Sillesen 提交于
-
由 Simon Vandel Sillesen 提交于
Co-authored-by: NAndreas Jonson <andjo403@users.noreply.github.com>
-
由 Simon Vandel Sillesen 提交于
This is heavily dependent on MIR inlining running to actually see the drop statement
-
由 bors 提交于
Don't dynamically link LLVM tools unless rustc is too This PR initially tried to support link-shared on all of our target platforms (other than Windows), but ran into a number of difficulties: * LLVM doesn't really support a shared link on macOS (llvm-config runs into problems with the version suffix) * LLVM doesn't seem to support a shared link when cross-compiling (the libLLVM.so ends up empty and symbols are not found) So, this PR has now been revised such that we don't attempt to dynamically link LLVM tools (even if that would, otherwise, be supported) on targets where LLVM is statically linked to rustc. Currently that's basically everything except for x86_64-unknown-linux-gnu (where we dynamically link to avoid rerunning ThinLTO in each stage). Follow-up to #76708. Fixes #76698.
-
由 Dylan MacKenzie 提交于
-
由 Dylan MacKenzie 提交于
-
由 Josh Stone 提交于
-
由 Dylan MacKenzie 提交于
-
由 Dylan MacKenzie 提交于
-
由 Dylan MacKenzie 提交于
-
由 Dylan MacKenzie 提交于
-
由 Dylan MacKenzie 提交于
-
由 Dylan MacKenzie 提交于
-
由 Dylan MacKenzie 提交于
This is a hack for parity with `qualify_min_const_fn`, which only emitted a single error.
-
由 Dylan MacKenzie 提交于
-
由 Dylan MacKenzie 提交于
-
由 Dylan MacKenzie 提交于
This may not be strictly minimal, but all unstable functions also need a `rustc_const_unstable` attribute.
-
由 Dylan MacKenzie 提交于
-
- 22 9月, 2020 10 次提交
-
-
由 bors 提交于
Function to convert OpenOptions to c_int Fixes: #74943 The creation_mode and access_mode function were already available in the OpenOptions struct, but currently private. I've added a new free functions to unix/fs.rs which takes the OpenOptions, and returns the c_int to be used as parameter for the `open` call.
-
由 bors 提交于
Add a changelog for x.py and nag contributors until they read it Add a changelog for x.py - Add a changelog and instructions for updating it - Use `changelog-seen` in `config.toml` and `VERSION` in bootstrap to determine whether the changelog has been read. There's no way to tie reading the changelog to updating the version, so unfortunately they still have to update `config.toml` manually. Actually reading the changelog is optional, anyone can set `changelog-seen = N` without reading (although it's not recommended). - Nag people if they haven't read the x.py changelog + Print message twice to make sure it's seen - Give different error messages depending on whether the version needs to be updated or added Closes https://github.com/rust-lang/rust/issues/76617 r? `@Mark-Simulacrum`
-
由 Federico Ponzi 提交于
-
由 bors 提交于
Split rustc_typeck::check into separate files Contributing to #60302.
-
由 bors 提交于
Fix cross compiling dist/build invocations I am uncertain why the first commit is not affecting CI. I suspect it's because we pass --disable-docs on most of our cross-compilation builders. The second commit doesn't affect CI because CI runs x.py dist, not x.py build. Both commits are standalone; together they should resolve #76733. The first commit doesn't really fix that issue but rather just fixes cross-compiled x.py dist, resolving a bug introduced in #76549.
-
由 bors 提交于
Rollup of 13 pull requests Successful merges: - #72734 (Reduce duplicate in liballoc reserve error handling) - #76131 (Don't use `zip` to compare iterators during pretty-print hack) - #76150 (Don't recommend ManuallyDrop to customize drop order) - #76275 (Implementation of Write for some immutable ref structs) - #76489 (Add explanation for E0756) - #76581 (do not ICE on bound variables, return `TooGeneric` instead) - #76655 (Make some methods of `Pin` unstable const) - #76783 (Only get ImplKind::Impl once) - #76807 (Use const-checking to forbid use of unstable features in const-stable functions) - #76888 (use if let instead of single match arm expressions) - #76914 (extend `Ty` and `TyCtxt` lints to self types) - #77022 (Reduce boilerplate for BytePos and CharPos) - #77032 (lint missing docs for extern items) Failed merges: r? `@ghost`
-
由 ecstatic-morse 提交于
lint missing docs for extern items fixes #76991
-
由 ecstatic-morse 提交于
Reduce boilerplate for BytePos and CharPos Reduces boilerplate code for BytePos and CharPos by using a macro to implement shared traits.
-
由 ecstatic-morse 提交于
extend `Ty` and `TyCtxt` lints to self types blocked on #76891 r? @ecstatic-morse cc @Aaron1011
-
由 ecstatic-morse 提交于
use if let instead of single match arm expressions use if let instead of single match arm expressions to compact code and reduce nesting (clippy::single_match)
-