QtCreator's extebded complex type syntax highlighting is messy
-
Hi All!
may be it would be a good idea to fix complex type highlighting in C environment?
If I try to declare non-default 'float complex' type, QtCreator immediately starts taking followed variable name as an extra symbol, claiming its as 'unexpected token' and blooding the code with its perfectly shaped katana-blade ;)
It does consider simple 'complex' declaration as accepted one (line 133) though...'float complex' is a valid declaration, and it is really wanted when coding for embedded ARM processors as soon as default double type takes huge time to compute.
Stan
-
Hi,
There's nothing anyone on these forums can do officially. You would have much better luck submitting a bug or feature request. This is a user based forum none of the Qt devs usually hang out here.
-
If you enable the Clang Code Model (Help -> About Plugins) the highlighting works fine and no syntax error is shown. There won't be anymore fixes to the builtin code model, so you don't need to file a bugreport.
PS: you have a type in the thread title, please fix it so it can be found again later.
-
As Clang is a compiler, it is also pendantic ;)
As it seems you are cross-compiling, Clang has problems to find or to understand diverse header files. You will have to make sure the headers are properly parsed, e.g. by injecting some DEFINES into the code model. How to do that depends on your project - I've done it a lot for the Generic Projects to overcome problems like yours.
However, if your include files uses language extensions, that may not be enough.
-
@aha_1980 I use arm-none-eabi-49... as a compiler's part and Qbs as build engine. Of course, I can feed a lot of defines withing qbs's project file, but it will not help to beautify editor's frame. So, I'm afraid, Clang's code model (at least with Qbs on-board) can't fix.