about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorLines
2019-12-18Set release channel on non-dist buildersMark Rousskov-4/+9
Toolstate publication only runs if the channel is "nightly" and previously the toolstate builders did not know that the channel was nightly (since they are not dist builders). A look through bootstrap seems to indicate that nothing should directly depend on the channel being set to `-dev` on the test builders, though this may cause some problems with UI tests (if for some reason they're dumping the channel into stderr), but we cannot find evidence of such so hopefully this is fine.
2019-12-15Rollup merge of #67305 - kappa:patch-1, r=jonas-schievinkMazdak Farrokhzad-1/+1
Doc typo
2019-12-15Rollup merge of #67300 - aloucks:issue-65970, r=rkruppeMazdak Farrokhzad-1/+16
Restore original implementation of Vec::retain This PR reverts #48065, which aimed to optimize `Vec::retain` by making use of `Vec::drain_filter`. Unfortunately at that time, `drain_filter` was unsound. The soundness hole in `Vec::drain_filter` was fixed in #61224 by guaranteeing that cleanup logic runs via a nested `Drop`, even in the event of a panic. Implementing this nested drop affects codegen (apparently?) and results in slower code. Fixes #65970
2019-12-15Rollup merge of #67289 - estebank:unnamed-closure, r=CentrilMazdak Farrokhzad-4/+57
Do not ICE on unnamed future Fix #67252.
2019-12-15Rollup merge of #67282 - pjw91:patch-1, r=Dylan-DPCMazdak Farrokhzad-1/+1
Fix example code of OpenOptions::open The example didn't set the access mode flag, which resulted in an `Err(InvalidInput)`. r? @steveklabnik
2019-12-15Rollup merge of #67267 - alexcrichton:update-wasi-libc, r=Dylan-DPCMazdak Farrokhzad-14/+21
Fix signature of `__wasilibc_find_relpath` Looks like this function changed upstream, so it needs to be adjusted for when used by libstd.
2019-12-15Rollup merge of #67255 - tuxillo:remove-i686-unknown-dragonfly, r=alexcrichtonMazdak Farrokhzad-24/+0
Remove i686-unknown-dragonfly target DragonFly BSD removed support for i386 a while ago. It only supports x86_64 right now.
2019-12-15Auto merge of #67216 - ecstatic-morse:const-loop, r=oli-obkbors-127/+559
Enable `loop` and `while` in constants behind a feature flag This PR is an initial implementation of #52000. It adds a `const_loop` feature gate, which allows `while` and `loop` expressions through both HIR and MIR const-checkers if enabled. `for` expressions remain forbidden by the HIR const-checker, since they desugar to a call to `IntoIterator::into_iter`, which will be rejected anyways. `while` loops also require [`#![feature(const_if_match)]`](https://github.com/rust-lang/rust/pull/66507), since they have a conditional built into them. The diagnostics from the HIR const checker will suggest this to the user. r? @oli-obk cc @rust-lang/wg-const-eval
2019-12-14Doc typoAlex Kapranoff-1/+1
2019-12-14Do not ICE on unnamed futureEsteban Küber-4/+57
2019-12-14Auto merge of #67224 - nikomatsakis:revert-stabilization-of-never-type, ↵bors-170/+454
r=centril Revert stabilization of never type Fixes https://github.com/rust-lang/rust/issues/66757 I decided to keep the separate `never-type-fallback` feature gate, but tried to otherwise revert https://github.com/rust-lang/rust/pull/65355. Seemed pretty clean. ( cc @Centril, author of #65355, you may want to check this over briefly )
2019-12-14update referenceNiko Matsakis-0/+0
2019-12-14update clippy to the rustc-pr-67224 branchNiko Matsakis-13/+5
Actually to commit <69f99e74ac2266dff4b5adc7c59b35236f0abef1>.
2019-12-14Restore original implementation of Vec::retainAaron Loucks-1/+16
This PR reverts #48065, which aimed to optimize `Vec::retain` by making use of `Vec::drain_filter`. Unfortunately at that time, `drain_filter` was unsound. The soundness hole in `Vec::drain_filter` was fixed in #61224 by guaranteeing that cleanup logic runs via a nested `Drop`, even in the event of a panic. Implementing this nested drop affects codegen (apparently?) and results in slower code. Fixes #65970
2019-12-14[WIP] fix tests after rebaseNiko Matsakis-47/+15
2019-12-14add `#![feature(never_type)]` to tests as neededNiko Matsakis-11/+16
2019-12-14Add regression test for #66757Niko Matsakis-0/+29
2019-12-14Revert "Stabilize the `never_type`, written `!`."Niko Matsakis-23/+44
This reverts commit 15c30ddd69d6cc3fffe6d304c6dc968a5ed046f1.
2019-12-14Revert "Remove `#![feature(never_type)]` from tests."Niko Matsakis-98/+268
This reverts commit 8f6197f39f7d468dfc5b2bd41dae4769992a2f83.
2019-12-14Revert "Redefine `core::convert::Infallible` as `!`."Niko Matsakis-7/+106
This reverts commit 089229a1935fa9795cfdefa518c8f8c3beb66db8.
2019-12-14Auto merge of #67136 - oli-obk:const_stability, r=Centrilbors-181/+717
Require stable/unstable annotations for the constness of all stable fns with a const modifier r? @RalfJung @Centril Every `#[stable]` const fn now needs either a `#[rustc_const_unstable]` attribute or a `#[rustc_const_stable]` attribute. You can't silently stabilize the constness of a function anymore.
2019-12-14Auto merge of #67084 - Pagten:feature/print-msg-from-elf-entrypoint, r=Amanieubors-1/+31
SGX: Change ELF entrypoint This fixes [rust-sgx issue #148](https://github.com/fortanix/rust-sgx/issues/148). A new entry point is created for the ELF file generated by `rustc`, separate from the enclave entry point. When the ELF file is executed as a Linux binary, the error message below is written to stderr. > Error: This file is an SGX enclave which cannot be executed as a standard Linux binary. > See the installation guide at https://edp.fortanix.com/docs/installation/guide/ on how to use 'cargo run' or follow the steps at https://edp.fortanix.com/docs/tasks/deployment/ for manual deployment. When the ELF file is converted to an SGXS using `elf2sgxs`, the old entry point is still set as the enclave entry point. In a future pull request in the rust-sgx repository, `elf2sgxs` will be modified to remove the code in the ELF entry point, since this code is not needed in the enclave.
2019-12-13Auto merge of #65951 - estebank:type-inference-error, r=nikomatsakisbors-135/+470
Point at method call when type annotations are needed - Point at method call instead of whole expression when type annotations are needed. - Suggest use of turbofish on function and methods. Fix #49391, fix #46333, fix #48089. CC #58517, #63502, #63082. Fixes https://github.com/rust-lang/rust/issues/40015 r? @nikomatsakis
2019-12-13Auto merge of #67284 - Centril:rollup-ghiukob, r=Centrilbors-217/+1039
Rollup of 7 pull requests Successful merges: - #67026 (Improve diagnostics and code for exhaustiveness of empty matches) - #67235 (VecDeque: drop remaining items on destructor panic) - #67254 (dont ICE in case of invalid drop fn) - #67256 (Reduce allocs for validation errors) - #67274 (be explicit that mem::uninitialized is the same as MaybeUninit::uninit().assume_init()) - #67278 (`coerce_inner`: use initial `expected_ty`) - #67280 (docs: std::convert::From: Fix typo) Failed merges: r? @ghost
2019-12-13Rollup merge of #67280 - shalzz:patch-1, r=jonas-schievinkMazdak Farrokhzad-1/+1
docs: std::convert::From: Fix typo Fix a minor typo
2019-12-13Rollup merge of #67278 - Centril:67273, r=oli-obkMazdak Farrokhzad-2/+63
`coerce_inner`: use initial `expected_ty` Fixes #67273. Follow-up to #59439. r? @oli-obk
2019-12-13Rollup merge of #67274 - RalfJung:uninit, r=CentrilMazdak Farrokhzad-1/+5
be explicit that mem::uninitialized is the same as MaybeUninit::uninit().assume_init() Cc @Centril @nikomatsakis
2019-12-13Rollup merge of #67256 - RalfJung:reduce-allocs, r=oli-obkMazdak Farrokhzad-29/+22
Reduce allocs for validation errors This probably doesn't really matter, but I just felt like I had to do this... r? @oli-obk
2019-12-13Rollup merge of #67254 - RalfJung:vtable-ice, r=oli-obkMazdak Farrokhzad-1/+12
dont ICE in case of invalid drop fn Fixes https://github.com/rust-lang/miri/issues/1112 r? @oli-obk
2019-12-13Rollup merge of #67235 - jonas-schievink:vecdeque-leak, r=KodrAusMazdak Farrokhzad-1/+47
VecDeque: drop remaining items on destructor panic Closes https://github.com/rust-lang/rust/issues/67232
2019-12-13Rollup merge of #67026 - Nadrieril:improve-usefulness-empty, ↵Mazdak Farrokhzad-182/+889
r=varkor,Centril,estebank Improve diagnostics and code for exhaustiveness of empty matches There was a completely separate check and diagnostics for the case of an empty match. This led to slightly different error messages and duplicated code. This improves code reuse and generally clarifies what happens for empty matches. This also clarifies the action of the `exhaustive_patterns` feature, and ensures that this feature doesn't change diagnostics in places it doesn't need to.
2019-12-14Fix incorrect example code of OpenOptions::openPatrick Wang-1/+1
2019-12-13Correctly mark things as `min_const_fn`Dylan MacKenzie-4/+6
2019-12-13Document `Features::enabled`ecstatic-morse-0/+3
Co-Authored-By: Mazdak Farrokhzad <twingoow@gmail.com>
2019-12-13Use correct nightly version for featureDylan MacKenzie-1/+1
2019-12-13Ensure test actually uses dataflow, not simulationDylan MacKenzie-3/+7
2019-12-13Use better name for local containing required feature gatesDylan MacKenzie-5/+5
2019-12-13Replace `Index` impl with `enabled` methodDylan MacKenzie-8/+4
2019-12-13Apply suggestions from reviewDylan MacKenzie-5/+7
2019-12-13Fix grammar in test descriptionecstatic-morse-1/+1
Co-Authored-By: Mazdak Farrokhzad <twingoow@gmail.com>
2019-12-13Look for "unstable feature" error code in testDylan MacKenzie-1/+1
Conditionals and loops now have unstable features, and `feature_err` has its own error code. I think that `feature_err` should take an error code as a parameter, but don't have the energy to make this change throughout the codebase. Also, the error code system may be torn out entirely.
2019-12-13Improve commentDylan MacKenzie-2/+2
2019-12-13Improve message when active feature indexing panicsDylan MacKenzie-1/+1
2019-12-13Bless modified testsDylan MacKenzie-80/+298
2019-12-13Bless unrelated tests with new help messageDylan MacKenzie-17/+48
2019-12-13Add qualif smoke tests for const loopsDylan MacKenzie-0/+61
2019-12-13Extend control flow basics tests with loopsDylan MacKenzie-9/+52
2019-12-13Restructue HIR const-checker to handle features with multiple gatesDylan MacKenzie-19/+69
2019-12-13Put MIR checks for loops behind the feature flagDylan MacKenzie-1/+7
2019-12-13Add feature gate for `const_loop`Dylan MacKenzie-0/+4