[flang-commits] [flang] [flang] pass true/false to EditLogicalOutput directly (NFC) (PR #73375)

Daniel Chen via flang-commits flang-commits at lists.llvm.org
Thu Dec 7 08:42:22 PST 2023


================
@@ -140,7 +140,7 @@ bool EditIntegerOutput(IoStatementState &io, const DataEdit &edit,
     return EditBOZOutput<4>(
         io, edit, reinterpret_cast<const unsigned char *>(&n), KIND);
   case 'L':
-    return EditLogicalOutput(io, edit, *reinterpret_cast<const char *>(&n));
+    return EditLogicalOutput(io, edit, n != 0 ? true : false);
----------------
DanielCChen wrote:

I think the suggestion was to do 
```
return EditLogicalOutput(io, edit, n != 0);
```


https://github.com/llvm/llvm-project/pull/73375


More information about the flang-commits mailing list