about summary refs log tree commit diff
path: root/src/test/run-pass
AgeCommit message (Collapse)AuthorLines
2018-08-30Rollup merge of #53786 - frewsxcv:frewsxcv-bad-style, r=ManishearthPietro Albini-1/+1
Replace usages of 'bad_style' with 'nonstandard_style'. `bad_style` is being deprecated in favor of `nonstandard_style`: - https://github.com/rust-lang/rust/issues/41646
2018-08-30Rollup merge of #53476 - GuillaumeGomez:try-from-int-error-partial-eq, r=KodrAusPietro Albini-0/+21
Add partialeq implementation for TryFromIntError type Fixes #53458.
2018-08-30Made std::intrinsics::transmute() const fn.thedarkula-0/+22
2018-08-30fix u32 steps_between for 16-bit systemsAndre Bogus-0/+23
2018-08-29Replace usages of 'bad_style' with 'nonstandard_style'.Corey Farwell-1/+1
`bad_style` is being deprecated in favor of `nonstandard_style`: - https://github.com/rust-lang/rust/issues/41646
2018-08-29Auto merge of #53671 - RalfJung:miri-refactor, r=oli-obkbors-0/+8
Miri engine cleanup * Unify the two maps in memory to store the allocation and its kind together. * Share the handling of statics between CTFE and miri: The miri engine always uses "lazy" `AllocType::Static` when encountering a static. Acessing that static invokes CTFE (no matter the machine). The machine only has any influence when writing to a static, which CTFE outright rejects (but miri makes a copy-on-write). * Add an `AllocId` to by-ref consts so miri can use them as operands without making copies. * Move responsibilities around for the `eval_fn_call` machine hook: The hook just has to find the MIR (or entirely take care of everything); pushing the new stack frame is taken care of by the miri engine. * Expose the intrinsics and lang items implemented by CTFE so miri does not have to reimplement them. * Allow Machine to hook into foreign statics (used by miri to get rid of some other hacks). * Clean up function calling. * Switch const sanity check to work on operands, not mplaces. * Move const_eval out of rustc_mir::interpret, to make sure that it does not access private implementation details. In particular, we can finally make `eval_operand` take `&self`. :-) Should be merged after https://github.com/rust-lang/rust/pull/53609, across which I will rebase.
2018-08-28Add partialeq implementation for TryFromIntError typeGuillaume Gomez-0/+21
2018-08-28restructure unary_op to also dispatch on type first; fix promotion with ↵Ralf Jung-0/+8
unary '-' overflowing
2018-08-27Auto merge of #53227 - nivkner:pin_move, r=RalfJungbors-4/+4
move the Pin API into its own module for centralized documentation This implements the change proposed by @withoutboats in #49150, as suggested by @RalfJung in the review of #53104, along with the documentation that was originally in it, that was deemed more appropriate in module-level documentation. r? @RalfJung
2018-08-26fix `is_non_exhaustive` confusion between structs and enumsAriel Ben-Yehuda-0/+29
Structs and enums can both be non-exhaustive, with a very different meaning. This PR splits `is_non_exhaustive` to 2 separate functions - 1 for structs, and another for enums, and fixes the places that got the usage confused. Fixes #53549.
2018-08-25Update Cargo submoduleAlex Crichton-2/+2
Also update Cargo's dependencies while we're at it
2018-08-24Auto merge of #53662 - kennytm:rollup, r=kennytmbors-1/+50
Rollup of 16 pull requests Successful merges: - #53311 (Window Mutex: Document that we properly initialize the SRWLock) - #53503 (Discourage overuse of mem::forget) - #53545 (Fix #50865: ICE on impl-trait returning functions reaching private items) - #53559 (add macro check for lint) - #53562 (Lament the invincibility of the Turbofish) - #53563 (use String::new() instead of String::from(""), "".to_string(), "".to_owned() or "".into()) - #53592 (docs: minor stylistic changes to str/string docs) - #53594 (Update RELEASES.md to include clippy-preview) - #53600 (Fix a grammatical mistake in "expected generic arguments" errors) - #53614 (update nomicon and book) - #53617 (tidy: Stop requiring a license header) - #53618 (Add missing fmt examples) - #53636 (Prefer `.nth(n)` over `.skip(n).next()`.) - #53644 (Use SmallVec for SmallCStr) - #53664 (Remove unnecessary closure in rustc_mir/build/mod.rs) - #53666 (Added rustc_codegen_llvm to compiler documentation.)
2018-08-24Rollup merge of #53545 - FelixMcFelix:fix-50865-beta, r=petrochenkovkennytm-0/+49
Fix #50865: ICE on impl-trait returning functions reaching private items Adds a test case as suggested in #50865, and implements @petrochenkov's suggestion. Fixes #50865. Impl-trait-returning functions are marked under a new (low) access level, which they propagate rather than `AccessLevels::Reachable`. `AccessLevels::is_reachable` returns false for such items (leaving stability analysis unaffected), these items may still be visible to the lints phase however.
2018-08-24Rollup merge of #53636 - frewsxcv:frewsxcv-nth, r=rkruppekennytm-1/+1
Prefer `.nth(n)` over `.skip(n).next()`. Found by clippy.
2018-08-23Stabilize 'attr_literals' feature.Sergio Benitez-1/+0
2018-08-23Prefer `.nth(n)` over `.skip(n).next()`.Corey Farwell-1/+1
Found by clippy.
2018-08-23Auto merge of #52602 - scottmcm:tryblock-expr, r=nikomatsakisbors-12/+34
Implement try block expressions I noticed that `try` wasn't a keyword yet in Rust 2018, so... ~~Fix​es https://github.com/rust-lang/rust/issues/52604~~ That was fixed by PR https://github.com/rust-lang/rust/pull/53135 cc https://github.com/rust-lang/rust/issues/31436 https://github.com/rust-lang/rust/issues/50412
2018-08-23move PinBox into pin module and export through stdNiv Kaminer-2/+2
2018-08-23move PinMut into pin module and export through stdNiv Kaminer-2/+2
2018-08-23Stabilize a few secondary macro featuresVadim Petrochenkov-1/+0
`tool_attributes`, `proc_macro_path_invoc`, partially `proc_macro_gen`
2018-08-22Remove Ty prefix from Ty{Bool|Char|Int|Uint|Float|Str}varkor-6/+6
2018-08-22Remove Ty prefix from Ty{Foreign|Param}varkor-1/+1
2018-08-22Remove Ty prefix from ↵varkor-10/+10
Ty{Adt|Array|Slice|RawPtr|Ref|FnDef|FnPtr|Dynamic|Closure|Generator|GeneratorWitness|Never|Tuple|Projection|Anon|Infer|Error}
2018-08-21Auto merge of #53530 - kennytm:rollup, r=kennytmbors-18/+19
Rollup of 17 pull requests Successful merges: - #53030 (Updated RELEASES.md for 1.29.0) - #53104 (expand the documentation on the `Unpin` trait) - #53213 (Stabilize IP associated constants) - #53296 (When closure with no arguments was expected, suggest wrapping) - #53329 (Replace usages of ptr::offset with ptr::{add,sub}.) - #53363 (add individual docs to `core::num::NonZero*`) - #53370 (Stabilize macro_vis_matcher) - #53393 (Mark libserialize functions as inline) - #53405 (restore the page title after escaping out of a search) - #53452 (Change target triple used to check for lldb in build-manifest) - #53462 (Document Box::into_raw returns non-null ptr) - #53465 (Remove LinkMeta struct) - #53492 (update lld submodule to include RISCV patch) - #53496 (Fix typos found by codespell.) - #53521 (syntax: Optimize some literal parsing) - #53540 (Moved issue-53157.rs into src/test/ui/consts/const-eval/) - #53551 (Avoid some Place clones.) Failed merges: r? @ghost
2018-08-21Rollup merge of #53329 - frewsxcv:frewsxcv-ptr-add-sub, r=RalfJungkennytm-6/+6
Replace usages of ptr::offset with ptr::{add,sub}. Rust provides these helper methods – so let's use them!
2018-08-21Rollup merge of #53496 - matthiaskrgr:codespell_08_2018, r=varkorkennytm-10/+10
Fix typos found by codespell.
2018-08-21Further fixes.Kyle Simpson-1/+1
2018-08-21Fixes for code review.Kyle Simpson-3/+8
2018-08-20Removed `raw_identifiers` feature gate.Alexander Regueiro-13/+0
2018-08-20Replace usages of ptr::offset with ptr::{add,sub}.Corey Farwell-6/+6
2018-08-19Rename `catch_expr` feature to `try_blocks`Scott McMurray-2/+2
2018-08-19Parse try blocks with the try keyword instead of do catch placeholderScott McMurray-10/+14
2018-08-19Add `try` to syntax_pos as an edition-2018-only keywordScott McMurray-0/+18
2018-08-19Stabilize macro_vis_matcherJakub Kozlowski-2/+3
2018-08-19Fix typos found by codespell.Matthias Krüger-10/+10
2018-08-19Implement simple codegen for unsized rvalues.Masaki Hara-0/+98
2018-08-18Auto merge of #53324 - alexreg:self_in_typedefs, r=eddybbors-0/+40
`Self` in type definitions (self_in_typedefs) This implements the [`self_in_typedefs` feature](https://github.com/rust-lang/rfcs/blob/master/text/2300-self-in-typedefs.md) ([tracking issue 49303](https://github.com/rust-lang/rust/issues/49303)). r? @eddyb CC @Centril
2018-08-18Added tests.Alexander Regueiro-0/+40
2018-08-17Auto merge of #50911 - petrochenkov:macuse, r=alexcrichtonbors-56/+51
Stabilize `use_extern_macros` Closes https://github.com/rust-lang/rust/issues/35896
2018-08-17Rollup merge of #53413 - eddyb:featured-in-the-latest-edition, r=varkorCorey Farwell-1/+1
Warn that `#![feature(rust_2018_preview)]` is implied when the edition is set to Rust 2018. cc @varkor @petrochenkov @joshtriplett
2018-08-17Fix undesirable falloutVadim Petrochenkov-51/+51
compile-fail-fulldeps/proc-macro/proc-macro-attributes.rs - resolution change for derive helper attributes with the same name as derive itself run-pass/macro-comma-support.rs - indeterminate resolutions for macros in expression positions ui/issues/issue-49074.rs - diagnostics regression, not enough recovery to report the second error ui/object-lifetime/object-lifetime-default.stderr - unstable diagnostics?
2018-08-17Stabilize `use_extern_macros`Vadim Petrochenkov-5/+0
2018-08-17rustc_resolve: don't allow paths starting with `::crate`.Eduard-Mihai Burtescu-3/+4
2018-08-17rustc_resolve: overhaul `#![feature(uniform_paths)]` error reporting.Eduard-Mihai Burtescu-1/+8
2018-08-16tests: prefer edition: directives to compile-flags:--edition.Eduard-Mihai Burtescu-1/+1
2018-08-15Auto merge of #53133 - Zoxc:gen-int, r=eddybbors-0/+35
Record adjustments and original type for expressions in the generator interior Fixes https://github.com/rust-lang/rust/issues/50878 and https://github.com/rust-lang/rust/issues/52398. r? @eddyb
2018-08-15Auto merge of #53212 - sunjay:nll-raw-cast, r=nikomatsakisbors-0/+35
NLL - Prevent where clauses from extending the lifetime of bindings Fixes https://github.com/rust-lang/rust/issues/53123 r? @nikomatsakis
2018-08-14Rollup merge of #53208 - BurntPizza:protect-the-environment, r=alexcrichtonkennytm-0/+29
Don't panic on std::env::vars() when env is null. Fixes #53200. Reviewer(s): * Do I need to do any `#[cfg()]` here? * Is this use of libc ok for a dev-dependency?
2018-08-14Auto merge of #53335 - eddyb:issue-53333, r=petrochenkovbors-0/+17
rustc_resolve: crates only exist in the type namespace. Fixes #53333 by resolving `::crate_name` in `TypeNS` alone, which was overlooked in #52923 and didn't break tests, since having `use crate_name;` and a `crate_name` value in the same scope is rare.
2018-08-14rustc_resolve: crates only exist in the type namespace.Eduard-Mihai Burtescu-0/+17