about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorLines
2019-10-31Rollup merge of #65959 - vext01:immediate-docstring, r=davidtwcoMazdak Farrokhzad-1/+1
Fix an incorrect docstring for Immediate in librustc_mir/interpret. I suspect `Immediate` was once called `Value`?
2019-10-31Rollup merge of #65955 - pietroalbini:master-revert-msys2-hack, ↵Mazdak Farrokhzad-16/+0
r=Mark-Simulacrum ci: revert msys2 ca-certificates hack The hack was added because upstream msys2 broke the ca-certificates package, but since then it has been fixed. This reverts CI to use the upstream package. Part of #65767
2019-10-31Rollup merge of #65850 - mikeyhew:patch-1, r=nikomatsakisMazdak Farrokhzad-5/+7
Update comments re type parameter hack in object safety To check if a method's receiver type is object safe, we create a new receiver type by substituting in a bogus type parameter (let's call it `U`) for `Self`, and checking that the unmodified receiver type implements `DispatchFromDyn<receiver type with Self = U>`. It would be better to use `dyn Trait` directly, and the only reason we don't is because it triggers another check that `Trait` is object safe, resulting in a query cycle. Once the feature `object_safe_for_dispatch` (tracking issue https://github.com/rust-lang/rust/issues/43561) is stabilized, this will no longer be the case, and we'll be able to use `dyn Trait` as the unsized `Self` type. I've updated the comments in object_safety.rs accordingly. cc @Centril @nikomatsakis @bovinebuddha
2019-10-31Rollup merge of #65434 - GuillaumeGomez:long-err-explanation-E0577, r=Dylan-DPCMazdak Farrokhzad-2/+29
Add long error explanation for E0577 Part of #61137. r? @kinnison
2019-10-31Rollup merge of #65274 - pietroalbini:ci-upload-toolstate, r=alexcrichtonMazdak Farrokhzad-35/+73
Upload toolstates.json to rust-lang-ci2 This PR does two things: * Following up with https://github.com/rust-lang/rust/pull/65202, it migrates deploying artifacts to CI in a script. Both uploading release artifacts and CPU stats were merged into the same script, designing it to be easily extended. * Uploads the toolstate JSON to `rust-lang-ci2` along with the release artifacts, both for Linux and Windows. This is needed because @RalfJung wants to stop shipping MIRI when its tests are failing, and the toolstate repo doesn't have entries for each commit. Having the toolstate data (just for that specific commit) on `rust-lang-ci2` will simplify the code a lot. r? @alexcrichton cc @RalfJung
2019-10-30ci: move toolstates.json to /tmp/toolstate/ and docker mount itPietro Albini-6/+13
Before this commit toolstates.json was stored in /tmp and it wasn't mounted outside the build container. That caused uploading the file in the upload-artifacts task to fail, as the file was missing on the host. Mounting /tmp/toolstates.json alone is not the best approach: if the file is missing when the container is started the Docker engine will create a *directory* named /tmp/toolstates.json. The Docker issue could be solved by pre-creating an empty file named /tmp/toolstates.json, but doing that could cause problems if bootstrap fails to generate the file and the toolstate scripts receive an empty JSON. The approach I took in this commit is to instead mount a /tmp/toolstate directory inside Docker, and create the toolstates.json file in it. That also required a small bootstrap change to ensure the directory is created if it's missing.
2019-10-30Update ui testsGuillaume Gomez-1/+2
2019-10-30Add long error explanation for E0577Guillaume Gomez-1/+27
2019-10-30Auto merge of #65941 - ehuss:update-cargo-books, r=alexcrichtonbors-0/+0
Update cargo, books. ## cargo 8 commits in 3ba5f27170db10af7a92f2b682e049397197b8fa..5da4b4d47963868d9878480197581ccbbdaece74 2019-10-22 15:05:18 +0000 to 2019-10-28 21:53:41 +0000 - Add --filter-platform to `cargo metadata`. (rust-lang/cargo#7376) - Fix `cargo fix` not showing colors. (rust-lang/cargo#7550) - Rephrase --manifest-path section (rust-lang/cargo#7409) - Add a note to discourage the use of -Zminimal-versions. (rust-lang/cargo#7549) - Fix profile override warning in a workspace. (rust-lang/cargo#7536) - Fix some tests failing on Windows nightly. (rust-lang/cargo#7534) - Show better error message for Windows abnormal termination. (rust-lang/cargo#7535) - Run `apt update` before `apt install` (rust-lang/cargo#7541) ## reference 8 commits in 5b9d2fcefadfc32fceafacfc0dd9441d9b57dd94..4b21b646669e0af49fae7cae301898dc4bfaa1f0 2019-10-03 22:39:10 +0200 to 2019-10-27 22:33:11 +0100 - Document `const_constructor` feature (rust-lang-nursery/reference#677) - Add `non_exhaustive` to reference. (rust-lang-nursery/reference#609) - Re-add rust-docs component for lintcheck (rust-lang-nursery/reference#702) - group signed and unsigned integers in layout table (rust-lang-nursery/reference#700) - Fix layout table rendering (rust-lang-nursery/reference#699) - Add reference for attributes in function parameters (rust-lang-nursery/reference#657) - Update now that proc macros can expand to macro_rules. (rust-lang-nursery/reference#694) - Fix match in union example. (rust-lang-nursery/reference#684) ## book 8 commits in 9bb8b161963fcebc9d9ccd732ba26f42108016d5..28fa3d15b0bc67ea5e79eeff2198e4277fc61baf 2019-10-14 18:42:55 -0500 to 2019-10-29 07:16:09 -0500 - Update Ch19.1 on slice splitting (rust-lang/book#1999) - fixed inconsistent terminology regarding enums (rust-lang/book#2022) - Update ch15-03 code to match output. (rust-lang/book#2020) - Fixes rust-lang/book#2039 (rust-lang/book#2040) - Update ch15-03-drop.md (rust-lang/book#2049) - unit type value is also a value (rust-lang/book#2061) - Minor: remove an extraneous `.` (rust-lang/book#2059) - Clarifications and consistent use of quotation marks (rust-lang/book#1992) ## rust-by-example 4 commits in 0b111eaae36cc4b4997684be853882a59e2c7ca7..f3197ddf2abab9abdbc029def8164f4a748b0d91 2019-10-14 18:34:25 -0300 to 2019-10-29 10:17:40 -0300 - Fix typos (rust-lang/rust-by-example#1285) - Improve Cargo / Dependencies section (rust-lang/rust-by-example#1287) - Improve Cargo / Build Scripts section (rust-lang/rust-by-example#1288) - Make if_let exercise runnable (rust-lang/rust-by-example#1289)
2019-10-30Fix an incorrect docstring for Immediate in librustc_mir/interpret.Edd Barrett-1/+1
2019-10-30ci: revert msys2 ca-certificates hackPietro Albini-16/+0
The hack was added because upstream msys2 broke the ca-certificates package, but since then it has been fixed. This reverts CI to use the upstream package.
2019-10-30Auto merge of #65068 - estebank:trait-impl-lt-mismatch, r=nikomatsakisbors-53/+115
Custom lifetime error for `impl` item doesn't conform to `trait` Partly addresses #42706, #41343, fix #40900.
2019-10-29Auto merge of #65943 - tmandry:rollup-g20uvkh, r=tmandrybors-190/+291
Rollup of 12 pull requests Successful merges: - #65405 (Create new error E0742 and add long error explanation) - #65539 (resolve: Turn the "non-empty glob must import something" error into a lint) - #65724 (ci: refactor pr tools job skipping) - #65741 (Prevent help popup to disappear when clicking on it) - #65832 (Re-enable Emscripten's exception handling support) - #65843 (Enable dist for MIPS64 musl targets) - #65898 (add basic HermitCore support within libtest) - #65900 (proc_macro: clean up bridge::client::__run_expand{1,2} a bit.) - #65906 (Update mdbook to 0.3.3) - #65920 (Use rustc-workspace-hack for rustbook) - #65930 (doc: use new feature gate for c_void type) - #65936 (save-analysis: Account for async desugaring in async fn return types) Failed merges: - #65434 (Add long error explanation for E0577) r? @ghost
2019-10-29Rollup merge of #65936 - Xanewok:save-analysis-async, r=nikomatsakisTyler Mandry-4/+44
save-analysis: Account for async desugaring in async fn return types Closes #65590 When visiting the return type of an async function we need to take into account its desugaring, since it introduces a new definition under which the return type is redefined. r? @nikomatsakis
2019-10-29Rollup merge of #65930 - lzutao:new-feature-gate-c_void, r=dtolnayTyler Mandry-2/+7
doc: use new feature gate for c_void type Closes #63694, closes #55619
2019-10-29Rollup merge of #65920 - smaeul:patch/workspace-hack, r=alexcrichtonTyler Mandry-0/+6
Use rustc-workspace-hack for rustbook As rustbook now depends transitively on openssl, it needs access to the rustc-workspace-hack/all-static feature to pick up openssl-sys/vendored. This fixes the rust build with `all-static = true` on systems where openssl is not installed (e.g. when cross-compiling).
2019-10-29Rollup merge of #65900 - eddyb:proc-macro-cleanup, r=alexcrichtonTyler Mandry-54/+28
proc_macro: clean up bridge::client::__run_expand{1,2} a bit. See commit titles/diffs for more details. The first commit is made possible by #53451 being fixed (almost a year ago). The last commit should remove the need for `#[allow(improper_ctypes)]` in #65134.
2019-10-29Rollup merge of #65898 - hermitcore:rusty-hermit, r=kennytmTyler Mandry-1/+7
add basic HermitCore support within libtest This an extension to #65167. The current pull request extend libtest to support HermitCore as target OS.
2019-10-29Rollup merge of #65843 - xen0n:mips64-musl-targets-with-ci, r=alexcrichtonTyler Mandry-0/+22
Enable dist for MIPS64 musl targets Continuing work in #63165, necessary libc changes are in place and published so here we go!
2019-10-29Rollup merge of #65832 - tlively:emscripten-exception-handling, r=alexcrichtonTyler Mandry-68/+63
Re-enable Emscripten's exception handling support Passes LLVM codegen and Emscripten link-time flags for exception handling if and only if the panic strategy is `unwind`. Sets the default panic strategy for Emscripten targets to `unwind`. Re-enables tests that depend on unwinding support for Emscripten, including `should_panic` tests. r? @alexcrichton
2019-10-29Rollup merge of #65741 - GuillaumeGomez:help-popup, r=Dylan-DPCTyler Mandry-3/+7
Prevent help popup to disappear when clicking on it Fixes #65736. r? @kinnison
2019-10-29Rollup merge of #65724 - pietroalbini:ci-remove-template-parameter, ↵Tyler Mandry-31/+25
r=alexcrichton ci: refactor pr tools job skipping We have a job in our CI (PR's x86_64-gnu-tools) that's supposed to run only when a submodule is changed in the PR, and it works by having a task at the start of the build that skips all the following tasks if the condition isn't met. Before this commit that task was gated with template parameters, which is a unique feature of Azure Pipelines. To make our CI more generic this commit switches the gate to use a simple environment variable plus a condition, which should be supported on more CI providers. This PR also extracts the skipping logic into a script. r? @alexcrichton
2019-10-29Rollup merge of #65539 - traxys:fix_62334, r=petrochenkovTyler Mandry-15/+27
resolve: Turn the "non-empty glob must import something" error into a lint This fixes #62334 by changing the error to a lint warning the glob. I changed the test but I'm very unsure of what I did as I do not know how to correctly check for the warning
2019-10-29Rollup merge of #65405 - GuillaumeGomez:long-err-explanation-E0740, r=Dylan-DPCTyler Mandry-12/+55
Create new error E0742 and add long error explanation Part of #61137. Creates E0742 error code and add its long error explanation.
2019-10-29Update cargo, books.Eric Huss-0/+0
2019-10-29Silence crate external span error in x86 platformsEsteban Küber-1/+3
This causes issues in at least `dist-i586-gnu-i586-i686-musl`, possibly others.
2019-10-29Fix NLL testEsteban Küber-18/+7
2019-10-29Make error apply only to impl/trait mismatchEsteban Küber-21/+23
2019-10-29Point at the trait item and tweak wordingEsteban Küber-15/+36
2019-10-29review commentsEsteban Küber-20/+23
2019-10-29Custom lifetime error for `impl` item doesn't conform to `trait`Esteban Küber-48/+93
2019-10-29Auto merge of #65904 - matthiaskrgr:submodule_upd, r=Manishearthbors-7/+11
submodules: update clippy from 66df92ae to c8e3cfbd Changes: ```` travis: temporarily disable rustfmt ci check until #4742 is resolved rustup https://github.com/rust-lang/rust/pull/65792/ Fix ICE #4579 Add regression test for ICE #4579 Run update_lints for Unicode lint Re-add false positive check Add raw string regression test for useless_format lint Re-factor useless_format lint Update Unicode lint tests [Backported] Rustup to https://github.com/rust-lang/rust/pull/59545 ```` Fixes #65888 r? @oli-obk @Manishearth
2019-10-29save-analysis: Account for async desugaring in async fn return typesIgor Matuszewski-4/+44
2019-10-29doc: use new feature gate for c_void typeLzu Tao-2/+7
2019-10-29Change E0741 into E0742Guillaume Gomez-13/+14
2019-10-29Update ui testsGuillaume Gomez-9/+13
2019-10-29Add long error explanation for E0740Guillaume Gomez-1/+38
2019-10-29Create new error code E0740 for visibility restrictions to ancestor module ↵Guillaume Gomez-3/+4
issues
2019-10-29Auto merge of #65927 - eddyb:eval-always-considered-harmful, r=michaelwoeristerbors-2/+0
Don't use eval_always for miri queries used from codegen. This should fix the [massive incremental perf regression](https://perf.rust-lang.org/compare.html?start=95f437b3cfb2fec966d7eaf69d7c2e36f9c274d1&end=9285d401a6070094747465962bc49969b93e14c5&stat=instructions:u) introduced in #65664. It seems that `eval_always` was mistakenly(?) added to `const_field` and then it ended up on `const_caller_location` (which is used much more often than `const_field` is). r? @michaelwoerister cc @oli-obk @nnethercote
2019-10-29Don't use eval_always for miri queries used from codegen.Eduard-Mihai Burtescu-2/+0
2019-10-29Apply suggestions from lzutaoPietro Albini-1/+1
Co-Authored-By: lzutao <taolzu@gmail.com>
2019-10-29Apply suggestions from lzutaoPietro Albini-3/+3
Co-Authored-By: lzutao <taolzu@gmail.com>
2019-10-29ci: upload toolstates.json to rust-lang-ci2Pietro Albini-0/+7
Uploading the toolstate data for each commit will help our release tooling understand which components are failing, to possibly skip shipping broken tools to users.
2019-10-29ci: extract uploading artifacts into a scriptPietro Albini-30/+54
2019-10-29ci: extract job skipping logic into a scriptPietro Albini-14/+21
2019-10-29ci: enable "run when submodule changes" with environment variablesPietro Albini-28/+15
We have a job in our CI (PR's x86_64-gnu-tools) that's supposed to run only when a submodule is changed in the PR, and it works by having a task at the start of the build that skips all the following tasks if the condition isn't met. Before this commit that task was gated with template parameters, which is a unique feature of Azure Pipelines. To make our CI more generic this commit switches the gate to use a simple environment variable plus a condition, which should be supported on more CI providers.
2019-10-29Auto merge of #65435 - michaelwoerister:fix-issue-64153, r=alexcrichtonbors-21/+68
Fix #64153 This PR changes how the compiler detects if an object file from an upstream crate is a Rust object file or not. Instead of checking if the name starts with the crate name and ends with `.o` (which is not always the case, as described in #64153), it now just checks if the filename ends with `.rcgu.o`. This fixes #64153. However, ideally we'd clean up the code around filename generation some more. Then this check could be made more robust. r? @alexcrichton
2019-10-28Use rustc-workspace-hack for rustbookSamuel Holland-0/+6
As rustbook now depends transitively on openssl, it needs access to the rustc-workspace-hack/all-static feature to pick up openssl-sys/vendored. This fixes the rust build with `all-static = true` on systems where openssl is not installed (e.g. when cross-compiling).
2019-10-29Rollup merge of #65809 - roblabla:eficall-abi, r=nagisaMazdak Farrokhzad-82/+203
Add new EFIAPI ABI Fixes #54527 Adds a new ABI, "efiapi", which reflects the calling convention as specified by [the current spec UEFI spec](https://uefi.org/sites/default/files/resources/UEFI%20Spec%202_7_A%20Sept%206.pdf#G6.999903). When compiling for x86_64, we should select the `win64` ABI, while on all other architectures (Itanium, x86, ARM and ARM64 and RISC-V), we should select the `C` ABI. Currently, this is done by just turning it into the C ABI everywhere except on x86_64, where it's turned into the win64 ABI. Should we prevent this ABI from being used on unsupported architectures, and if so, how would this be done?
2019-10-29Rollup merge of #65562 - Patryk27:master, r=estebankMazdak Farrokhzad-44/+57
Improve the "try using a variant of the expected type" hint. Fix https://github.com/rust-lang/rust/issues/65494. - Change type-printing output. - Use `span_to_snippet` when possible. - Change the message to `try using a variant of the expected enum`