summary refs log tree commit diff
path: root/src/librustc_resolve/lib.rs
AgeCommit message (Collapse)AuthorLines
2016-11-03Fix label scopes.Jeffrey Seyfried-19/+13
2016-09-26Update E0425, E0446, E0449Jonathan Turner-4/+9
2016-09-24Load macros from `#[macro_use]` extern crates in `resolve`.Jeffrey Seyfried-0/+6
2016-09-23Load extern crates in `resolve`.Jeffrey Seyfried-4/+5
2016-09-22Use `Resolver::visit_expansion` only with monotonic expansions.Jeffrey Seyfried-2/+5
2016-09-22Refactor `no_implicit_prelude: Cell<bool>` -> `no_implicit_prelude: bool`.Jeffrey Seyfried-23/+21
2016-09-22Refactor away `ParentLink`.Jeffrey Seyfried-81/+66
2016-09-20rustc_metadata: group information into less tags.Eduard Burtescu-2/+2
2016-09-20rustc_metadata: move more RBML tags to auto-serialization.Eduard Burtescu-0/+1
2016-09-20rustc: replace uses of NodeId in Def, other than closures and labels.Eduard Burtescu-6/+7
2016-09-20rustc_metadata: go only through rustc_serialize in astencode.Eduard Burtescu-2/+2
2016-09-20rustc_metadata: remove astencode tests.Eduard Burtescu-2/+2
2016-09-15Rollup merge of #36438 - jseyfried:node_ids_in_expansion, r=nrcManish Goregaokar-4/+17
Assign node ids during macro expansion After this PR, - The `ExtCtxt` can access `resolve`'s `Resolver` through the trait object `ext::base::Resolver`. - The `Resolver` trait object can load macros and replaces today's `MacroLoader` trait object. - The macro expander uses the `Resolver` trait object to resolve macro invocations. - The macro expander assigns node ids and builds the `Resolver`'s `macros_at_scope` map. - This is groundwork for merging import resolution and expansion. - Performance of expansion together with node id assignment improves by ~5%. **EDIT:** Since Github is reordering the commits, here is `git log`: - b54e1e399741579612f13e2df98a25ea9447989d: Differentiate between monotonic and non-monotonic expansion and only assign node ids during monotonic expansion. - 78c00398780db6f59ebf43e765fa9368dad436d2: Expand generated test harnesses and macro registries. - f3c2dca3539e6edc745f9c91898cb97d281865c1: Remove scope placeholders from the crate root. - c86c8d41a26b2037e80c9fd028a59313a78b3a66: Perform node id assignment and `macros_at_scope` construction during the `InvocationCollector` and `PlaceholderExpander` folds. - 72a636975fc5d0bb4af45af7bdd97987cc722a6a: Move macro resolution into `librustc_resolve`. - 20b43b23230ce063ccf99a4841d85790ad311bdf: Rewrite the unit tests in `ext/expand.rs` as a `compile-fail` test. - a9821e1658240bb2c056f260a4b6bc9789301fae: Refactor `ExtCtxt` to use a `Resolver` instead of a `MacroLoader`. - 60440b226d2f70bdae803443ff7ad2e2af2c9b10: Refactor `noop_fold_stmt_kind` out of `noop_fold_stmt`. - 50f94f6c95c944f08c4af264f48260e42efefd47: Avoid needless reexpansions. r? @nrc
2016-09-13Perform node id assignment and `macros_at_scope` construction duringJeffrey Seyfried-1/+0
the `InvocationCollector` and `PlaceholderExpander` folds.
2016-09-13Move macro resolution into `librustc_resolve`.Jeffrey Seyfried-10/+8
2016-09-13Refactor `ExtCtxt` to use a `Resolver` instead of a `MacroLoader`.Jeffrey Seyfried-1/+17
2016-09-13fix "X is not a member of trait Y" span labelsAlex Burka-3/+3
The span labels for associated types and consts were hardcoded to `Foo` rather than substituting the name of the trait. This also normalizes the wording for associated methods', traits', and consts' span labels. Fixes #36428.
2016-09-06Add struct `AmbiguityError`.Jeffrey Seyfried-4/+11
2016-09-06Add field `used: Cell<bool>` to variant `NameBindingKind::Import`.Jeffrey Seyfried-22/+16
2016-09-06Avoid false positive unused import warnings.Jeffrey Seyfried-5/+6
2016-09-04Replace `_, _` with `..`Vadim Petrochenkov-8/+8
2016-09-04Replace `_, _, _` with `..`Vadim Petrochenkov-2/+3
2016-09-03Some better support for unions through the compilerVadim Petrochenkov-2/+3
2016-09-02Address comments.Jeffrey Seyfried-14/+20
2016-09-01Avoid cascading name resolution errors caused by an ambiguous module.Jeffrey Seyfried-29/+39
2016-09-01Avoid reporting multiple ambiguity errors for a single use of a name.Jeffrey Seyfried-11/+19
2016-09-01item_like_imports: Allow unused ambiguous glob imports.Jeffrey Seyfried-2/+32
2016-09-01item_like_imports: Make all visible items glob importable.Jeffrey Seyfried-0/+4
2016-09-01Add `item_like_imports` feature.Jeffrey Seyfried-0/+2
2016-09-01Add field `dummy_binding` to `Resolver`.Jeffrey Seyfried-1/+7
2016-09-01Refactor away `resolver.current_vis` and add `module.normal_ancestor_id`.Jeffrey Seyfried-69/+37
2016-09-01Improve diagnostics and remove dead code.Jeffrey Seyfried-29/+17
2016-09-01Refactor `binding.def()` to return a `Def` instead of an `Option<Def>`.Jeffrey Seyfried-17/+17
2016-09-01Refactor away `binding.is_pseudo_public()`.Jeffrey Seyfried-4/+0
2016-08-31Rollup merge of #35773 - EugeneGonzalez:master, r=jonathandturnerJonathan Turner-1/+5
Change E0259 to the new error format Fixes #35514 as part of #35233. Sorry about creating a new PR I was having a lot of troubles squashing the commit because I didn't properly branch the new feature. r? @GuillaumeGomez
2016-08-30Change E0259 to the new error formatEugene R Gonzalez-1/+5
Fixed E0259 unit test Added name of conflict to E0259's note
2016-08-30Auto merge of #36126 - GuillaumeGomez:rollup, r=GuillaumeGomezbors-1/+5
Rollup of 16 pull requests - Successful merges: #35418, #35759, #35862, #35863, #35895, #35962, #35977, #35993, #35997, #36054, #36056, #36060, #36086, #36100, #36103, #36125 - Failed merges: #35771, #35810
2016-08-30Auto merge of #36066 - jseyfried:rollup, r=Manishearthbors-0/+1
Batch up libsyntax breaking changes Batch of the following syntax-[breaking-change] changes: - #35591: Add a field `span: Span` to `ast::Generics`. - #35618: Remove variant `Mod` of `ast::PathListItemKind` and refactor the remaining variant `ast::PathListKind::Ident` to a struct `ast::PathListKind_`. - #35480: Change uses of `Constness` in the AST to `Spanned<Constness>`. - c.f. `MethodSig`, `ItemKind` - #35728: Refactor `cx.pat_enum()` into `cx.pat_tuple_struct()` and `cx.pat_path()`. - #35850: Generalize the elements of lists in attributes from `MetaItem` to a new type `NestedMetaItem` that can represent a `MetaItem` or a literal. - #35917: Remove traits `AttrMetaMethods`, `AttributeMethods`, and `AttrNestedMetaItemMethods`. - Besides removing imports of these traits, this won't cause fallout. - Add a variant `Union` to `ItemKind` to future proof for `union` (c.f. #36016). - Remove inherent methods `attrs` and `fold_attrs` of `Annotatable`. - Use methods `attrs` and `map_attrs` of `HasAttrs` instead. r? @Manishearth
2016-08-29Update E0260 to new error formatMohit Agarwal-1/+5
Updates #35515. Part of #35233. r? @jonathandturner
2016-08-29Future proof the AST for `union`.Jeffrey Seyfried-0/+1
2016-08-27Use `FnvHashMap` in more placesJonas Schievink-25/+24
* A step towards #34902 * More stable error messages in some places related to crate loading * Possible slight performance improvements since all `HashMap`s replaced had small keys where `FnvHashMap` should be faster (although I didn't measure)
2016-08-22Rollup merge of #35858 - shyaamsundhar:patch-1, r=GuillaumeGomezJonathan Turner-6/+12
E0435, E0437 & E0438 New Error Format Part of #35801 , #35802 and #35803 r? @GuillaumeGomez Hi! Please review the changes.
2016-08-22Rollup merge of #35841 - kyrias:new-error-E0424, r=GuillaumeGomezJonathan Turner-3/+5
Update E0424 to the new error format Fixes #35797. Part of #35233. r? @GuillaumeGomez
2016-08-22Rollup merge of #35835 - crypto-universe:E0426, r=jonathandturnerJonathan Turner-5/+7
New format for E0426 Issue #35799 as a part of issue #35233 r? jonathandturner
2016-08-22 Updated E0423 to new formatKnight-2/+4
2016-08-22 Updated E0432 to new formatKnight-2/+6
2016-08-21Auto merge of #35776 - jseyfried:more_groundwork, r=nrcbors-97/+56
resolve: More groundwork for `item_like_imports` (RFC 1560) r? @nrc
2016-08-21Update lib.rsShyam Sundar B-6/+12
Update lib.rs Update lib.rs Update E0438.rs Update E0437.rs Update E0435.rs
2016-08-20Update E0424 to the new error formatJohannes Löthberg-3/+5
Fixes #35797. Signed-off-by: Johannes Löthberg <johannes@kyriasis.com>
2016-08-19New format for E0426crypto-universe-5/+7
Issue #35799 as a part of issue #35233 ?r jonathandturner