Skip to content
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

Anomole #68

Open
SteveRMann opened this issue Jul 2, 2019 · 0 comments
Open

Anomole #68

SteveRMann opened this issue Jul 2, 2019 · 0 comments

Comments

@SteveRMann
Copy link

SteveRMann commented Jul 2, 2019

This is not an issue more than a curiosity.

I use these two lines at the start of many of my Arduino and ESP sketches to turn Serial.print on or off with one #define statement.:

#define DEBUG true  //set to true for debug output, false for no debug output
#define Serial if(DEBUG)Serial

It works. Except when I add #include <ESP8266WiFi.h>. I then get a compile error:

expected primary-expression before 'if'
It's not a show-stopper because the "feature" is simply a convenience, but examining the cpp code in the library is a bit above my skill level. I am simply curious what is in the ESP8266WiFi.h that would prevent me using the debug lines?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant