Migrate stubbing transformation to be performed in the instance body #3072
Labels
[C] Internal
Tracks some internal work. I.e.: Users should not be affected.
[I] Refactoring / Clean Up
Refactoring or cleaning up of existing code
Proposed change:
Perform stubbing in the instance body instead of the generic one.
Motivation
This will simplify stubbing code, remove the redundant compilation and provide more precise error handling.
Background:
The stubbing transformation and validation are spread into multiple stages. The stubbing itself is done in the generic body by hijacking rustc's transformation query. Because of that, we have the following limitations:
collect_and_partition_mono_items
query to avoid an ICE related to the delayed validation of the instantiation requirements.There is a downside though. Today, we are able to apply the stubs to concrete playback, which wouldn't be possible until changes to the StableMIR are visible to the rust compiler.
The text was updated successfully, but these errors were encountered: