Skip to main content

comparison_operand_of

Function comparison_operand_of 

Source
fn comparison_operand_of<'gcx>(
    gcx: Gcx<'gcx>,
    expr: &'gcx Expr<'gcx>,
) -> Option<(VariableId, Vec<ElementaryType>, Range)>
Expand description

The variable an operand compares, the casts applied to it and the range its values span.

A same-signed widening cast preserves the value, so it neither changes the range nor distinguishes the operand from the uncast expression; any other cast resets the range to the target type’s and becomes part of the operand’s identity.