charon_lib::transform

Module remove_drop_never

source
Expand description

The MIR code often contains variables with type ! that come from panic!s and similar !-returning` functions.

We want to get rif of these variables since they are never initialized. The only instruction that uses them is StorageDead, which is a no-op since there is no corresponding StorageLive. We do that in this pass, and the unused local will be removed in remove_unused_locals.

Structsยง