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

via flang-commits flang-commits at lists.llvm.org
Thu Dec 7 13:30:36 PST 2023


Author: kkwli
Date: 2023-12-07T16:30:31-05:00
New Revision: 3bc7e552cad6dedb96102421611eadb11c83bd51

URL: https://github.com/llvm/llvm-project/commit/3bc7e552cad6dedb96102421611eadb11c83bd51
DIFF: https://github.com/llvm/llvm-project/commit/3bc7e552cad6dedb96102421611eadb11c83bd51.diff

LOG: [flang] pass true/false to EditLogicalOutput directly (NFC) (#73375)

Added: 
    

Modified: 
    flang/runtime/edit-output.cpp

Removed: 
    


################################################################################
diff  --git a/flang/runtime/edit-output.cpp b/flang/runtime/edit-output.cpp
index 18b209bc6798c..18e2a3f1e537c 100644
--- a/flang/runtime/edit-output.cpp
+++ b/flang/runtime/edit-output.cpp
@@ -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);
   case 'A': // legacy extension
     return EditCharacterOutput(
         io, edit, reinterpret_cast<char *>(&n), sizeof n);


        


More information about the flang-commits mailing list