Having a hard time understanding anchored ARC lifetimes

Shadowing does not end a binding's lifetime, even though there's no way to access it anymore (this is observable in debug builds the debugger). And arguably shadowing using guard, as opposed to a proper nested scope, should never have been allowed for consistency reasons, but that'd be source-breaking to change, and people do like it.

(EDIT: and I'm not the one to speak about everything else, but my guess is that assigning to _ does not sufficiently count as a use, but nearly any other use would be, including your closures that don't actually do anything.)

1 Like