These are chat archives for esp8266/Arduino

13th
Nov 2018
Holger Lembke
@holgerlembke
Nov 13 2018 20:10
moin moin
Arduino 1.8.7 ide sometimes stops compiling and throws some errors. switching back to 1.8.5 and everything is fine. any ideas? did someone report that?
Develo
@devyte
Nov 13 2018 20:38
what errors?
Holger Lembke
@holgerlembke
Nov 13 2018 20:44
does not help very much: " 'File' was not declared in this scope".
it appears after adding an empty function, removing the function makes the error go away. the function itself is something totally simple, void/void, empty.
Develo
@devyte
Nov 13 2018 20:58
That sounds like the arduino preprocessor tool (or whatever it's called) getting dizzy. The tool scans your code and generates function prototypes automatically. In C/C++, a function must be defined first before use. Alternatively, it must be declared before use, and defined later. Arduino has a tool that scans your code and adds prior declarations of your functions as needed. That is what allows you to define a function at the end of a sketch e.g.: below loop(), without having declared it. However, I've seen several weird bugs.
artua
@artua
Nov 13 2018 21:49
I saw the same with extensive use of PROGMEM. Reported thru arduino-beta. https://github.com/arduino/Arduino/issues/7666#event-1944365619
@holgerlembke if you have MCVE please report it to Arduino guys.
Develo
@devyte
Nov 13 2018 21:56
what @artua said. However, reproduce the issue building against some Arduino board, e.g.: Due. That will make it more likely they'll take a look. If you go to them with an ESP build, they'll likely refer you back here.
Just a build and the build error should be enough.
Holger Lembke
@holgerlembke
Nov 13 2018 22:02
@artua looks like my problem…. thanks for the feedback.
Holger Lembke
@holgerlembke
Nov 13 2018 22:08
in my understanding (until now) the builder only creates the forward declarations, glues the tabs to one .c file and creates the build environment. if I look into the .c file it looks fine, all the forwards and #includes are there… so what point of the builders work do I miss?
Holger Lembke
@holgerlembke
Nov 13 2018 22:47
just to add some more confusion: the function is named "void setupSSDP(void)" and never ever used anywhere in my sketch. the simple existance of this function kills the compile. If I change the name to "void setuPSSDP(void)" it compiles fine.
Develo
@devyte
Nov 13 2018 23:24
Yup, that sounds like that tool. Again, I strongly suggest reproducing the issue with a different target like an arduino due, then opening an issue against arduino folks