pub fn handle_unspecified_float_assignment(
context: &CompilationContext,
let_stmt: &LetStatement,
_expr_type: &TypeId,
) -> SemanticResult
Expand description
Handles assignment of an unspecified float literal to a variable with a declared type.
§Arguments
context
- The compilation contextlet_stmt
- The let statement being analyzed._expr_type
- The type of the initialization expression (should be unspecified_float_type).
§Returns
Ok(type_id)
with the declared type if the literal is valid for that type.Err
with a SemanticAnalysisError if there’s a type mismatch or value out of range.