================
@@ -150,6 +148,12 @@ static Cl::Kinds ClassifyInternal(ASTContext &Ctx, const 
Expr *E) {
   case Expr::OMPIteratorExprClass:
     return Cl::CL_LValue;
 
+    // C++ [expr.prim.general]p1: A string literal is an lvalue.
+    // Except we special case them as prvalues when they are used for
+    // initialization.
----------------
efriedma-quic wrote:

Maybe say more specifically "to initialize a char array".

https://github.com/llvm/llvm-project/pull/101447
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to