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

Fix for C++23 standard library module usage. #326

Merged
merged 3 commits into from
Feb 7, 2024
Merged

Fix for C++23 standard library module usage. #326

merged 3 commits into from
Feb 7, 2024

Conversation

stripe2933
Copy link
Contributor

Currently argparse cannot be built using ARGPARSE_MODULE_ENABLE_STD_MODULE macro, because there are two problems.

  • In argparse.hpp, the header <cerrno> should be outside the macro if statement because errno macro variable cannot be exported via C++ module.
  • In argparse.cppm, to use <cstdlib> features, std.compat module should also be imported.

This PR's commits include these fixes.

<errno> header exposes errno macro, which cannot be exported in C++ module. It must always included regardless of module usage.
To use <cstdlib> feature, std.compat module should be imported.
@p-ranav p-ranav merged commit 1b3abd9 into p-ranav:master Feb 7, 2024
8 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.

None yet

2 participants