about summary refs log tree commit diff
path: root/src/librustc/middle/dead.rs
AgeCommit message (Collapse)AuthorLines
2019-10-04middle::dead -> rustc_passesMark Rousskov-676/+0
2019-09-26Rename `ForeignItem.node` to `ForeignItem.kind`varkor-1/+1
2019-09-26Rename `Item.node` to `Item.kind`varkor-6/+6
2019-09-26Rename `Ty.node` to `Ty.kind`varkor-1/+1
2019-09-26Rename `TraitItem.node` to `TraitItem.kind`varkor-2/+2
2019-09-26Rename `ImplItem.node` to `ImplItem.kind`varkor-1/+1
2019-09-26Rename `Pat.node` to `Pat.kind`varkor-2/+2
2019-09-26Rename `Expr.node` to `Expr.kind`varkor-1/+1
For both `ast::Expr` and `hir::Expr`.
2019-09-26Auto merge of #64513 - varkor:sty-begone, r=eddybbors-3/+3
Rename `TyS.sty` to `TyS.kind` Fixes https://github.com/rust-lang/rust/issues/64353. r? @eddyb
2019-09-25Rename `sty` to `kind`varkor-3/+3
2019-09-21or-patterns: middle/dead: remove `top_pats_hack`.Mazdak Farrokhzad-14/+7
Also tweak walkers on `Pat`.
2019-09-16or-patterns: middle/dead: make a hack less hacky.Mazdak Farrokhzad-2/+2
2019-09-15or-patterns: use `top_pats_hack` to make things compile.Mazdak Farrokhzad-2/+3
2019-08-21Do not complain about unused code when used in `impl` `Self` typeEsteban Küber-6/+20
2019-08-15Remove `Spanned` from `{ast,hir}::FieldPat`Vadim Petrochenkov-6/+4
2019-08-14Merge Variant and Variant_Caio-6/+6
2019-08-04Rename `ItemImplKind::Type` to `ItemImplKind::TyAlias`varkor-1/+1
2019-08-04Rename `ItemKind::Ty` to `ItemKind::TyAlias`varkor-1/+1
2019-08-03Rollup merge of #63227 - jakubadamw:issue-63151, r=estebankMazdak Farrokhzad-2/+3
dead_code: Properly inspect fields in struct patterns with type relative paths Closes #63151.
2019-08-02dead_code: Properly inspect fields in struct patterns with type relative pathsJakub Adam Wieczorek-2/+3
2019-08-02Replace "existential" by "opaque"varkor-1/+1
2019-07-24syntax_ext: Turn `#[global_allocator]` into a regular attribute macroVadim Petrochenkov-5/+0
2019-07-04rename hir::map::local_def_id_from_hir_id to local_def_idljedrz-4/+4
2019-07-03Remove needless lifetimesJeremy Stucki-2/+2
2019-06-24HIR: rename find_by_hir_id to findljedrz-2/+2
2019-06-18rustc: remove 'x: 'y bounds (except from comments/strings).Eduard-Mihai Burtescu-2/+2
2019-06-17remove _by_hir_id if there is no NodeId counterpartljedrz-1/+1
2019-06-14Unify all uses of 'gcx and 'tcx.Eduard-Mihai Burtescu-8/+8
2019-06-12Run `rustfmt --file-lines ...` for changes from previous commits.Eduard-Mihai Burtescu-9/+11
2019-06-12rustc: replace `TyCtxt<'tcx, 'gcx, 'tcx>` with `TyCtxt<'gcx, 'tcx>`.Eduard-Mihai Burtescu-8/+8
2019-06-12Fix fallout from `deny(unused_lifetimes)`.Eduard-Mihai Burtescu-4/+4
2019-06-12rustc: replace `TyCtxt<'a, 'gcx, 'tcx>` with `TyCtxt<'tcx, 'gcx, 'tcx>`.Eduard-Mihai Burtescu-10/+10
2019-06-01rustc: remove Res::Upvar.Eduard-Mihai Burtescu-1/+1
2019-05-26Rename "Associated*" to "Assoc*"Andrew Xu-1/+1
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-13Pass a `Symbol` to `check_name`, `emit_feature_err`, and related functions.Nicholas Nethercote-4/+5
2019-05-03rustc: rename hir::def::Def to Res (short for "resolution").Eduard-Mihai Burtescu-21/+21
2019-05-03rustc: factor most DefId-containing variants out of Def and into DefKind.Eduard-Mihai Burtescu-4/+6
2019-03-29Rollup merge of #59486 - varkor:dead-code-impl, r=sanxiynMazdak Farrokhzad-8/+6
Visit `ImplItem` in `dead_code` lint Fixes https://github.com/rust-lang/rust/issues/47131.
2019-03-28Walk all items for dead_code lint by defaultvarkor-9/+6
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-28Visit ItemKind::Impl for dead code lintvarkor-0/+1
2019-03-25Allocate HIR id counters for use trees in MiscCollectorJohn Kåre Alsaker-1/+1
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-12/+27
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-1/+1
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
2019-03-16Add def getting methods to librustc/ty/contextTomas Koutsky-2/+2
2019-03-15rustc: remove TyCtxt::parent_def_id in favor of TyCtxt::parent.Eduard-Mihai Burtescu-2/+2
2019-03-13middle: replace NodeId with HirId in AccessLevelsljedrz-1/+1
2019-03-12Visit impl Trait for dead_code lintSeo Sanghyeon-1/+12