after CLion target for library code completion was implemented, there is still a bug in the code-completion for any code in the “lib” folder. Inside these code files, CLion is not able to resolve include files, neither for the Arduino environment or the C standard library (like
string.h). It does recommend to include non-found functions from a very long relative path though.
It looks like this:
To reproduce, do a test project and add some library. For example:
mkdir piotest && cd piotest pio init -b uno --ide=clion wget http://playground.arduino.cc/uploads/Code/DateTime.zip && unzip DateTime.zip -d lib/ #press "n" to *not* overwrite touch src/main.cpp pio init --ide=clion
Then open the
piotest program in CLion.
I’m using the latest platformio development version
PlatformIO, version 3.5.1a6 and CLion 2017.3.