about summary refs log tree commit diff
path: root/src/librustc/session
AgeCommit message (Collapse)AuthorLines
2019-05-21Move `edition` outside the hygiene lock and avoid accessing itJohn Kåre Alsaker-6/+6
2019-05-16Rollup merge of #60769 - ehuss:rustc-cli-docs, r=steveklabnikMazdak Farrokhzad-2/+1
Update rustc book CLI docs. This adds a little detail (and missing flags) to the rustc book. There is still a lot of information missing, but this seemed like a good step to expanding it.
2019-05-13Remove the equality operation between `Symbol` and strings.Nicholas Nethercote-1/+2
And also the equality between `Path` and strings, because `Path` is made up of `Symbol`s.
2019-05-13Pass a `Symbol` to `check_name`, `emit_feature_err`, and related functions.Nicholas Nethercote-1/+2
2019-05-12Update rustc book CLI docs.Eric Huss-2/+1
2019-05-08Optimize HIR mapJohn Kåre Alsaker-3/+0
2019-05-07rustc: rename -Z emit-directives to -Z emit-artifact-notifications and ↵Eduard-Mihai Burtescu-2/+2
simplify the output.
2019-05-05Add commentsvarkor-0/+9
2019-05-05Fix argument alias handling for -g and -C debuginfovarkor-3/+8
2019-05-05Fix argument alias handling for -O and -C opt-levelvarkor-3/+8
2019-05-03Update help messageChristopher Vittal-1/+1
2019-05-02Remove BorrowckMode::CompareChristopher Vittal-4/+0
2019-04-29Auto merge of #60006 - nnethercote:json-for-pipelining, r=alexcrichtonbors-3/+3
In JSON output, emit a directive after metadata is generated. To implement pipelining, Cargo needs to know when metadata generation is finished. This is done via a new JSON "directive". Unfortunately, metadata file writing currently occurs very late during compilation, so pipelining won't produce a speed-up. Moving metadata file writing earlier will be a follow-up. r? @alexcrichton
2019-04-30In JSON output, emit a directive after metadata is generated.Nicholas Nethercote-0/+2
To implement pipelining, Cargo needs to know when metadata generation is finished. This commit adds code to do that. Unfortunately, metadata file writing currently occurs very late during compilation, so pipelining won't produce a speed-up. Moving metadata file writing earlier will be a follow-up. The change involves splitting the existing `Emitter::emit` method in two: `Emitter::emit_diagnostic` and `Emitter::emit_directive`. The JSON directives look like this: ``` {"directive":"metadata file written: liba.rmeta"} ``` The functionality is behind the `-Z emit-directives` option, and also requires `--error-format=json`.
2019-04-28Rollup merge of #60347 - JohnTitor:remove-flags, r=matthewjasperMazdak Farrokhzad-4/+0
Remove `-Z two-phase-borrows` and `-Z two-phase-beyond-autoref` fixes #60331
2019-04-28Rollup merge of #60270 - alexcrichton:metadata-multi-cgu, r=oli-obkMazdak Farrokhzad-3/+2
rustc: Flag metadata compatible with multiple CGUs It looks like the `OutputType::Metadata` kind in the compiler was misclassified in #38571 long ago by accident as incompatible with codegen units and a single output file. This means that if you emit both a linkable artifact and metadata it silently turns off multiple codegen units unintentionally! This commit corrects the situation to ensure that if `--emit metadata` is used it doesn't implicitly disable multiple codegen units. This will ensure we don't accidentally regress compiler performance when striving to implement pipelined compilation!
2019-04-28Remove two-phase-beyond-autorefYuki OKUSHI-2/+0
2019-04-28Remove two-phase-borrowsYuki OKUSHI-2/+0
2019-04-26Remove unused `DiagnosticOutput::Emitter` variant.Nicholas Nethercote-3/+1
2019-04-25ignore-tidy-filelength on all files with greater than 3000 linesvarkor-0/+2
2019-04-25rustc: Flag metadata compatible with multiple CGUsAlex Crichton-3/+2
It looks like the `OutputType::Metadata` kind in the compiler was misclassified in #38571 long ago by accident as incompatible with codegen units and a single output file. This means that if you emit both a linkable artifact and metadata it silently turns off multiple codegen units unintentionally! This commit corrects the situation to ensure that if `--emit metadata` is used it doesn't implicitly disable multiple codegen units. This will ensure we don't accidentally regress compiler performance when striving to implement pipelined compilation!
2019-04-22Remove double trailing newlinesvarkor-1/+0
2019-04-21Enable migrate mode by default on the 2015 editionMatthew Jasper-15/+2
This also fully stabilizes two-phase borrows on all editions
2019-04-19Rollup merge of #60045 - estebank:suggest-std, r=petrochenkovMazdak Farrokhzad-0/+5
Suggest appropriate path when calling associated item on bare types When looking at the documentation for `std::f32` or `std::str`, for example, it is easy to get confused and assume `std::f32` and `f32` are the same thing. Because of this, it is not uncommon to attempt writing `f32::consts::PI` instead of the correct `std::f32::consts::PI`. When encountering the former, which results in an access error due to it being an inexistent path, try to access the same path under `std`. If this succeeds, this information is stored for later tweaking of the final E0599 to provide an appropriate suggestion. Fix #26760, fix #46660.
2019-04-18Suggest appropriate path when calling associated item on bare typesEsteban Küber-0/+5
When looking at the documentation for `std::f32` or `std::str`, for example, it is easy to get confused and assume `std::f32` and `f32` are the same thing. Because of this, it is not uncommon to attempt writing `f32::consts::PI` instead of the correct `std::f32::consts::PI`. When encountering the former, which results in an access error due to it being an inexistent path, try to access the same path under `std`. If this succeeds, this information is stored for later tweaking of the final E0599 to provide an appropriate suggestion. This suggestion applies to both E0233 and E0599 and is only checked when the first ident of a path corresponds to a primitive type.
2019-04-18Implement event filtering for self-profiler.Michael Woerister-1/+3
2019-04-17Rollup merge of #59128 - oli-obk:colorful_json, r=mark-i-m,eddybMazdak Farrokhzad-68/+103
Emit ansi color codes in the `rendered` field of json diagnostics cc @ljedrz Implemented for https://github.com/rust-lang/rust/pull/56595#issuecomment-447645115 (x.py clippy)
2019-04-14Derive Default for ExternEntryAaron Hill-20/+11
2019-04-14Fix ExternEntry testAaron Hill-25/+11
2019-04-14Refactor structure of ExternEntryAaron Hill-38/+28
2019-04-14Move new_public to 'tess' moduleAaron Hill-8/+10
2019-04-14Improve formattingAaron Hill-24/+1
2019-04-14Fix testsAaron Hill-7/+28
2019-04-14Fix tidyAaron Hill-1/+1
2019-04-14Combine 'Extern' and 'ExternPrivate'Aaron Hill-27/+50
2019-04-14Properly parse '--extern-private' with name and pathAaron Hill-6/+37
2019-04-14Auto merge of #59950 - Centril:rollup-hpmr62i, r=Centrilbors-6/+32
Rollup of 6 pull requests Successful merges: - #59776 (Apply resource-suffix to search-index and source-files scripts as well) - #59784 (Suggest importing macros from the crate root) - #59812 (Exclude profiler-generated symbols from MSVC __imp_-symbol workaround.) - #59874 (Clean up handling of `-Z pgo-gen` commandline option.) - #59890 (Don't generate empty json variables) - #59911 (Revert "compile crates under test w/ -Zemit-stack-sizes") Failed merges: r? @ghost
2019-04-14Rollup merge of #59874 - michaelwoerister:pgo-updates-1, r=cramertjMazdak Farrokhzad-6/+32
Clean up handling of `-Z pgo-gen` commandline option. This PR adapts the `-Z pgo-gen` flag to how Clang and GCC handle the corresponding `-fprofile-generate` flag. In particular, the flag now optionally takes a directory to place the profiling data in and allows to omit the argument (instead of having to pass an empty string).
2019-04-14Rollup merge of #59899 - nnethercote:sort-enum-variants-by-size, r=pnkfelixMazdak Farrokhzad-1/+7
In `-Zprint-type-size` output, sort enum variants by size. It's useful to see the biggest variants first. r? @pnkfelix
2019-04-12Use measureme in self-profilerWesley Wiser-9/+17
Related to #58372 Related to #58967
2019-04-12In `-Zprint-type-size` output, sort enum variants by size.Nicholas Nethercote-1/+7
It's useful to see the biggest variants first.
2019-04-11Clean up handling of -Zpgo-gen commandline option.Michael Woerister-6/+32
2019-04-09Do not render ascii colors to buffersOliver Scherer-2/+2
2019-04-09Make trait_methods_not_found use a lockJohn Kåre Alsaker-2/+2
2019-04-02Rename `colorful-json` to `json-rendered` and make it a selection instead of ↵Oliver Scherer-62/+66
a bool
2019-04-02Fix forgotten capitalizationOliver Scherer-5/+5
2019-04-02Adjust tests to new enum variant fieldsOliver Scherer-20/+25
2019-04-02Emit ansi color codes in the `rendered` field of json diagnosticsOliver Scherer-15/+41
2019-04-01Rollup merge of #58507 - Zoxc:time-extended, r=michaelwoeristerMazdak Farrokhzad-0/+5
Add a -Z time option which prints only passes which runs once This ensures `-Z time-passes` fits on my screen =P r? @michaelwoerister
2019-03-28Rollup merge of #59363 - peterjoel:issue_59361_edition_opt_shortlist, r=nagisaMazdak Farrokhzad-6/+6
#59361 Moved rustc edition opt to short list Addresses #59361, in case that issue is accepted.