forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sync to rust-lang/rust master #28
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Fixes some extra blank lines and makes some minor tweaks to the wording.
Make sure interned constants are immutable This makes sure that interning for constants (not statics) creates only immutable allocations. Previously, the "main" allocation of `const FOO: Cell<i32> = Cell::new(0);` was marked as mutable, but I don't think we want that. It can be only copied, not written to. Also, "leftover" allocations (behind raw pointers etc) were left mutable. I don't think we want to support that. I tried asserting that these are all already immutable (to double-check our static checks), but that failed in this one: ```rust const NON_NULL_PTR2: NonNull<u8> = unsafe { mem::transmute(&0) }; ``` Seems like maybe we want more precise mutability annotation inside Miri for locals (like `&0` here) so that this would actually become immutable to begin with? I also factored `intern_shallow` out of the visitor so that we don't have to construct a visitor when we do not plan to visit anything. That confused me at first.
… r=kennytm ci: ensure all tool maintainers are assignable on issues GitHub only allows people explicitly listed as collaborators on the repository or who commented on the issue/PR to be assignees, failing to create the issue if non-assignable people are assigned. This adds an extra check on CI to make sure all the people listed as tool maintainers can be assigned to toolstate issues. The check won't be executed on PR builds due to the lack of a valid token. r? @kennytm
fix building libstd without backtrace feature Fixes #64410 r? @alexcrichton
Fix build script sanitizer check. #64166 changed the way the sanitizer build scripts work. However, they were changed so that they switch between new-style to old-style cargo fingerprints. This trips up on rust-lang/cargo#6779. It also causes rustbuild to panic. If you build stage1 std (with sanitizers off), and then enable sanitizers, it panics. (This is because the build scripts don't declare that they need to re-run.) This PR will trip rust-lang/cargo#6779 again, unfortunately. I've been having way too many unexplained rebuilds in rust-lang/rust recently, but at least I'll know why this time. This doesn't fix all problems with the build scripts, but arguably they should be fixed in cargo. For example, the build scripts change which rerun-if statements they declare between runs which triggers rust-lang/cargo#7362. The test for this is: 1. Turn off sanitizers (which is the default) 2. `./x.py build --stage=1 src/libstd` 3. `./x.py build --stage=1 src/libstd` again should be a null build. 4. Enable sanitizers. 5. `./x.py build --stage=1 src/libstd` should rebuild with sanitizers enabled. 6. `./x.py build --stage=1 src/libstd` again should be a null build. This actually rebuilds due to rust-lang/cargo#7362 because the rerun-if directives changed between step 3 and 5. A 3rd attempt should be a null build.
when Miri tests are not passing, do not add Miri component This makes build-manifest query the toolstate repo at /~https://github.com/rust-lang-nursery/rust-toolstate to figure out if the tests of the Miri component are passing. If they are not, we remove the component from the manifest, to avoid shipping a broken Miri. I tested this locally by running build-manifest and making sure that it correctly detects the toolstate of 02785da as broken. r? @pietroalbini Cc @kennytm @alexcrichton Fixes #60301
Hide diagnostics emitted during --cfg parsing The early error is more than sufficient for fixing the problem. Fixes #31496.
Don't print the "total" `-Ztime-passes` output if `--prints=...` is also given Fixes #64339.
…, r=petrochenkov Use `Symbol` in two more functions. r? @petrochenkov
…as-schievink use println!() instead of println!("") The empty string is unnecessary.
Rollup of 10 pull requests Successful merges: - #63955 (Make sure interned constants are immutable) - #64028 (Stabilize `Vec::new` and `String::new` as `const fn`s) - #64119 (ci: ensure all tool maintainers are assignable on issues) - #64444 (fix building libstd without backtrace feature) - #64446 (Fix build script sanitizer check.) - #64451 (when Miri tests are not passing, do not add Miri component) - #64467 (Hide diagnostics emitted during --cfg parsing) - #64497 (Don't print the "total" `-Ztime-passes` output if `--prints=...` is also given) - #64499 (Use `Symbol` in two more functions.) - #64504 (use println!() instead of println!("")) Failed merges: r? @ghost
This commit disables LLVM/debug assertions in our 5 slowest builders: * i686-gnu * i686-gnu-nopt * i686-msvc-1 * i686-msvc-2 * x86_64-msvc-cargo This is reducing the amount of test coverage for LLVM/debug assertions, but we're just unfortunately running out of time on CI too many times. Some test builds have shown that i686-gnu drops nearly an hour of CI time by disabling these two assertions. Perhaps when we eventually get 4-core machines we can reenable these, but for now turn them off and hook them up to the tracking issue at #59637 which will ideally be repurposes to tracking all of these.
Old desugaring, given a user function body { $stmts; $expr } ``` { let $param_pattern0 = $raw_param0; ... let $param_patternN = $raw_paramN; $stmts; $expr } ``` New desugaring: ``` { let $param_pattern0 = $raw_param0; ... let $param_patternN = $raw_paramN; drop-temps { $stmts; $expr } } ``` The drop-temps is an internal bit of HIR that drops temporaries from the resulting expression, but it should be equivalent to `return { $stmts; $expr }`.
`AdtDef` is an algebraic data type, not abstract data type r? @varkor
update Miri Fixes #64363 r? @alexcrichton for the Cargo.toml changes: with byteorder 1.3, the `i128` feature is a NOP, so we can remove it everywhere and then get rid of this crate in the workspace-hack.
Make some adjustments to the documentation for `std::convert::identity` Fixes some extra blank lines and makes some minor tweaks to the wording.
…ice, r=oli-obk Use while let slice_pattern instead of carrying an index around r? @oli-obk
Rollup of 9 pull requests Successful merges: - #63907 (Add explanation to type mismatch involving type params and assoc types) - #64615 (rustbuild: Turn down compression on exe installers) - #64617 (rustbuild: Turn down compression on msi installers) - #64618 (rustbuild: Improve output of `dist` step) - #64619 (Fixes #63962. Hint about missing tuple parentheses in patterns) - #64634 (Update to LLVM 9.0.0) - #64635 (Allow using fn pointers in const fn with unleash miri) - #64660 (unify errors for tuple/struct variants) - #64664 (fully remove AstBuilder) Failed merges: r? @ghost
also removed some duplicated logic from TypeRelation methods.
Use span label instead of note in unreachable lint Fix #64636.
Update clippy and rls r? @oli-obk cc @Manishearth
Fix `Stdio::piped` example code and lint Summary: Invoking `rev` does not add a trailing newline when none is present in the input (at least on my Debian). Nearby examples use `echo` rather than `rev`, which probably explains the source of the discrepancy. Also, a `mut` qualifier is unused. Test Plan: Copy the code block into <https://play.rust-lang.org> with a `fn main` wrapper, and run it. Note that it compiles and runs cleanly; prior to this commit, it would emit an `unused_mut` warning and then panic. wchargin-branch: stdio-piped-docs
…henkov Cleanup syntax::ext::build I suspect most of this code could be inlined but I only removed the bits where the inlining didn't really hurt readability (i.e., method call -> function call) or the completely unused code.
…ochenkov Parse assoc type bounds in generic params and provide custom diagnostic Fix #26271.
remove outdated comment
Clarify the "since" tidy check r? @pietroalbini cc @alexreg
Rollup of 7 pull requests Successful merges: - #64294 (Fix `Stdio::piped` example code and lint) - #64670 (Cleanup syntax::ext::build) - #64674 (Propagate `types.err` in locals further to avoid spurious knock-down errors) - #64676 (Parse assoc type bounds in generic params and provide custom diagnostic) - #64677 (remove outdated comment) - #64679 (Infer consts more consistently) - #64688 (Clarify the "since" tidy check) Failed merges: r? @ghost
Refactor librustc_errors::Handler API This should be reviewed by-commit. The last commit moves all fields into an inner struct behind a single lock; this is done to prevent possible deadlocks in a multi-threaded compiler, as well as inconsistent state observation.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.