Bug 515505 - kdevelop crashes after typing "std::array"
Summary: kdevelop crashes after typing "std::array"
Status: REPORTED
Alias: None
Product: kdevelop
Classification: Applications
Component: Code completion (other bugs)
Version First Reported In: 6.3.250803
Platform: Gentoo Packages Linux
: NOR crash
Target Milestone: ---
Assignee: kdevelop-bugs-null
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2026-02-04 15:20 UTC by Guido Winkelmann
Modified: 2026-02-04 15:48 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments
Backtrace from running kdevelop from inside of gdb (372.42 KB, text/plain)
2026-02-04 15:20 UTC, Guido Winkelmann
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Guido Winkelmann 2026-02-04 15:20:46 UTC
Created attachment 189213 [details]
Backtrace from running kdevelop from inside of gdb

***
Immediately after typing "std::array" at the beginning of a (not otherwise empty) line, kdevelop crashes with a segmentation fault.

Dr. Konqi is unable to produce a backtrace of the crash for some reason as described here:

https://discuss.kde.org/t/dr-konqi-cannot-load-a-backtrace-after-kdevelop-crashes/43991

but I ran kdevelop from within gdb to get a backtrace anyway.
***

SUMMARY


STEPS TO REPRODUCE
1.  Have a very short test C++ project with a main.cpp that #includes <array>
2. Have a line in there reading "uint32_t random_bytes_buffer[buffer_size];"
3. Try to change the C style array to a C++ style std::array<uint32_t, 4>, beginning by deleting the "uint32_t" keyword and replacing it with "std::array".

OBSERVED RESULT

Kdevelop crashes.

EXPECTED RESULT

Kdevelop should not crash.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 
KDE Plasma Version: 6.5.5
KDE Frameworks Version: 6.22.0
Qt Version: 6.10.1
LLVM: 21.1.8

ADDITIONAL INFORMATION

Note: The crash seems to happen deep inside of LLVM code. It may actually be a bug in LLVM instead of kdevelop itself.
Comment 1 Guido Winkelmann 2026-02-04 15:23:57 UTC
BTW, the project in question is extremely simple and short and not sensitive at all. I can post the whole thing if that's helpful.
Comment 2 Guido Winkelmann 2026-02-04 15:27:55 UTC
Forgot to mention: The crash is 100% reproducible for me at the moment.
Comment 3 Guido Winkelmann 2026-02-04 15:48:34 UTC
When removing the [buffer_size] at the end of the variable name first, I can change the uint32_t to std::array<uint32_t, buffer_size> without a crash.