diff --git a/src/tools/illink/test/Mono.Linker.Tests/TestCasesRunner/AssemblyChecker.cs b/src/tools/illink/test/Mono.Linker.Tests/TestCasesRunner/AssemblyChecker.cs index 8cec5a657dd42..36031245d5191 100644 --- a/src/tools/illink/test/Mono.Linker.Tests/TestCasesRunner/AssemblyChecker.cs +++ b/src/tools/illink/test/Mono.Linker.Tests/TestCasesRunner/AssemblyChecker.cs @@ -3,6 +3,7 @@ using System; using System.Collections.Generic; +using System.Globalization; using System.Linq; using System.Text; using Mono.Cecil; @@ -628,13 +629,13 @@ static string FormatInstruction (Instruction instr) case Code.Ldc_R4: if (instr.Operand is float fvalue) - return $"{instr.OpCode.ToString ()} {fvalue.ToString ()}"; + return $"{instr.OpCode.ToString ()} {fvalue.ToString (CultureInfo.InvariantCulture)}"; throw new NotImplementedException (instr.Operand.GetType ().ToString ()); case Code.Ldc_R8: if (instr.Operand is double dvalue) - return $"{instr.OpCode.ToString ()} {dvalue.ToString ()}"; + return $"{instr.OpCode.ToString ()} {dvalue.ToString (CultureInfo.InvariantCulture)}"; throw new NotImplementedException (instr.Operand.GetType ().ToString ());