[clang-tools-extra] [clang-tidy] Fix crash in `cppcoreguidelines-pro-type-member-init` with alias template in constructor initializer (PR #192786)

via cfe-commits cfe-commits at lists.llvm.org
Sat Apr 18 04:43:23 PDT 2026


flovent wrote:

Well, for windows there will be no `CXXCtorInitializer` in ctor, so i remove the check-message (it will be reported in other systems but not windows): 

Windows:
```
`-CXXConstructorDecl <line:15:5, col:12> col:5 X<T> 'void (INT)' implicit-inline
        |-ParmVarDecl <col:7, col:11> col:11 i 'INT':'C<T>'
        `-<<<NULL>>>
```
Linux:
```
-CXXConstructorDecl <line:15:5, col:24> col:5 X<T> 'void (INT)' implicit-inline
        |-ParmVarDecl <col:7, col:11> col:11 referenced i 'INT':'C<T>'
        |-CXXCtorInitializer 'INT':'C<T>'
        | `-ParenListExpr <col:19, col:21> 'NULL TYPE'
        |   `-DeclRefExpr <col:20> 'INT':'C<T>' lvalue ParmVar 0x21813138 'i' 'INT':'C<T>'
        `-CompoundStmt <col:23, col:24>
```

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


More information about the cfe-commits mailing list