Skip to content

Update to fix defines that collide with other commonly used defines. #10

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

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

Conversation

suicvne
Copy link

@suicvne suicvne commented Aug 7, 2022

Recently I experienced the #define's for log levels very badly conflicted with a library I was trying to port. Essentially, by defining them as such, it broke macros that had the words DEBUG or ERROR or INFO on them.

The fix is to re-define the log levels with the library as a prefix.

#define NONE 0
#define INFO 1
#define ERROR 2
#define DEBUG 3	

becomes

#define DBGNET_NONE 0
#define DBGNET_INFO 1
#define DBGNET_ERROR 2
#define DBGNET_DEBUG 3

This is important, the errors that are generated by these macros conflicting are vague and non-descript. Not to mention this library is bundled with VITASDK!

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.

1 participant