Sysprogs forums › Forums › VisualGDB › C++20 intellisense support
Tagged: visualgdb intellisense
- This topic has 7 replies, 3 voices, and was last updated 1 year, 4 months ago by Timo Engelmann.
-
AuthorPosts
-
September 5, 2022 at 05:59 #33118oto313Participant
Hi,
Does clang intellisense support C++20? What version of clang intellisense is bundled with VisualGDB?
Thanks
September 5, 2022 at 08:46 #33120supportKeymasterHi,
Our Clang IntelliSense uses Clang 6.0 that supports many of the C++20 features. That said, since it uses the headers directly from your toolchain, the toolchain must support C++20 as well and it should be selected via the “language standard” setting in project properties, as many toolchains default to a lower C++ language standard version.
September 7, 2022 at 10:05 #33139oto313ParticipantHi,
I have problem when I switch to c++2a. It says for example “Error: unknown type name “‘BulkMotorSettings’; did you mean ‘std::BulkMotorSettings'” see attachment. For every type included from another file it says “Error: unknown type name ‘Class’; did you mean ‘std::Class”. When I switch back to c++17 it works as expected. Do you know where could be a problem? The project is compile successfully with c++17 and with c++2a. There is problem only with intellisense
Thanks
Attachments:
You must be logged in to view attached files.September 8, 2022 at 12:19 #33151supportKeymasterHi,
If the compilation is working, most likely some parts of the platform headers use C++20 features that are not yet supported by our Clang IntelliSense engine. We are planning to release a major update to the engine in the next few months, so it should take care of it.
Until then, the only way to troubleshoot such issues would be to narrow them down to a specific broken identifier, checking where it is actually defined, and trying to move the definition around to see what triggers the issue. Most likely, IntelliSense stops parsing when it encounters a very specific language construct that it cannot work around, so the entities declared after it are not recognized. If you can locate a specific construct causing it, you can try wrapping it with #ifndef __SYSPROGS_CODESENSE__ so that the IntelliSense engine will ignore it.
September 9, 2022 at 05:47 #33162oto313ParticipantOk thanks I will wait for next release. Hope it will be soon.
August 11, 2023 at 15:47 #34578Timo EngelmannParticipant<p style=”text-align: left;”>Hi,
is there an update regarding the C++20 support of Intellisense?
I use
– VisualGDB 5.6R9 build 4777
– STM32 CMake Project with ARM toolchain GCC 12.2.1 / GDB 12.2I need the C++20 standard. The project compiles without issues.
But with C++20 the Intellisense don’t work.
In Error List window following ist shown:Severity Code Description Project File Line Suppression State
Error [Clang IntelliSense] Error: invalid value ‘gnu++20’ in ‘-std=gnu++20’ 1After setting back to C++17, the Intellisense is working.
How can I solve the issue?
Best regards,
Timo</p>
August 13, 2023 at 21:04 #34580supportKeymasterHi,
Sorry for the delay with updating IntelliSense. In the past year we have been working on a new software tracing engine that allows recording the values of various variables at arbitrary moments without disrupting the program. It allows easily debugging issues that would otherwise be impossible to reproduce under debugger, or that would require excessive amount of stepping and note-taking. So, we prioritized it over the IntelliSense engine update.
We have recently released VisualGDB 6.0 Beta 1 introducing the tracing engine, and are working on another update to it.
IntelliSense update is the next thing on our plan and we expect to release another Beta using the latest Clang in September.
As a workaround until then, please consider adding “-std=c++17” to VisualGDB Project Properties -> IntelliSense Settings -> Additional flags for C++ files. It will allow IntelliSense to recognize C++17 features even if the underlying build system reports that it’s using C++20.
August 14, 2023 at 00:07 #34581Timo EngelmannParticipantThanks for the response. I will try the workaround.
-
AuthorPosts
- You must be logged in to reply to this topic.