Skip to content

Conversation

@michaelwoerister
Copy link
Member

@michaelwoerister michaelwoerister commented Dec 8, 2016

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm. I guess you decided that doing the refactoring to break out the span was too difficult? Seems like we could add a ccx.tcx().map.crate_span() helper that just ignores the read-edge easily enough as well, no?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The refactoring turned out to break many implicit assumptions that there is no real root module, especially around DefPaths and HIR map parent relationships. I could give it another try but I'd estimate that it would take me several days to get this right.

Do you have a suggestion where to point the edge alternatively? I'd rather not just ignore it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well I would point it at DepNode::Hir(CRATE_DEF_ID), I think.

Note that DepNode::Krate and the Hir node for the crate def-id are distinct nodes.

@michaelwoerister michaelwoerister force-pushed the fix-debuginfo-namespace-edge branch from 9fc891c to 271fb22 Compare December 12, 2016 17:18
@nikomatsakis
Copy link
Contributor

@bors r+

@bors
Copy link
Collaborator

bors commented Dec 12, 2016

📌 Commit 271fb22 has been approved by nikomatsakis

@michaelwoerister
Copy link
Member Author

Pushed a cleaner fix for this. Reading a the crate's span or attribute will now add an edge to DepNode::Hir(CRATE_DEF_INDEX) instead of to the all encompassing DepNode::Krate.

@bors
Copy link
Collaborator

bors commented Dec 12, 2016

⌛ Testing commit 271fb22 with merge 6483bdd...

bors added a commit that referenced this pull request Dec 12, 2016
… r=nikomatsakis

incr.comp.: Avoid creating an edge to DepNode::Krate when generating debuginfo namespaces.

r? @nikomatsakis

Fixes #38222
@bors bors merged commit 271fb22 into rust-lang:master Dec 12, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants