about summary refs log tree commit diff
path: root/src/test/run-pass
AgeCommit message (Collapse)AuthorLines
2019-05-21Auto merge of #60950 - taiki-e:arbitrary_self_types-tests, r=Centrilbors-988/+0
Move arbitrary self types's tests into ui/self https://github.com/rust-lang/rust/pull/60944#discussion_r285362006 r? @Centril
2019-05-20Auto merge of #60445 - RalfJung:maybe-uninit, r=Centrilbors-1/+1
stabilize core parts of MaybeUninit and deprecate mem::uninitialized in the future (1.40.0). This is part of implementing https://github.com/rust-lang/rfcs/pull/1892. Also expand the documentation a bit. This type is currently primarily useful when dealing with partially initialized arrays. In libstd, it is used e.g. in `BTreeMap` (with some unstable APIs that however can all be replaced, less ergonomically, by stable ones). What we stabilize should also be enough for `SmallVec` (Cc @bluss). Making this useful for structs requires https://github.com/rust-lang/rfcs/pull/2582 or a commitment that references to uninitialized data are not insta-UB.
2019-05-20stabilize core parts of MaybeUninit and deprecate mem::uninitialized in the ↵Ralf Jung-1/+1
future Also expand the documentation a bit
2019-05-20Auto merge of #60921 - cuviper:remove-mpsc_select, r=SimonSapinbors-37/+0
Remove the unstable and deprecated mpsc_select This removes macro `select!` and `std::sync::mpsc::{Handle, Select}`, which were all unstable and have been deprecated since 1.32. Closes #27800 r? @SimonSapin
2019-05-20Rollup merge of #60590 - petertodd:2018-test-union-nonzero, ↵Mazdak Farrokhzad-0/+51
r=nikomatsakis,Centril Test interaction of unions with non-zero/niche-filling optimization Notably this nails down part of the behavior that MaybeUninit assumes, e.g. that a Option<MaybeUninit<&u8>> does not take advantage of non-zero optimization, and thus is a safe construct. It also verifies the status quo: that even unions that could theoretically take advantage of niches don't. (relevant: https://github.com/rust-lang/rust/issues/36394)
2019-05-19Move run-pass/self/* to ui/selfTaiki Endo-696/+0
2019-05-19Move arbitrary_self_types's tests into ui/selfTaiki Endo-292/+0
2019-05-18Make clear that status quo ≠ guaranteePeter Todd-2/+3
2019-05-18Auto merge of #60386 - Goirad:sgx-ignore-tests, r=nikomatsakisbors-2/+86
Added ignore-sgx for appropriate tests in src/test These are all the tests that make sense to ignore when targeting fortanix-unknonw-sgx, at least in test/runpass. Other suites not yet covered.
2019-05-17Remove the unstable and deprecated mpsc_selectJosh Stone-37/+0
This removes macro `select!` and `std::sync::mpsc::{Handle, Select}`, which were all unstable and have been deprecated since 1.32.
2019-05-17Auto merge of #60171 - matthewjasper:full-nll-compare-mode, r=pnkfelixbors-25/+0
Use -Zborrowck=mir for NLL compare mode closes #56993 r? @pnkfelix
2019-05-16reverted changed cfg test casesDario Gonzalez-8/+7
2019-05-16Fixed tidy errorsDario Gonzalez-7/+2
2019-05-16Added ignore-sgx for appropriate testsDario Gonzalez-6/+96
2019-05-15Auto merge of #60775 - hellow554:no_bitrig, r=joshtriplettbors-34/+0
Remove bitrig support from rust Resolves #60743 using `find` and `rg` I delete every occurence of "bitrig" in the sources, expect for the llvm submodule (is this correct?). There's also this file https://github.com/rust-lang/rls/blob/5b8e99bb61958ca8abcb7c5eda70521726be1065/rls-analysis/test_data/rust-analysis/libstd-af9bacceee784405.json which contains a bitrig string in it. What to do with that?
2019-05-13add impl_trait_in_bindings to INCOMPLETE_FEATURESPulkit Goyal-0/+7
impl_trait_in_bindings is not yet complete and can lead to compiler crashes. Fixes #60764.
2019-05-13Remove bitrig support from rustMarcel Hellwig-34/+0
2019-05-13Auto merge of #60765 - matthewjasper:fix-more-escaping-rescopes, r=oli-obkbors-0/+6
Fix more escaping ReScopes Closes #58840
2019-05-12Remove feature(nll) when compare mode is sufficientMatthew Jasper-25/+0
2019-05-12Treat generators the same as closure for escaping lifetimesMatthew Jasper-0/+6
2019-05-12Auto merge of #60244 - SimonSapin:dangling, r=oli-obkbors-2/+0
const-stabilize NonNull::dangling and NonNull::cast
2019-05-10Various test changesMazdak Farrokhzad-0/+8
2019-05-09Rollup merge of #60572 - tmandry:issue-59972, r=RalfJung,oli-obkMazdak Farrokhzad-0/+23
Add test for #59972 This PR adds a test for #59972, which was fixed in #59897. Closes #59972. r? @eddyb
2019-05-07Implement built-in await syntaxTaylor Cramer-23/+222
Adds support for .await under the existing async_await feature gate. Moves macro-like await! syntax to the await_macro feature gate. Removes support for `await` as a non-keyword under the `async_await` feature.
2019-05-07Add non-non-zero test to union-nonzero testPeter Todd-0/+8
2019-05-07Document purpose of union-nonzero testPeter Todd-0/+12
2019-05-06Add test for #59972Tyler Mandry-0/+23
2019-05-06Test interaction of unions with non-zero/niche-filling optimizationPeter Todd-0/+30
Notably this nails down part of the behavior that MaybeUninit assumes, e.g. that a Option<MaybeUninit<&u8>> does not take advantage of non-zero optimization, and thus is a safe construct.
2019-05-04Rollup merge of #60513 - chrisvittal:remove-borrowck-compare, r=matthewjasperMazdak Farrokhzad-7/+0
Remove -Z borrowck=compare flag This is the start of the work that needs to be done on #59193. It just removes the flag and updates the tests. r? @matthewjasper
2019-05-03Rollup merge of #60409 - JohnTitor:error-for-existential-type, r=oli-obkMazdak Farrokhzad-2/+2
Require a trait in the bounds of existential types Fixes #53090 r? @oli-obk
2019-05-03Rollup merge of #60401 - JohnTitor:rename-log, r=davidtwcoMazdak Farrokhzad-5/+5
Rename `RUST_LOG` to `RUSTC_LOG` cc: #57985 I think we should also change these submodules: - rustc-guide - Cargo (rename to `CARGO_LOG`, cc: https://github.com/rust-lang/cargo/pull/6605, https://github.com/rust-lang/cargo/issues/6189) - miri - rls - rustfmt r? @davidtwco
2019-05-03Update testsChristopher Vittal-7/+0
2019-05-02Rollup merge of #60437 - davidtwco:issue-60236, r=nikomatsakisMazdak Farrokhzad-184/+0
Ensure that drop order of `async fn` matches `fn` and that users cannot refer to generated arguments. Fixes #60236 and fixes #60438. This PR modifies the lowering of `async fn` arguments so that the drop order matches the equivalent `fn`. Previously, async function arguments were lowered as shown below: async fn foo(<pattern>: <ty>) { async move { } } // <-- dropped as you "exit" the fn // ...becomes... fn foo(__arg0: <ty>) { async move { let <pattern> = __arg0; } // <-- dropped as you "exit" the async block } After this PR, async function arguments will be lowered as: async fn foo(<pattern>: <ty>, <pattern>: <ty>, <pattern>: <ty>) { async move { } } // <-- dropped as you "exit" the fn // ...becomes... fn foo(__arg0: <ty>, __arg1: <ty>, __arg2: <ty>) { async move { let __arg2 = __arg2; let <pattern> = __arg2; let __arg1 = __arg1; let <pattern> = __arg1; let __arg0 = __arg0; let <pattern> = __arg0; } // <-- dropped as you "exit" the async block } If `<pattern>` is a simple ident, then it is lowered to a single `let <pattern> = <pattern>;` statement as an optimization. This PR also stops users from referring to the generated `__argN` identifiers. r? @nikomatsakis
2019-05-01Unify tests under async-await directory.David Wood-263/+0
2019-05-01Ensure that drop order of `async fn` matches `fn`.David Wood-184/+263
This commit modifies the lowering of `async fn` arguments so that the drop order matches the equivalent `fn`. Previously, async function arguments were lowered as shown below: async fn foo(<pattern>: <ty>) { async move { } } // <-- dropped as you "exit" the fn // ...becomes... fn foo(__arg0: <ty>) { async move { let <pattern> = __arg0; } // <-- dropped as you "exit" the async block } After this PR, async function arguments will be lowered as: async fn foo(<pattern>: <ty>, <pattern>: <ty>, <pattern>: <ty>) { async move { } } // <-- dropped as you "exit" the fn // ...becomes... fn foo(__arg0: <ty>, __arg1: <ty>, __arg2: <ty>) { async move { let __arg2 = __arg2; let <pattern> = __arg2; let __arg1 = __arg1; let <pattern> = __arg1; let __arg0 = __arg0; let <pattern> = __arg0; } // <-- dropped as you "exit" the async block } If `<pattern>` is a simple ident, then it is lowered to a single `let <pattern> = <pattern>;` statement as an optimization.
2019-05-01Rollup merge of #60369 - TimDiekmann:dispatch-zst, r=eddybMazdak Farrokhzad-0/+49
Support ZSTs in DispatchFromDyn Allows to use ZSTs with 1 byte alignment in `DispatchFromDyn` implementation. This is required for `Box<T, A: Alloc>` cc #58457
2019-05-01Fix run-pass testYuki OKUSHI-2/+2
2019-04-30Rename to RUSTC_LOGYuki OKUSHI-5/+5
2019-04-29Rollup merge of #60360 - rasendubi:const-labeled-break, r=CentrilMazdak Farrokhzad-0/+10
Add test case for labeled break in const assignment Fixes #51350.
2019-04-29Support ZSTs in DispatchFromDynTim Diekmann-0/+49
2019-04-29const-stabilize std::mem::needs_dropYuki OKUSHI-2/+0
2019-04-28Add test case for labeled break in const assignmentAlexey Shmalko-0/+10
See https://github.com/rust-lang/rust/issues/51350 for more information.
2019-04-26Auto merge of #60167 - varkor:tidy-filelength, r=matthewjasperbors-0/+4
Add a tidy check for files with over 3,000 lines Files with a large number of lines can cause issues in GitHub (e.g. https://github.com/rust-lang/rust/issues/60015) and also tend to be indicative of opportunities to refactor into less monolithic structures. This adds a new check to tidy to warn against files that have more than 3,000 lines, as suggested in https://github.com/rust-lang/rust/issues/60015#issuecomment-483868594. (This number was chosen fairly arbitrarily as a reasonable indicator of size.) This check can be ignored with `// ignore-tidy-filelength`. Existing files with greater than 3,000 lines currently ignore the check, but this helps us spot when files are getting too large. (We might try to split up all files larger than this in the future, as in https://github.com/rust-lang/rust/issues/60015).
2019-04-26Rollup merge of #60183 - tmandry:chalk-builtin-copy-clone, r=scalexmMazdak Farrokhzad-0/+43
Chalkify: Add builtin Copy/Clone r? @nikomatsakis
2019-04-25ignore-tidy-filelength on all files with greater than 3000 linesvarkor-0/+4
2019-04-24chalkify: Add Copy/Clone builtinsTyler Mandry-0/+43
2019-04-25const-stabilize NonNull::dangling and NonNull::castSimon Sapin-2/+0
2019-04-24Allow subtyping of the final expression of a constantMatthew Jasper-0/+8
Fixes an ICE for the following code: fn foo(_ : &()) {} static X: fn(&'static ()) = foo;
2019-04-23Stabilize futures_apiTaylor Cramer-7/+3
2019-04-23Rollup merge of #60169 - varkor:tidy-unnecessary-ignore-newline, r=kennytmMazdak Farrokhzad-2/+2
Warn when ignore-tidy-linelength is present, but no lines are too long It's easy for a `// ignore-tidy-linelength` to be added when there is a genuine need to ignore a file's line length, but then after refactoring the need is gone, but the tidy directive is not removed. This means that in the future, further editing may accidentally add unnecessarily long lines. This change forces `// ignore-tidy-linelength` to be used exactly when necessary, to make sure such changes are intentional.