Hello Cppcheck team. Greetings!
With latest Cppcheck v2.9, it reports [internalAstError] Syntax Error: AST broken, 'libName' doesn't have a parent error for below code snippet.
template <class libnameselectortype,="" class="" loadfntype=""> HMODULE f(LibNameSelectorType &LibNameSelector, LoadFnType LoadFn) { HMODULE hLib {nullptr}; auto libName = LibNameSelector.baseType(); auto catchName = [&] (decltype(libName.name) name) { libName.name = name; return name; }; }</class>
- I think Cppcheck simply does not understand syntax as per the error message. could you please help check it.
Thanks for reporting, we have a ticket for this issue here: https://trac.cppcheck.net/ticket/10739
Thanks confirming it. Is it targeted for Milestone > 2.9 +
Log in to post a comment.
Hello Cppcheck team.
Greetings!
With latest Cppcheck v2.9, it reports [internalAstError] Syntax Error: AST broken, 'libName' doesn't have a parent error for below code snippet.
template <class libnameselectortype,="" class="" loadfntype="">
HMODULE f(LibNameSelectorType &LibNameSelector, LoadFnType LoadFn)
{
HMODULE hLib {nullptr};
auto libName = LibNameSelector.baseType();
auto catchName = [&] (decltype(libName.name) name) { libName.name = name; return name; };
}</class>
-
I think Cppcheck simply does not understand syntax as per the error message. could you please help check it.
Thanks for reporting, we have a ticket for this issue here: https://trac.cppcheck.net/ticket/10739
Thanks confirming it.
Is it targeted for Milestone > 2.9 +