diff --git a/compiler/passes/src/type_checking/check_expressions.rs b/compiler/passes/src/type_checking/check_expressions.rs index 670774f79d..fd1168efe1 100644 --- a/compiler/passes/src/type_checking/check_expressions.rs +++ b/compiler/passes/src/type_checking/check_expressions.rs @@ -588,7 +588,7 @@ impl<'a> ExpressionVisitor<'a> for TypeChecker<'a> { } fn visit_literal(&mut self, input: &'a Literal, expected: &Self::AdditionalInput) -> Self::Output { - fn parse_integer_literal(handler: &Handler, raw_string: &String, span: Span, type_string: &str) { + fn parse_integer_literal(handler: &Handler, raw_string: &str, span: Span, type_string: &str) { let string = raw_string.replace('_', ""); if string.parse::().is_err() { handler.emit_err(TypeCheckerError::invalid_int_value(string, type_string, span)); @@ -621,7 +621,7 @@ impl<'a> ExpressionVisitor<'a> for TypeChecker<'a> { self.assert_and_return_type(Type::Integer(IntegerType::U128), expected, input.span()) } IntegerType::I8 => { - parse_integer_literal::(self.handler, &string, input.span(), "i8"); + parse_integer_literal::(self.handler, string, input.span(), "i8"); self.assert_and_return_type(Type::Integer(IntegerType::I8), expected, input.span()) } IntegerType::I16 => {