Eclipse C/C++ Shows Errors but Compiles?

前端 未结 9 1229
我寻月下人不归
我寻月下人不归 2020-12-15 17:27

So I am building some Arduino code in eclipse, as described in Your Second Arduino Project, but every time I use an Arduino library, such as Serial, Eclipse und

相关标签:
9条回答
  • 2020-12-15 18:02

    In my case the problem was due to adding "-std=c++17" flag in the language standard field in the project properties under the compile dialect. After that the build was passing with errors, but the program was running fine. So the trick of Index>Rebuild resolved everything.

    0 讨论(0)
  • 2020-12-15 18:03

    When resolving symbols, CDT indexer seems to consider all header files irrespectively of which ones are actually included in the compilation unit. There is a corresponding bug report filed with Eclipse Bugzilla: https://bugs.eclipse.org/bugs/show_bug.cgi?id=439553

    0 讨论(0)
  • 2020-12-15 18:11

    If you changed something in the configurations, (example, editing in *.cproject file with notepad++) , the below options helps. Build Configurations --> Clean All and then Index --> Rebuild

    0 讨论(0)
提交回复
热议问题