about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorLines
2018-11-23Auto merge of #54071 - eddyb:alignsssss, r=oli-obkbors-374/+363
rustc_target: separate out an individual alignment quantity type from Align. Before this PR, `rustc_target::abi::Align` combined "power-of-two alignment quantity" semantics, with a distinction between ABI (required) and preferred alignment (by having two quantities). After this PR, `Align` is only *one* such quantity, and a new `AbiAndPrefAlign` type is introduced to hold the pair of ABI and preferred `Align` quantities. `Align` is used everywhere one quantity is necessary/sufficient, simplifying some of the code in codegen/miri, while `AbiAndPrefAlign` only in layout computation (to propagate preferred alignment). r? @oli-obk cc @nagisa @RalfJung @nikomatsakis
2018-11-22Do not point at associated types from other cratesEsteban Küber-34/+6
This is a somewhat arbitrary restriction in order to be consistent in the output of the tests regardless of target platform.
2018-11-22Reword and fix testEsteban Küber-23/+26
2018-11-22Suggest correct syntax when writing type arg instead of assoc typeEsteban Küber-47/+88
When confusing an associated type with a type argument, suggest the appropriate syntax. Given `Iterator<isize>`, suggest `Iterator<Item = isize>`.
2018-11-22Point at the associated type's def spanEsteban Küber-0/+66
2018-11-22Join multiple E0191 errors in the same location under a single diagnosticEsteban Küber-27/+33
2018-11-22Point at every unexpected lifetime and type argument in E0107Esteban Küber-29/+69
2018-11-22Auto merge of #56143 - nikomatsakis:issue-56128-segment-id-ice-nightly, ↵bors-41/+123
r=petrochenkov Issue 56128 segment id ice nightly Tentative fix for #56128 From what I can tell, the problem is that if you have `pub(super) use foo::{a, b}`, then when we explode the `a` and `b`, the segment ids from the `super` path were not getting cloned. However, once I fixed *that*, then I ran into a problem that the "visibility" node-ids were not present in the final HIR -- this is because the visibility of the "stem" that is returned in this case was getting reset to inherited. I don't *think* it is a problem to undo that, so that the visibility is returned unmodified. Fixes #55475 Fixes #56128 cc @nrc @petrochenkov
2018-11-22Move fake rustc_codegen_ssa dependency from rustc_driver to rustc-mainbjorn3-4/+4
2018-11-22Add rustc_codegen_ssa to sysrootbjorn3-1/+23
2018-11-22Disable the self-profiler unless the `-Z self-profile` flag is setWesley Wiser-2/+4
Related to #51648
2018-11-22Fix the tracking issue for hash_raw_entrySteven Fackler-38/+38
It used to point to the implementation PR.
2018-11-22miri: restrict fn argument punning to Rust ABIRalf Jung-12/+21
2018-11-22fix codegen-units testsRalf Jung-37/+38
2018-11-22Auto merge of #53586 - eddyb:top-lock, r=alexcrichtonbors-3569/+39
Move Cargo.{toml,lock} to the repository root directory. This should give us back `src/` in errors, panics and debuginfo, for free. r? @Mark-Simulacrum @alexcrichton cc @michaelwoerister
2018-11-22drop glue takes in mutable references, it should reflect that in its typeRalf Jung-3/+21
2018-11-22explain how this worksNiko Matsakis-1/+23
2018-11-22only reset non-restricted visibilitiesNiko Matsakis-15/+28
2018-11-22std::str Adapt documentation to realityAdrian Heine né Lang-4/+2
2018-11-22Auto merge of #56136 - matthiaskrgr:clippy, r=oli-obkbors-11/+18
submodules: update clippy from f5d868c9 to 2f6881c6 Changes: ```` missed another one in the README run "util/dev update_lints" rust-lang-nursery/rust-clippy => rust-lang/rust-clippy Address 'clippy::single-match' dogfood lint Fix nit Address travis CI lint failure Update trivially_copy_pass_by_ref with Trait stderr output issue#3318 run trivially_copy_pass_by_ref for traits Update trivially_copy_pass_by_ref with Trait examples Fix awkward wording Document how to lint local Clippy changes with locally built Clippy Enable rustup clippy to refer to the correct documentation rustup https://github.com/rust-lang/rust/pull/52591 remove unused allow() attributes, NFC Add regression test Don't emit suggestion when inside of a macro ```` fixes clippy toolstate
2018-11-22submodules: update clippy from f5d868c9 to 2f6881c6Matthias Krüger-11/+18
```` missed another one in the README run "util/dev update_lints" rust-lang-nursery/rust-clippy => rust-lang/rust-clippy Address 'clippy::single-match' dogfood lint Fix nit Address travis CI lint failure Update trivially_copy_pass_by_ref with Trait stderr output issue#3318 run trivially_copy_pass_by_ref for traits Update trivially_copy_pass_by_ref with Trait examples Fix awkward wording Document how to lint local Clippy changes with locally built Clippy Enable rustup clippy to refer to the correct documentation rustup https://github.com/rust-lang/rust/pull/52591 remove unused allow() attributes, NFC Add regression test Don't emit suggestion when inside of a macro ````
2018-11-22Move Cargo.{toml,lock} to the repository root directory.Eduard-Mihai Burtescu-3569/+39
2018-11-22Auto merge of #56155 - GuillaumeGomez:rollup, r=GuillaumeGomezbors-97/+507
Rollup of 11 pull requests Successful merges: - #55367 (lint if a private item has doctests) - #55485 (Return &T / &mut T in ManuallyDrop Deref(Mut) impl) - #55784 (Clarifying documentation for collections::hash_map::Entry::or_insert) - #55961 (Fix VecDeque pretty-printer) - #55980 (Suggest on closure args count mismatching with pipe span) - #56002 (fix #55972: Erroneous self arguments on bare functions emit subpar compilation error) - #56063 (Update any.rs documentation using keyword dyn) - #56067 (Add SGX target to rustc) - #56078 (Fix error message for `-C panic=xxx`.) - #56106 (Remove some incorrect doc comments) - #56126 (core/benches/num: Add `from_str/from_str_radix()` benchmarks) Failed merges: r? @ghost
2018-11-22expand thread::park explanationRalf Jung-1/+6
2018-11-22Rollup merge of #56126 - Turbo87:bench-parse, r=alexcrichtonGuillaume Gomez-0/+105
core/benches/num: Add `from_str/from_str_radix()` benchmarks This was extracted from #55973 /cc @alexcrichton
2018-11-22Rollup merge of #56106 - bjorn3:patch-1, r=alexcrichtonGuillaume Gomez-12/+0
Remove some incorrect doc comments
2018-11-22Rollup merge of #56078 - ehuss:fix-panic-opt-msg, r=alexcrichtonGuillaume Gomez-5/+5
Fix error message for `-C panic=xxx`. Fixes rust-lang/cargo#6334
2018-11-22Rollup merge of #56067 - jethrogb:jb/sgx-target-spec, r=alexcrichtonGuillaume Gomez-0/+93
Add SGX target to rustc This adds the `x86_64-fortanix-unknown-sgx` target specification to the Rust compiler. See #56066 for more details about this target.
2018-11-22Rollup merge of #56063 - 0xrgb:patch-1, r=joshtriplettGuillaume Gomez-11/+11
Update any.rs documentation using keyword dyn This will fix #56062.
2018-11-22Rollup merge of #56002 - Axary:master, r=estebankGuillaume Gomez-2/+58
fix #55972: Erroneous self arguments on bare functions emit subpar compilation error #55972 r? @estebank
2018-11-22Rollup merge of #55980 - csmoe:issue-55891, r=estebankGuillaume Gomez-11/+45
Suggest on closure args count mismatching with pipe span Closes #55891 r? @estebank
2018-11-22Rollup merge of #55961 - tromey:Bug-55944-vecdeque, r=nikomatsakisGuillaume Gomez-3/+22
Fix VecDeque pretty-printer This fixes the VecDeque pretty-printer to handle cases where head < tail. Closes #55944
2018-11-22Rollup merge of #55784 - meltinglava:master, r=KodrAusGuillaume Gomez-8/+8
Clarifying documentation for collections::hash_map::Entry::or_insert Previous version does not show that or_insert does not insert the passed value, as the passed value was the same value as what was already in the map.
2018-11-22Rollup merge of #55485 - petertodd:2018-10-manuallydrop-deref, r=TimNNGuillaume Gomez-2/+2
Return &T / &mut T in ManuallyDrop Deref(Mut) impl Without this change the generated documentation looks like this: fn deref(&self) -> &<ManuallyDrop<T> as Deref>::Target Returning the actual type directly makes the generated docs more clear: fn deref(&self) -> &T Basically, compare how the impl for `Box<T>` and `ManuallyDrop<T>` looks in this screenshot: ![rust docs for ManuallyDrop as Deref](https://user-images.githubusercontent.com/7042/47673083-fc9dc280-db89-11e8-89b0-c6bde663feef.png)
2018-11-22Rollup merge of #55367 - GuillaumeGomez:private-item-doc-test-lint, ↵Guillaume Gomez-43/+158
r=QuietMisdreavus lint if a private item has doctests Fixes #55333. r? @QuietMisdreavus
2018-11-22Pass additional linker flags when targeting FuchsiaPetr Hosek-5/+24
This is a follow up to 8aa9267 which changed the driver to use lld directly rather than invoking it through Clang. This change ensures we pass all the necessary flags to lld.
2018-11-22Auto merge of #53918 - Havvy:doc-sort-by, r=GuillaumeGomezbors-0/+32
Doc total order requirement of sort(_unstable)_by I took the definition of what a total order is from the Ord trait docs. I specifically put "elements of the slice" because if you have a slice of f64s, but know none are NaN, then sorting by partial ord is total in this case. I'm not sure if I should give such an example in the docs or not. r? @GuillaumeGomez
2018-11-21Move a flaky process test out of libstdAlex Crichton-36/+25
This test ensures that everything in `env::vars()` is inherited but that's not actually true because other tests may add env vars after we spawn the process, causing the test to be flaky! This commit moves the test to a run-pass test where it can execute in isolation. Along the way this removes a lot of the platform specificity of the test, using iteslf to print the environment instead of a foreign process.
2018-11-22rustc_target: avoid using AbiAndPrefAlign where possible.Eduard-Mihai Burtescu-334/+311
2018-11-22Auto merge of #56147 - petrochenkov:impice, r=nikomatsakisbors-2/+71
resolve: Fix some asserts in import validation The asserts are not actually correct in presence of ambiguity errors. Fixes https://github.com/rust-lang/rust/issues/56125
2018-11-22rustc_target: separate out an individual Align from AbiAndPrefAlign.Eduard-Mihai Burtescu-197/+207
2018-11-22rustc_target: rename abi::Align to AbiAndPrefAlign.Eduard-Mihai Burtescu-218/+220
2018-11-22Make std::os::unix/linux::fs::MetadataExt::a/m/ctime* documentation clearerariasuni-12/+24
2018-11-21add compile-pass annotationNiko Matsakis-0/+2
2018-11-21Auto merge of #56065 - oli-obk:min_const_fn_loop_ice, r=davidtwcobors-5/+16
Replace the ICEing on const fn loops with an error fixes #56035
2018-11-21Add test for sidebar link generationGuillaume Gomez-0/+23
2018-11-22resolve: Fix some asserts in import validationVadim Petrochenkov-2/+71
2018-11-21hack: ignore list-stems for pub lintNiko Matsakis-1/+9
2018-11-21Fix BTreeSet and BTreeMap gdb pretty-printersTom Tromey-63/+50
The BTreeSet and BTreeMap gdb pretty-printers did not take the node structure into account, and consequently only worked for shallow sets. This fixes the problem by iterating over child nodes when needed. This patch avoids the current approach of implementing some of the value manipulations in debugger-indepdendent code. This was done for convenience: a type lookup was needed for the first time, and there currently are no lldb formatters for these types. Closes #55771
2018-11-21pass vis by shared referenceNiko Matsakis-6/+6
We are not mutating it now.