about summary refs log tree commit diff
path: root/src/librustc_save_analysis
AgeCommit message (Collapse)AuthorLines
2019-10-29save-analysis: Account for async desugaring in async fn return typesIgor Matuszewski-4/+23
2019-10-17save-analysis: Nest tables when processing impl itemsIgor Matuszewski-9/+12
2019-10-13Nest typeck tables when processing struct member typesIgor Matuszewski-5/+7
2019-10-13Use empty typeck tables when nesting on items without thoseIgor Matuszewski-8/+14
2019-10-05Rollup merge of #64708 - SimonSapin:option-deref, r=CentrilTyler Mandry-1/+0
Stabilize `Option::as_deref` and `Option::as_deref_mut` The tracking issue https://github.com/rust-lang/rust/issues/50264 still has unresolved question for the corresponding `Result` methods.
2019-09-26Rename `ForeignItem.node` to `ForeignItem.kind`varkor-3/+3
2019-09-26Rename `Item.node` to `Item.kind`varkor-7/+7
2019-09-26Rename `Ty.node` to `Ty.kind`varkor-5/+5
2019-09-26Rename `TraitItem.node` to `TraitItem.kind`varkor-1/+1
2019-09-26Rename `ImplItem.node` to `ImplItem.kind`varkor-1/+1
2019-09-26Rename `Pat.node` to `Pat.kind`varkor-6/+6
2019-09-26Rename `Expr.node` to `Expr.kind`varkor-6/+6
For both `ast::Expr` and `hir::Expr`.
2019-09-25Rename `sty` to `kind`varkor-3/+3
2019-09-23Stabilize Option::deref and Option::deref_mutSimon Sapin-1/+0
The tracking issue https://github.com/rust-lang/rust/issues/50264 still has unresolved question for the corresponding `Result` methods.
2019-09-23Remove unused dependenciesShotaro Yamada-1/+0
2019-09-15save-analysis: Process bounds in impl trait only in argument positionIgor Matuszewski-1/+18
2019-09-15save-analysis: Deduplicate lookup_{d,r}ef_id functionsIgor Matuszewski-11/+8
2019-09-13save-analysis: Visit bounds in opaque typesIgor Matuszewski-2/+3
2019-09-13save-analysis: Use process_bounds when processing opaque impl item typeIgor Matuszewski-5/+1
...since the code is literally the same and does the same thing.
2019-09-13save-analysis: Nest typeck tables when processing functions/methodsIgor Matuszewski-42/+38
Fixes an issue where we did not nest tables correctly when resolving associated types in formal argument/return type positions
2019-09-05or-patterns: adjust save_analysis wrt. `process_var_decl{_multi}`.Mazdak Farrokhzad-83/+15
2019-08-27Cleanup: Consistently use `Param` instead of `Arg` #62426Kevin Per-3/+3
2019-08-15syntax_pos: Introduce a helper for checking whether a span comes from expansionVadim Petrochenkov-1/+1
2019-08-15Remove `Spanned` from `{ast,hir}::FieldPat`Vadim Petrochenkov-2/+2
2019-08-14Merge Variant and Variant_Caio-15/+15
2019-08-04Rename `ItemImplKind::Type` to `ItemImplKind::TyAlias`varkor-1/+1
2019-08-04Rename `ItemKind::Ty` to `ItemKind::TyAlias`varkor-2/+2
2019-08-02Address review commentsvarkor-11/+9
2019-08-02Replace "existential" by "opaque"varkor-7/+7
2019-07-30Auto merge of #62766 - alexcrichton:stabilize-pipelined-compilation, r=oli-obkbors-1/+1
rustc: Stabilize options for pipelined compilation This commit stabilizes options in the compiler necessary for Cargo to enable "pipelined compilation" by default. The concept of pipelined compilation, how it's implemented, and what it means for rustc are documented in #60988. This PR is coupled with a PR against Cargo (rust-lang/cargo#7143) which updates Cargo's support for pipelined compliation to rustc, and also enables support by default in Cargo. (note that the Cargo PR cannot land until this one against rustc lands). The technical changes performed here were to stabilize the functionality proposed in #60419 and #60987, the underlying pieces to enable pipelined compilation support in Cargo. The issues have had some discussion during stabilization, but the newly stabilized surface area here is: * A new `--json` flag was added to the compiler. * The `--json` flag can be passed multiple times. * The value of the `--json` flag is a comma-separated list of directives. * The `--json` flag cannot be combined with `--color` * The `--json` flag must be combined with `--error-format=json` * The acceptable list of directives to `--json` are: * `diagnostic-short` - the `rendered` field of diagnostics will have a "short" rendering matching `--error-format=short` * `diagnostic-rendered-ansi` - the `rendered` field of diagnostics will be colorized with ansi color codes embedded in the string field * `artifacts` - JSON blobs will be emitted for artifacts being emitted by the compiler The unstable `-Z emit-artifact-notifications` and `--json-rendered` flags have also been removed during this commit as well. Closes #60419 Closes #60987 Closes #60988
2019-07-29Rollup merge of #63055 - Mark-Simulacrum:save-analysis-clean-2, r=XanewokMazdak Farrokhzad-72/+41
Various cleanups to save analysis
2019-07-28Deny `unused_lifetimes` through rustbuildVadim Petrochenkov-2/+0
2019-07-28Remove lint annotations in specific crates that are already enforced by ↵Vadim Petrochenkov-2/+0
rustbuild Remove some random unnecessary lint `allow`s
2019-07-27Simplify SaveHandler traitMark Rousskov-38/+26
This extracts the core visiting logic
2019-07-27Store dumper directly in VisitorMark Rousskov-25/+19
2019-07-27Remove unused scope trackingMark Rousskov-19/+6
2019-07-26rustc: Stabilize options for pipelined compilationAlex Crichton-1/+1
This commit stabilizes options in the compiler necessary for Cargo to enable "pipelined compilation" by default. The concept of pipelined compilation, how it's implemented, and what it means for rustc are documented in #60988. This PR is coupled with a PR against Cargo (rust-lang/cargo#7143) which updates Cargo's support for pipelined compliation to rustc, and also enables support by default in Cargo. (note that the Cargo PR cannot land until this one against rustc lands). The technical changes performed here were to stabilize the functionality proposed in #60419 and #60987, the underlying pieces to enable pipelined compilation support in Cargo. The issues have had some discussion during stabilization, but the newly stabilized surface area here is: * A new `--json` flag was added to the compiler. * The `--json` flag can be passed multiple times. * The value of the `--json` flag is a comma-separated list of directives. * The `--json` flag cannot be combined with `--color` * The `--json` flag must be combined with `--error-format=json` * The acceptable list of directives to `--json` are: * `diagnostic-short` - the `rendered` field of diagnostics will have a "short" rendering matching `--error-format=short` * `diagnostic-rendered-ansi` - the `rendered` field of diagnostics will be colorized with ansi color codes embedded in the string field * `artifacts` - JSON blobs will be emitted for artifacts being emitted by the compiler The unstable `-Z emit-artifact-notifications` and `--json-rendered` flags have also been removed during this commit as well. Closes #60419 Closes #60987 Closes #60988
2019-07-25Rename JsonDumper to DumperMark Rousskov-15/+15
The Dumper no longer has anything to do specifically with JSON, it merely represents processing into an `Analysis` output.
2019-07-25Simplify save-analysis JSON dumper interfaceMark Rousskov-72/+29
2019-07-23normalize use of backticks for compiler messages in remaining modulesSamy Kacimi-4/+4
https://github.com/rust-lang/rust/issues/60532
2019-07-11hygiene: Reuse `MacroKind` in `ExpnKind`Vadim Petrochenkov-1/+2
Orthogonality and reuse are good.
2019-07-11syntax: Make def-site span mandatory in ↵Vadim Petrochenkov-3/+2
ExpnInfo/MacroBacktrace/DiagnosticSpanMacroExpansion We have to deal with dummy spans anyway Remove def-site span from expander interfaces. It's not used by the expansion infra, only by specific expanders, which can keep it themselves if they want it.
2019-07-11Rename some things in `syntax_pos/hygiene`Vadim Petrochenkov-3/+2
More consistent with other naming: ExpnFormat -> ExpnKind ExpnKind::name -> ExpnKind::descr DesugaringKind::name -> DesugaringKind::descr Shorter, no tautology: CompilerDesugaring -> Desugaring CompilerDesugaringKind -> DesugaringKind
2019-07-07rustc: Remove `dylib` crate type from most rustc cratesAlex Crichton-1/+0
Now that procedural macros no longer link transitively to libsyntax, this shouldn't be needed any more! This commit is an experiment in removing all dynamic libraries from rustc except for librustc_driver itself. Let's see how far we can get with that!
2019-07-06Rollup merge of #62329 - matklad:no-peeking, r=petrochenkovMazdak Farrokhzad-1/+1
Remove support for 1-token lookahead from the lexer `StringReader` maintained `peek_token` and `peek_span_src_raw` for look ahead. `peek_token` was used only by rustdoc syntax coloring. After moving peeking logic into highlighter, I was able to remove `peek_token` from the lexer. I tried to use `iter::Peekable`, but that wasn't as pretty as I hoped, due to buffered fatal errors. So I went with hand-rolled peeking. After that I've noticed that the only peeking behavior left was for raw tokens to test tt jointness. I've rewritten it in terms of trivia tokens, and not just spans. After that it became possible to simplify the awkward constructor of the lexer, which could return `Err` if the first peeked token contained error.
2019-07-05Rollup merge of #62168 - ljedrz:the_culmination_of_hiridification, r=ZoxcMazdak Farrokhzad-24/+24
The (almost) culmination of HirIdification It's finally over. This PR removes old `FIXME`s and renames some functions so that the `HirId` variant has the shorter name. All that remains (and rightfully so) is stuff in `resolve`, `save_analysis` and (as far as I can tell) in a few places where we can't replace `NodeId` with `HirId`.
2019-07-05Rollup merge of #61545 - flip1995:internal_lints, r=oli-obkMazdak Farrokhzad-1/+0
Implement another internal lints cc #49509 This adds ~~two~~ one internal lint~~s~~: 1. LINT_PASS_IMPL_WITHOUT_MACRO: Make sure, that the `{declare,impl}_lint_pass` macro is used to implement lint passes. cc #59669 2. ~~USAGE_OF_TYCTXT_AND_SPAN_ARGS: item 2 on the list in #49509~~ ~~With 2. I wasn't sure, if this lint should be applied everywhere. That means a careful review of 0955835 would be great. Also 73fb9b4 allows this lint on some functions. Should I also apply this lint there?~~ TODO (not directly relevant for review): - [ ] https://github.com/rust-lang/rust/pull/59316#discussion_r280186517 (not sure yet, if this works or how to query for `rustc_private`, since it's not in [`Features`](https://doc.rust-lang.org/nightly/nightly-rustc/syntax/feature_gate/struct.Features.html) :thinking: cc @eddyb) - [x] https://github.com/rust-lang/rust/pull/61735#discussion_r292389870 - [x] Check explicitly for the `{declare,impl}_lint_pass!` macros r? @oli-obk
2019-07-04rename hir::map::opt_local_def_id*ljedrz-3/+3
2019-07-04rename hir::map::local_def_id to local_def_id_from_node_idljedrz-21/+21
2019-07-04remove peek_span_src_raw from StringReaderAleksey Kladov-1/+1