You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Here, %19 = as(%12, %18) is because of the .ty resultloc. We also need to use the resultloc in the else branch
Edit Edit:
it is actually because of the rlWrapPtr at the end of orelseCatchExpr. Changing it to rlWrap fixes it for the case where b != null, but breaks for b == null. It shows this:
The reason I am submitting this is because it is a blocker for writing tests for #7628 since this also affects catch, which #7628 allows to be run at comptime.
The text was updated successfully, but these errors were encountered:
@Vexu pinging you because you seem to have written the code.
andrewrk
added
enhancement
Solving this issue will likely involve adding new logic or components to the codebase.
frontend
Tokenization, parsing, AstGen, Sema, and Liveness.
labels
Jan 3, 2021
andrewrk
added
bug
Observed behavior contradicts documented or intended behavior
and removed
enhancement
Solving this issue will likely involve adding new logic or components to the codebase.
labels
Jan 3, 2021
This should work, but it does not:
Here is the untyped zir:
I think the problem is the
%23 = deref(%16)
line, which is coming fromrlWrapPtr
at the end oforelseCatchExpr
Adding this does not fix it:
Note, this does work:
This seems like a very easy fix, I just cannot think of a fix.
Edit:
Im pretty sure it is because of the resultLoc mechanism:
Here,
%19 = as(%12, %18)
is because of the .ty resultloc. We also need to use the resultloc in the else branchEdit Edit:
it is actually because of the
rlWrapPtr
at the end of orelseCatchExpr. Changing it torlWrap
fixes it for the case whereb != null
, but breaks forb == null
. It shows this:The reason I am submitting this is because it is a blocker for writing tests for #7628 since this also affects catch, which #7628 allows to be run at comptime.
The text was updated successfully, but these errors were encountered: