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

Added a warning about incorrect flags being used #1425

Open
wants to merge 1 commit into
base: development
Choose a base branch
from
Open

Added a warning about incorrect flags being used #1425

wants to merge 1 commit into from

Conversation

Avamander
Copy link
Contributor

Made the preprocessor throw an error if an ancient define is specified, user must update their defines to avoid very difficult to diagnose issues further on.

I personally stumbled upon it. I hope this PR avoids the headache for someone else.

Made the preprocessor throw an error if an ancient define is specified, user must update their defines to avoid very difficult to diagnose issues further on.
@Avamander Avamander changed the base branch from master to development May 31, 2020 01:09
@mfalkvidd
Copy link
Member

mfalkvidd commented May 31, 2020

I did some digging and the names were changed in the release of 2.0.0 (1.5.4 which was the last 1.x release had the old variants without MY_)

The commit was f8ee376

In the same commit, these were also updated so maybe these should have deprecation warnings as well:

RF24_CHANNEL -> MY_RF24_CHANNEL
RF24_BASE_RADIO_ID -> MY_RF24_BASE_RADIO_ID
RF24_CE_PIN -> MY_RF24_CE_PIN
RF24_CS_PIN -> MY_RF24_CS_PIN
RF24_PA_LEVEL -> MY_RF24_PA_LEVEL
RF24_PA_LEVEL_GW -> not used
IP_ADDRESS_DHCP -> MY_IP_ADDRESS_VIA_DHCP

I checked keywords.txt and none of the old defines have highlighting rules.

@Avamander
Copy link
Contributor Author

Yeah, probably would be a good idea. It probably wouldn't be a bad idea to just have a section in MyConfig.h that's for all the deprecated flags that throw errors.

@mfalkvidd
Copy link
Member

There is a list at https://www.mysensors.org/apidocs/deprecated.html but that page only lists stuff that have ben annotated as deprecated.

@Avamander
Copy link
Contributor Author

I more meant like that the file itself could have a separate section, so they aren't all mixed up with the rest, valid defined. I think that should be some other PR that does that though.

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

Successfully merging this pull request may close these issues.

None yet

2 participants