lmi-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lmi-commits] [lmi] master ea937af 3/7: Update #endif comments when #if


From: Greg Chicares
Subject: [lmi-commits] [lmi] master ea937af 3/7: Update #endif comments when #if conditions change
Date: Tue, 13 Nov 2018 12:21:36 -0500 (EST)

branch: master
commit ea937af80d41451e5a53fb9381d0f3537d091f08
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>

    Update #endif comments when #if conditions change
    
    See:
      https://www.gnu.org/prep/standards/html_node/Comments.html
---
 getopt.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/getopt.cpp b/getopt.cpp
index a630fcd..f39ae09 100644
--- a/getopt.cpp
+++ b/getopt.cpp
@@ -733,7 +733,7 @@ GetOpt::operator()()
 #if defined __GNUC__ && !defined __clang__
 #   pragma GCC diagnostic push
 #   pragma GCC diagnostic ignored "-Wuseless-cast"
-#endif // defined __GNUC__
+#endif // defined __GNUC__ && !defined __clang__
     // i686-w64-mingw32-g++-7.3 flags this cast as "useless", but
     // that seems to be a defect: the first argument is const, so
     // the return value is also const. Perhaps the presence of C99's
@@ -742,7 +742,7 @@ GetOpt::operator()()
     char* temp = const_cast<char*>(std::strchr(noptstring.c_str(), c));
 #if defined __GNUC__ && !defined __clang__
 #   pragma GCC diagnostic pop
-#endif // defined __GNUC__
+#endif // defined __GNUC__ && !defined __clang__
 
     // Increment 'optind' when we start to process its last character.
     if(*nextchar == 0)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]