forked from OSchip/llvm-project
[flang] Allow user to recover from bad edit descriptor with INTEGER
Runtime was crashing when an INTEGER passed in formatted output with a bad edit descriptor even when the user did provide IOSTAT. Flang is already signaling an error when facing similar error with other types. Do the same with INTEGERs. The input case is already signaling an error in the related input error case. Differential Revision: https://reviews.llvm.org/D122749
This commit is contained in:
parent
14c7754a35
commit
88d4b85f59
|
@ -57,7 +57,7 @@ bool EditIntegerOutput(IoStatementState &io, const DataEdit &edit,
|
|||
return EditCharacterOutput(
|
||||
io, edit, reinterpret_cast<char *>(&n), sizeof n);
|
||||
default:
|
||||
io.GetIoErrorHandler().Crash(
|
||||
io.GetIoErrorHandler().SignalError(IostatErrorInFormat,
|
||||
"Data edit descriptor '%c' may not be used with an INTEGER data item",
|
||||
edit.descriptor);
|
||||
return false;
|
||||
|
|
Loading…
Reference in New Issue