Closed sewbacca closed 2 years ago
Thanks for reporting this. I've filed internal bug 1535519 against our IntelliSense parser shared with VS.
It turns out this is "by design" for performance reasons and the suggested workaround is to use
const char str[] = {
#include "str.txt"
};
Bug type: Language Service
When using
#include "..."
the language server doesn't take them literally and shows a syntax error, where none is.Describe the bug
Steps to reproduce Where I found the error:
src/modules/graphics/wrap_Graphics.cpp
:45
Simpler case:
main.cpp
str.txt
Notice: The error vanishes, if
const char str[] = ...
is moved intomain
.Expected behavior No syntax error.
Screenshots