Open yseymour opened 4 years ago
I've reported a bug against our parser shared with VS at https://developercommunity.visualstudio.com/content/problem/1168897/incorrect-c-intellisense-error-in-gcc-mode-auto-ty.html .
A potential workaround is to add these lines somewhere in the TU:
#ifdef __INTELLISENSE__
#pragma diag_suppress 2717
#pragma diag_suppress 144
#endif
Type: LanguageService
Describe the bug
Steps to reproduce
test.c
Gives the error:
'__auto_type' must be a placeholder for the complete type of the variable (not for a component of that type)
. Removingconst
resolves the error.gcc and clang both compile the code without error.
I had difficulty working out whether this error is being produced by the extension, or some other tool. Googling the message did not uncover anything. Hopefully someone can work it out.
My
c_cpp_properties.json
looks like: