-
-
Notifications
You must be signed in to change notification settings - Fork 114
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
preprocessor fails on #include "ESP8266wifi.h" (for external ESP8266 addon) #68
Comments
The #include <memory> Including this library in the sketch seems to be enough to trigger the issue. Edit: actually we don't even need a library to trigger this. Compiling this sketch leads to the same error: #include <memory>
void setup() {
test();
}
void loop() {}
void test() {} Edit 2: here's the output of arduino-builder with --debug=10: http://hastebin.com/matajofoti.md Edit 3: interestingly, the list of prototypes is generated correctly by ctags:
But the .ino.cpp file generated in the next step doesn't contain #include <Arduino.h>
#line 1
#line 1 "/var/folders/15/ybtbgzpj7636vv4wp92l2c700000gn/T/arduino_ad5feee0973bd3788deb217687c83661/sketch_nov21a.ino"
#include <memory>
void setup() {
test();
}
void loop() {}
void test() {} |
I pulled the latest git version of Arduino and rebuilt it. Also renamed Here's arduino-builder output: http://hastebin.com/mupuhalehe.cs I had a thought that ctags gets confused by some of the c++11 constructs. Tried universal-ctags, and output looks much better (i.e. |
Haven't got a solution but I can reproduce all of the errors down to the rebuild reliably, and it definitely seems to be what caused #4137. |
At a first look, it looks like ctags is interrupting. It's not getting beyond that |
For the record, here's what i get from universal-ctags: https://gist.github.com/igrr/b82b708af81e7baa02fc |
Indeed, even universal-ctags misses |
I'm now using this
When running ctags with |
Same does universal-ctags |
#88 also ran into a problem with ESP8266wifi.h. I dug into that, without being aware of this issue and found that static_assert was the culprit. I wrote:
Looking through the comments here, I'm not sure if this is exactly the same issue, though that might be caused by changes in the ESP core since this issue was created. I haven't tried universal-ctags to see what that gives. |
Oh wow, thanks for info Matthijs. I was going through the logs multiple times but missed this |
@igrr, yeah I think in my testing, the offending |
@matthijskooijman here you go: arduino/ctags#4 |
see #68 Signed-off-by: Cristian Maglie <c.maglie@arduino.cc>
@igrr captive advance portal example exit status 1 |
If the problem is related to this issue you can work around it by providing your own function prototypes as you would typically do in a C application. You just need to define the functions at the top of your .ino for example, or potentially in a separate header file. |
@matthijskooijman Looks like we have another issue due to use of |
I have cherry-picked two more changes from geany. This fixes an issue with DNSServer library: |
How does one generate the useful debugging output for this bug? This issue is closed, but it seems like including the FastLED library is still causing issues:
Fails with: error: 'myctagstestfunc' was not declared in this scope On the 1.6.8 hourly build 2016/02/22 10:12 (downloaded just now) According to FastLED/FastLED#258, this is still an arduino-builder issue, is that the case? Should this be reopened? |
@julianh2o I just opened up #120 for the specific issue you're seeing there (since I think this is being caused by slightly different things that were causing the problems here). |
Pull request for a fix to #120 opened here - arduino/ctags#7 |
Folks, I tried hourly build 2016/03/04 and still seeing the error. Isnt the original error "memory" fixed? In file included from C:\Users\vmanan\Documents\Arduino\libraries\src/ESP8266WiFi.h:32:0, |
This still happens with 1.6.8. What was/is the resolution? |
@joeuser846 , it is fixed in 1.6.8+ (just tested with the initial sketch and ESP core 2.1.0) |
I'm still seeing issues with 1.6.8 |
@netmindz Possibly you are seeing #1898, caused by arduino/ctags#10. |
Had to flip whole structure upside down because this piece of ****: arduino/arduino-builder#68 arduino/arduino-builder#80 arduino/arduino-builder#85 and countless other issue tickets, arduino builder preprocessor fails to do prototype and can't reorder functions so everything must be just in the right order (and also breaks many libraries and other third party boards). Code may not compile properly as long as arduino developpers can't get their **** together. Wifi part won't work until underlying issue in arduino-builder gets fixed or old version of arduino ide is used or something is gludged to overcome these issues.
I confirm I'm still seeing issues with 1.6.8 and ESP8266Wifi. |
@stephanemorin please provide the sketch which causes issues. Thanks. |
Hi igrr, The following files from the ESPWifi library examples are all causing the same problem: The error message is:
|
Signed-off-by: Cristian Maglie <c.maglie@arduino.cc>
I am seeing a similar issue with 1.6.9 and ESP8266WiFiMulti.h. |
there's something about this header file that crashes the preprocessor, probably indicates some more general purpose bug. reproduce by:
http://arduino.esp8266.com/stable/package_esp8266com_index.json
to board manager prefs#include "ESP8266WiFi.h"
on last line, recompileAlso mentioned @ esp8266/Arduino#1066
The text was updated successfully, but these errors were encountered: