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

reduced unnecessary usage of emptyString #7229

Merged
merged 5 commits into from
Jan 22, 2025

Conversation

firewave
Copy link
Collaborator

No description provided.

@firewave
Copy link
Collaborator Author

emptyString is used for const std::string& return values and as an optimization in some cases. But those are insolated cases.

The goal is to remove it from config.h because that file should only contain "configuration" related stuff.

Also the <string> makes this one of the heavier headers.

Even worse though is the fact that the include affects the preprocessor checks. We are (were?) checking non-compiler/built-in defines which were transiently included leading to portability issues.

@firewave firewave changed the title removed unnecessary usage of emptyString reduced unnecessary usage of emptyString Jan 16, 2025
@firewave
Copy link
Collaborator Author

Even worse though is the fact that the include affects the preprocessor checks. We are (were?) checking non-compiler/built-in defines which were transiently included leading to portability issues.

I think this also implies that config.h always needs to be the very first include. Something for later ... as usual.

@firewave firewave marked this pull request as draft January 16, 2025 15:01
@firewave firewave marked this pull request as ready for review January 16, 2025 15:12
@firewave firewave marked this pull request as draft January 18, 2025 11:54
@firewave firewave marked this pull request as ready for review January 18, 2025 12:00
@chrchr-github chrchr-github merged commit 06e7663 into danmar:main Jan 22, 2025
60 checks passed
@firewave firewave deleted the emptystring branch January 22, 2025 12:55
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