Summary: | Crash in CMake Background Parser [CMakeFunctionArgument::CMakeFunctionArgument, DeclarationBuilder::startVisiting] | ||
---|---|---|---|
Product: | [Applications] kdevelop | Reporter: | Daniel Stöckel <daniel+kde> |
Component: | Build tools: CMake | Assignee: | kdevelop-bugs-null |
Status: | RESOLVED FIXED | ||
Severity: | crash | CC: | aleixpol, cordlandwehr, eugene.shalygin+bugzilla.kde |
Priority: | NOR | Keywords: | drkonqi |
Version: | git master | ||
Target Milestone: | --- | ||
Platform: | Arch Linux | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | 5.0.0 | |
Sentry Crash Report: | |||
Attachments: |
Skip CMake functions without arguments.
Skip CMake functions without arguments. |
Description
Daniel Stöckel
2016-06-04 09:38:25 UTC
Created attachment 99380 [details]
Skip CMake functions without arguments.
The problem seems to be that the startVisiting method of DeclarationBuilder assumes that there is always an argument to a CMake function. This seems to be wrong in some instances. The attached patch fixes the crash for me, but I am not sure whether it is the right thing to do here.
Created attachment 99381 [details]
Skip CMake functions without arguments.
The problem seems to be that the startVisiting method of DeclarationBuilder assumes that there is always an argument to a CMake function. This seems to be wrong in some instances. The attached patch fixes the crash for me, but I am not sure whether it is the right thing to do here.
It looks like #363943 is a duplicate of this bug. *** Bug 363943 has been marked as a duplicate of this bug. *** For me it crashes on `macro (MACRO_OPTIONAL_FIND_PACKAGE _name )` which does have arguments, but func.arguments list is empty in the DeclarationBuilder::startVisiting(). A similar patch saves me from crashes, but cmake parsing seems to be incomplete, because completion does not work in some cmake files now. Daniel, can you retest with current master? The cmake parsing crash should be fixed with b4263571146bab54459dd0aa122fc5dc604705d5. If not, please feel free to re-open. I can no longer reproduce the crash. Thank you for fixing this! I still want to know how macro (MACRO_OPTIONAL_FIND_PACKAGE _name ) (see my description in #363943) is considered to be a macro without parameters? |