summary refs log tree commit diff
path: root/src/librustc_save_analysis
AgeCommit message (Collapse)AuthorLines
2019-12-02syntax: Remove redundant span from `ast::Mac`Vadim Petrochenkov-8/+0
Also remove a couple of redundant `visit_mac` asserts
2019-11-16ast: Keep `extern` qualifiers in functions more preciselyVadim Petrochenkov-8/+9
2019-11-14TAIT: adjust save-analysisMazdak Farrokhzad-48/+0
2019-11-10move syntax::parse -> librustc_parseMazdak Farrokhzad-4/+3
also move MACRO_ARGUMENTS -> librustc_parse
2019-11-08ast::ItemKind::Fn: use ast::FnSigMazdak Farrokhzad-5/+5
2019-11-08ast::MethodSig -> ast::FnSigMazdak Farrokhzad-3/+3
2019-11-07move syntax::parse::lexer::comments -> syntax::util::commentsMazdak Farrokhzad-1/+1
2019-11-07syntax::parser::token -> syntax::tokenMazdak Farrokhzad-2/+2
2019-11-07syntax: use distinct FloatTy from rustc_target.Mazdak Farrokhzad-1/+0
We also sever syntax's dependency on rustc_target as a result. This should slightly improve pipe-lining. Moreover, some cleanup is done in related code.
2019-11-07parser: don't hardcode ABIs into grammarMazdak Farrokhzad-16/+10
2019-11-06Make doc comments cheaper with `AttrKind`.Nicholas Nethercote-2/+2
`AttrKind` is a new type with two variants, `Normal` and `DocComment`. It's a big performance win (over 10% in some cases) because `DocComment` lets doc comments (which are common) be represented very cheaply. `Attribute` gets some new helper methods to ease the transition: - `has_name()`: check if the attribute name matches a single `Symbol`; for `DocComment` variants it succeeds if the symbol is `sym::doc`. - `is_doc_comment()`: check if it has a `DocComment` kind. - `{get,unwrap}_normal_item()`: extract the item from a `Normal` variant; panic otherwise. Fixes #60935.
2019-11-06Remove unnecessary `Deref` impl for `Attribute`.Nicholas Nethercote-1/+1
This kind of thing just makes the code harder to read.
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.