[clang] [clang] Allow attributes on first constructor argument in pre-C++11 (PR #157300)
Shafik Yaghmour via cfe-commits
cfe-commits at lists.llvm.org
Mon Sep 8 08:12:29 PDT 2025
================
@@ -6007,10 +6007,9 @@ bool Parser::isConstructorDeclarator(bool IsUnqualified, bool DeductionGuide,
// A C++11 attribute here signals that we have a constructor, and is an
// attribute on the first constructor parameter.
- if (getLangOpts().CPlusPlus11 &&
- isCXX11AttributeSpecifier(/*Disambiguate*/ false,
+ if (isCXX11AttributeSpecifier(/*Disambiguate*/ false,
----------------
shafik wrote:
```suggestion
if (isCXX11AttributeSpecifier(/*Disambiguate=*/false,
```
https://github.com/llvm/llvm-project/pull/157300
More information about the cfe-commits
mailing list