> Have a few clarifications, assuming we take the following example: > > public void method foo() { > > > if (e instanceof String s) { > // s allowed > } else { > // s not allowed > } > // A: s should not be allowed here? > }
In this example, s is allowed at A if and only if the ELSE block never completes normally. (In that case, in all the cases you could get to A, it is because the match succeeded, and hence s would be DA.)