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

[easylog]if statement can be constexpr #494

Merged
merged 1 commit into from
Nov 14, 2023
Merged

[easylog]if statement can be constexpr #494

merged 1 commit into from
Nov 14, 2023

Conversation

scuzqy
Copy link
Contributor

@scuzqy scuzqy commented Nov 14, 2023

Why

if statement within macro ELOGV_IMPL. ELOGFMT_IMPL0 can be evaluated during compile-time.

I'm not 100% sure this change is proper, but it seems to me that severity should be compile-time constant as long as Id is used as one.

What is changing

Macro definition ELOGV_IMPL. ELOGFMT_IMPL0, easylog.hpp

@qicosmos
Copy link
Collaborator

qicosmos commented Nov 14, 2023

can be if-constexpr here.

@qicosmos qicosmos self-requested a review November 14, 2023 05:48
Copy link
Collaborator

@qicosmos qicosmos left a comment

Choose a reason for hiding this comment

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

LGTM

@qicosmos qicosmos merged commit 4d5da04 into alibaba:main Nov 14, 2023
30 checks passed
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