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

Add wrapper to throw compiler warning for deprecated funcs #122

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

jhiemstrawisc
Copy link
Contributor

In order to keep the scitokens.h header backwards compatible with older versions of C/C++ while still providing support for compiler warnings when a deprecated function is used, I set up a macro wrapper that checks for compiler support of the attribute and throws a warning when a deprecated function is used.

I was aiming for broad compiler compatibility. Let me know if there's anything I can change.

In order to keep the `scitokens.h` header backwards compatible with older versions of C/C++ while
still providing support for compiler warnings when a deprecated function is used, I set up a macro
wrapper that checks for compiler support of the attribute and throws a warning when a deprecated
function is used.
src/scitokens.h Outdated Show resolved Hide resolved
src/scitokens.h Outdated Show resolved Hide resolved
src/scitokens.h Outdated Show resolved Hide resolved
src/scitokens.h Outdated Show resolved Hide resolved
src/scitokens.h Outdated Show resolved Hide resolved
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Copy link
Contributor

@djw8605 djw8605 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting, did you find this code somewhere?

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.

2 participants