Validate uses of ids defined in unreachable blocks. (#2146)
* Validate uses of ids defined in unreachable blocks. For some reason we do not make sure the uses of ids that are defined in unreachable blocks are dominated by their def. This is causing invalid code to pass the validator. Fixes #2143 * Add test for unreachable code after a return. We want to allow code like: ``` void foo() { a = ...; ... return; // for debugging <use of a>; ... } ``` I added a test to make sure that something like this is still accepted by the validator. * Add test for unreachable def used in phi.
Loading
Please register or sign in to comment