Closure region hierarchy#23109
Conversation
There was a problem hiding this comment.
so, I know what this comment is saying because we've talked about it, but this sentence as written is too difficult to parse. (In particular, I worry about someone misparsing it as "... to compare (a region 'a from (a closure with a region 'b)) from (the fn that encloses it) ..."
I know that grammatically, that alternative parsing does not make sense. But I still think a rephrasing is in order; this stuff is hard enough to follow as it is.
Maybe even just putting in a few more names:
Let C be some closure and let F be the fn that encloses it. When we are asked to compare a region
'afrom C with a region'bfrom F, we can in fact assume'bis the larger region. (Sort of.)
|
@nikomatsakis feel free to r=me after addressing the comment-nits I noted above. |
its own disjoint region tree, and the new table encodes the lexical relationships between those trees.
hierarchies are judged based on the lexical relationship of their respective fn bodies.
case where `None` was returned should never happen in practice; it amounts to comparing regions from two unrelated hierarchies. (I was also not able to make it happen.)
1411d06 to
f15813d
Compare
Adjust internal treatment of the region hierarchy around closures. Work towards #3696.
r? @pnkfelix