compile back to hard scope when closure compile/build requested #4392
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
tbh I am super bothered I cannot figure out a test case to at least occasionally fail. I explain the basic issue in #4304 (more specifically #4304 (comment)). Summarized as two threads both decide to build something and one is a child closure and the other is a parent of that closure. We get a sequence like:
This code will ask hard scope to full build itself for blocks and the two entry points to building on IRScope will built the closures before the parent. It does not appear to infinite loop so yay? I could not see anything bust with this change and I think the intent is clear but I am unsure in best particular impl to use. Part of it is based on children wanting parent info for passes vs parents wanting children info for passes.
@subbuss I think you have best knowledge of these expectations and @headius I would like your thoughts as well.