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 preprocessor exclusions when INI_ALLOW_MULTILINE=0 #178

Merged

Conversation

isidroas
Copy link
Contributor

Exclude the prev_name variable and the ini_strncpy0() call.

This decreases the program size, the execution time and the stack usage when that flag is off.

But that's barely noticeable. It's more useful for progressive understanding.
When I first came across with this code, I removed (or collapsed) all the ifdef blocks to learn the simpler version first.

Exclude the `prev_name` variable and the ini_strncpy0() call
Copy link
Owner

@benhoyt benhoyt left a comment

Choose a reason for hiding this comment

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

I don't love how many #ifs there are now, but on balance, I'm okay with this change. Thanks!

@benhoyt benhoyt merged commit ee1fdd2 into benhoyt:master Oct 24, 2024
2 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