[libcxx-commits] [llvm] [mlir] [flang] [compiler-rt] [lldb] [clang] [libunwind] [libcxx] [lld] [libcxxabi] [clang-tools-extra] [libc] [clang] static operators should evaluate object argument (PR #68485)

via libcxx-commits libcxx-commits at lists.llvm.org
Thu Jan 11 07:21:57 PST 2024


================
@@ -5680,8 +5680,13 @@ static ImplicitConversionSequence TryObjectArgumentInitialization(
   QualType ClassType = S.Context.getTypeDeclType(ActingContext);
   // [class.dtor]p2: A destructor can be invoked for a const, volatile or
   //                 const volatile object.
+  // Also, a static operator can be invoked for a const, volatile or const
+  // volatile object, apparently.
----------------
cor3ntin wrote:

The best wording i can find is this one https://eel.is/c++draft/over.match#funcs.general-4.sentence-5

```suggestion
  C++23 [over.match.funcs.general] p4.2 For static member functions, the implicit object parameter is considered to match any object.
```

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


More information about the libcxx-commits mailing list