about summary refs log tree commit diff
path: root/src/librustc_save_analysis
AgeCommit message (Collapse)AuthorLines
2019-06-23let_chains: Remove ast::ExprKind::{IfLet, WhileLet} from visitors and ↵Mazdak Farrokhzad-10/+2
introduce ::Let.
2019-06-22Count all errors for `track_errors`Matthew Jasper-6/+0
2019-06-21revert the NodeId to HirId parameter change to get_path_resljedrz-17/+12
2019-06-20rename hir::map::get_by_hir_id to getljedrz-1/+1
2019-06-20remove hir::map::getljedrz-14/+18
2019-06-20rename hir::map::expect_expr_by_hir_id to expect_exprljedrz-2/+2
2019-06-20remove uses of the NodeId hir::map::exprljedrz-2/+4
2019-06-18rustc: reintroduce lifetime bounds where necessary.Eduard-Mihai Burtescu-2/+2
2019-06-18rustc: remove 'x: 'y bounds (except from comments/strings).Eduard-Mihai Burtescu-6/+6
2019-06-14Unify all uses of 'gcx and 'tcx.Eduard-Mihai Burtescu-3/+3
2019-06-12rustc: replace `TyCtxt<'tcx, 'gcx, 'tcx>` with `TyCtxt<'gcx, 'tcx>`.Eduard-Mihai Burtescu-3/+3
2019-06-12rustc: replace `TyCtxt<'a, 'gcx, 'tcx>` with `TyCtxt<'tcx, 'gcx, 'tcx>`.Eduard-Mihai Burtescu-3/+3
2019-06-11Add deny(unused_lifetimes) to all the crates that have deny(internal).Eduard-Mihai Burtescu-0/+1
2019-06-10Emit artifact notifications for save-analysis outputJeremy Fitzhardinge-8/+18
Issue: https://github.com/rust-lang/rust/issues/61047
2019-06-08Remove unused `#![feature(custom_attribute)]`sVadim Petrochenkov-1/+0
2019-06-06syntax: Rename `TokenAndSpan` into `Token`Vadim Petrochenkov-9/+9
2019-06-06syntax: Rename `Token` into `TokenKind`Vadim Petrochenkov-2/+2
2019-06-03syntax: revert `ast::AsyncArgument` and associated changes.Eduard-Mihai Burtescu-1/+1
Here follows the main reverts applied in order to make this commit: Revert "Rollup merge of #60676 - davidtwco:issue-60674, r=cramertj" This reverts commit 45b09453dbf120cc23d889435aac3ed7d2ec8eb7, reversing changes made to f6df1f6c30b469cb9e65c5453a0efa03cbb6005e. Revert "Rollup merge of #60437 - davidtwco:issue-60236, r=nikomatsakis" This reverts commit 16939a50ea440e72cb6ecefdaabb988addb1ec0e, reversing changes made to 12bf98155249783583a91863c5dccf9e346f1226. Revert "Rollup merge of #59823 - davidtwco:issue-54716, r=cramertj" This reverts commit 62d1574876f5531bce1b267e62dff520d7adcbbb, reversing changes made to 4eff8526a789e0dfa8b97f7dec91b7b5c18e8544.
2019-06-01rustc: remove Res::Upvar.Eduard-Mihai Burtescu-1/+1
2019-05-26Rename "Associated*" to "Assoc*"Andrew Xu-6/+6
We are going to uniform the terminology of all associated items. Methods that may or may not have `self` are called "associated functions". Because `AssociatedFn` is a bit long, we rename `Associated` to `Assoc`.
2019-05-23Update dylib_dependency_formats, extern_crate and reachable_non_genericsJohn Kåre Alsaker-2/+2
2019-05-23Update privacy_access_levelsJohn Kåre Alsaker-2/+1
2019-05-20Fixed nits raised in review.Alexander Regueiro-1/+1
2019-05-20Ban multi-trait objects via trait aliases.Alexander Regueiro-3/+3
2019-05-18Declare DefIndex with the newtype_index macroFabian Drinck-1/+1
2019-05-13Auto merge of #60649 - Xanewok:save-analysis-assoc-const-ice, r=oli-obkbors-4/+6
save-analysis: Fix ICE when processing associated constant Closes #59134 Closes https://github.com/rust-lang/rls/issues/1449 Thanks @swgillespie for helping tracking this down and fixing it! r? @eddyb
2019-05-13Remove the equality operation between `Symbol` and strings.Nicholas Nethercote-1/+1
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-3/+3
2019-05-08save-analysis: Fix ICE when processing associated constantIgor Matuszewski-4/+6
2019-05-04Remove `Res::Label`Vadim Petrochenkov-2/+1
Paths can never resolve to labels
2019-05-03rustc: rename hir::def::Def to Res (short for "resolution").Eduard-Mihai Burtescu-73/+73
2019-05-03rustc: factor most DefId-containing variants out of Def and into DefKind.Eduard-Mihai Burtescu-34/+36
2019-04-23Rollup merge of #59823 - davidtwco:issue-54716, r=cramertjMazdak Farrokhzad-1/+1
[wg-async-await] Drop `async fn` arguments in async block Fixes #54716. This PR modifies the HIR lowering (and some other places to make this work) so that unused arguments to a async function are always dropped inside the async move block and not at the end of the function body. ``` async fn foo(<pattern>: <type>) { async move { } } // <-- dropped as you "exit" the fn // ...becomes... fn foo(__arg0: <ty>) { async move { let <pattern>: <ty> = __arg0; } // <-- dropped as you "exit" the async block } ``` However, the exact ordering of drops is not the same as a regular function, [as visible in this playground example](https://play.rust-lang.org/?version=stable&mode=debug&edition=2015&gist=be39af1a58e5d430be1eb3c722cb1ec3) - I believe this to be an unrelated issue. There is a [Zulip topic](https://rust-lang.zulipchat.com/#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/.2354716.20drop.20order) for this. r? @cramertj cc @nikomatsakis
2019-04-22Auto merge of #60053 - Xanewok:serde-save-analysis, r=nrcbors-10/+12
save-analysis: Use serde instead of libserialize to dump JSON data This breaks the save-analysis infrastructure (which also includes `rls-{analysis, data, span}` crates) from depending on rustc_serialize and so we can start moving them to being supported on stable without implementing `Decodable` et al. by hand for data structures defined there. Notable benefits: - we drop the awkward raw byte `PathBuf` [serialization](https://gist.github.com/Xanewok/f4fe8564d0dc0c3ab1dbc244279ff895) (until now (de)serialized as `&[u8]`) - [faster](https://github.com/serde-rs/json-benchmark) (hopefully noticeable for inner crate dependencies for the RLS workloads) - we can easily explore the binary serialization backend (which we planned to do for save-analysis anyway) ~This should be merged together with an update to RLS (https://github.com/rust-lang/rls/pull/1435), which technically could be included right now because we can use the bundled `rls-analysis` here directly, however I'd prefer to publish this to crates.io first (https://github.com/rust-lang/rls/pull/1434, cc @nrc) and use the published version, instead.~ Includes https://github.com/rust-lang/rls/pull/1436. @matklad @nikomatsakis This is also important for the potential RLS 1.0 - 2.0 bridge we talked about on Zulip today
2019-04-21Add `AsyncArgument` to AST.David Wood-1/+1
This commit adds an `AsyncArgument` struct to the AST that contains the generated argument and statement that will be used in HIR lowering, name resolution and def collection.
2019-04-21AST/HIR: Use `Mutability` instead of bool in foreign staticsVadim Petrochenkov-1/+1
2019-04-21Switch to serde-enabled rls-* and update RLS appropriatelyIgor Matuszewski-2/+2
This also bumps RLS version to 1.36. The updated rls-* packages use serde but *not* serde_derive thanks to manual proc macro expansion. This is a hack, since rustc cannot handle crates.io proc macros (duplicated in tools) when cross-compiling, so that's the best we can do in order to support serde_json in save-analysis.
2019-04-21save-analysis: Use serde instead of libserialize to dump JSON dataIgor Matuszewski-8/+10
2019-04-17Deny `internal` in stage0Mateusz Mikuła-1/+1
2019-04-14HirIdify hir::Defljedrz-4/+4
2019-04-11save-analysis: Simplify match arm for type node defIgor Matuszewski-5/+4
2019-04-11save-analysis: use `qpath_def` for associated typesIgor Matuszewski-18/+3
2019-04-03Deny internal lints on non conflicting cratesflip1995-0/+1
- libarena - librustc_allocator - librustc_borrowck - librustc_codegen_ssa - librustc_codegen_utils - librustc_driver - librustc_errors - librustc_incremental - librustc_metadata - librustc_passes - librustc_privacy - librustc_resolve - librustc_save_analysis - librustc_target - librustc_traits - libsyntax - libsyntax_ext - libsyntax_pos
2019-03-29Rollup merge of #59510 - varkor:rename-type_parameters, r=eddybMazdak Farrokhzad-2/+2
Rename `type_parameters` to `generics` and so on Some old variable names had fallen through the generics generalisation pull requests.
2019-03-29Rename `type_parameters` to `generics` and so onvarkor-2/+2
2019-03-28Rollup merge of #59216 - stepnivlk:type_dependent_defs-wrappers, r=oli-obkMazdak Farrokhzad-2/+2
Type dependent defs wrappers First of all, forgive me if something would seem lame to you or I offend some rule (although I tried to read through docs), this is my first PR. Issue: https://github.com/rust-lang/rust/issues/59094 This PR adds 3 helper methods to `TypeckTables`: * `opt_type_dependent_def` * `opt_type_dependent_def_id` * `type_dependent_def_id` I didn't add `type_dependent_def` as was proposed in the issue simply because it wasn't used anywhere in the code. Only non-option wrapped`type_dependent_defs()[]` accesses were found in clippy which always called `def_id()` on result. Speaking of clippy, should I open separate PR in its own repo, given it's used as submodule here? Sry it took me so long, as I said I'm new here and I had tough week :).
2019-03-24Re-order fields in `Def::Ctor`.David Wood-1/+1
This commit moves the `DefId` field of `Def::Ctor` to be the first field.
2019-03-24Move `CtorOf` into `hir::def`.David Wood-2/+2
This commit moves the definition of `CtorOf` from `rustc::hir` to `rustc::hir::def` and adds imports wherever it is used.
2019-03-24Separate variant id and variant constructor id.David Wood-22/+22
This commit makes two changes - separating the `NodeId` that identifies an enum variant from the `NodeId` that identifies the variant's constructor; and no longer creating a `NodeId` for `Struct`-style enum variants and structs. Separation of the variant id and variant constructor id will allow the rest of RFC 2008 to be implemented by lowering the visibility of the variant's constructor without lowering the visbility of the variant itself. No longer creating a `NodeId` for `Struct`-style enum variants and structs mostly simplifies logic as previously this `NodeId` wasn't used. There were various cases where the `NodeId` wouldn't be used unless there was an unit or tuple struct or enum variant but not all uses of this `NodeId` had that condition, by removing this `NodeId`, this must be explicitly dealt with. This change mostly applied cleanly, but there were one or two cases in name resolution and one case in type check where the existing logic required a id for `Struct`-style enum variants and structs.
2019-03-23Auto merge of #59096 - ljedrz:HirIdify_AccessLevel, r=Zoxcbors-18/+33
middle: replace NodeId with HirId in AccessLevels Pushing the limits of HirIdification (#57578). Replaces `NodeId` with `HirId` in `middle::privacy::AccessLevels`. Actually this time I was more successful and cracked it; I probably tried to HirIdify too much at once when I attempted it last time ^^. r? @Zoxc