[llvm] [flang][runtime] Account for missing READ(SIZE=) characters (PR #153967)
Peter Klausler via llvm-commits
llvm-commits at lists.llvm.org
Sat Aug 16 10:03:12 PDT 2025
https://github.com/klausler created https://github.com/llvm/llvm-project/pull/153967
One of the two formatted real input paths was failing to call GotChar() to account for the characters that it consumes.
Fixes https://github.com/llvm/llvm-project/issues/153830.
>From 009ef5ca943fb585b731571a2659a0f887c56b64 Mon Sep 17 00:00:00 2001
From: Peter Klausler <pklausler at nvidia.com>
Date: Sat, 16 Aug 2025 09:59:58 -0700
Subject: [PATCH] [flang][runtime] Account for missing READ(SIZE=) characters
One of the two formatted real input paths was failing to call
GotChar() to account for the characters that it consumes.
Fixes https://github.com/llvm/llvm-project/issues/153830.
---
flang-rt/lib/runtime/edit-input.cpp | 1 +
1 file changed, 1 insertion(+)
diff --git a/flang-rt/lib/runtime/edit-input.cpp b/flang-rt/lib/runtime/edit-input.cpp
index 4f01623c6cf19..1bfc16cbc966d 100644
--- a/flang-rt/lib/runtime/edit-input.cpp
+++ b/flang-rt/lib/runtime/edit-input.cpp
@@ -663,6 +663,7 @@ static RT_API_ATTRS bool TryFastPathRealDecimalInput(
*reinterpret_cast<decimal::BinaryFloatingPointNumber<PRECISION> *>(n) =
converted.binary;
io.HandleRelativePosition(p - str);
+ io.GotChar(p - str);
// Set FP exception flags
if (converted.flags != decimal::ConversionResultFlags::Exact) {
RaiseFPExceptions(converted.flags);
More information about the llvm-commits
mailing list