[PATCH] D140280: [llvm] Fix APInt to work in C++20 mode
    Joe Loser via Phabricator via llvm-commits 
    llvm-commits at lists.llvm.org
       
    Sun Dec 18 20:21:37 PST 2022
    
    
  
jloser updated this revision to Diff 483857.
jloser edited the summary of this revision.
jloser added a comment.
Prettify commit message formatting
Repository:
  rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D140280/new/
https://reviews.llvm.org/D140280
Files:
  llvm/include/llvm/ADT/APInt.h
Index: llvm/include/llvm/ADT/APInt.h
===================================================================
--- llvm/include/llvm/ADT/APInt.h
+++ llvm/include/llvm/ADT/APInt.h
@@ -2027,9 +2027,11 @@
   /// @}
 };
 
+#if !(__cplusplus > 201703L && __cpp_impl_three_way_comparison >= 201907L)
 inline bool operator==(uint64_t V1, const APInt &V2) { return V2 == V1; }
 
 inline bool operator!=(uint64_t V1, const APInt &V2) { return V2 != V1; }
+#endif
 
 /// Unary bitwise complement operator.
 ///
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D140280.483857.patch
Type: text/x-patch
Size: 495 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221219/06f51ba1/attachment.bin>
    
    
More information about the llvm-commits
mailing list