Commit Graph

18 Commits

Author SHA1 Message Date
marmeladema
1d3f49f536 Always create a root definition when creating a new Definitions object. 2020-06-21 23:13:31 +01:00
marmeladema
f60513ec8d Move remaining NodeId APIs from Definitions to Resolver 2020-06-21 23:13:31 +01:00
marmeladema
13104ef1c5 Pre-compute def_id_to_hir_id table 2020-06-20 13:02:05 +01:00
marmeladema
94817e38e1 Pre-compute hir_id_to_def_id mapping 2020-06-20 11:03:58 +01:00
marmeladema
6a0f1af19d Remove HirId to NodeId conversion APIs 2020-06-20 11:03:58 +01:00
marmeladema
a98f35f503 Remove NodeId to HirId conversion APIs 2020-06-20 11:03:57 +01:00
Vadim Petrochenkov
73d5cb0a45 expand: Give reasonable NodeIds to lints associated with macro expansions 2020-06-09 22:27:13 +03:00
marmeladema
d0fccb552b Remove unsused NodeId related APIs in hir map 2020-06-04 20:32:35 +01:00
marmeladema
2f3dd7b187 Remove remaining calls to as_local_node_id 2020-05-29 20:05:44 +01:00
marmeladema
5728c5371d Use HirId as key for ResolverOutputs::trait_map instead of NodeId 2020-05-21 17:07:47 +01:00
Josh Stone
2325c20925 Avoid unused Option::map results
These are changes that would be needed if we add `#[must_use]` to
`Option::map`, per #71484.
2020-04-24 13:58:41 -07:00
marmeladema
bfce24aa67 Modify as_local_hir_id to return a bare HirId 2020-04-23 23:14:07 +01:00
marmeladema
6148db719f Modify as_local_hir_id to accept a LocalDefId instead of a DefId 2020-04-23 23:14:07 +01:00
marmeladema
c15e13ae16 Remove DUMMY_HIR_ID 2020-04-14 08:46:07 +01:00
marmeladema
b9161ab880 Do not use DUMMY_HIR_ID as placeholder value in node_id_to_hir_id table
Some helpers functions have been introduced to deal with (buggy) cases
where either a `NodeId` or a `DefId` do not have a corresponding `HirId`.
Those cases are tracked in issue #71104.
2020-04-14 08:46:07 +01:00
marmeladema
59e0db69e0 librustc_hir: return LocalDefId instead of DefId in local_def_id 2020-04-08 00:43:56 +01:00
Bastian Kauschke
37603f499a clarify hir_id <-> node_id method names 2020-03-27 16:43:20 +01:00
Mazdak Farrokhzad
14f89ded2c {rustc::hir::map -> rustc_hir}::definitions 2020-03-21 22:20:24 +01:00