Skip to content

Conversation

@cednik
Copy link
Collaborator

@cednik cednik commented Aug 7, 2025

Issue #54 is marked as closed, but warnings, mentioned in the original post, are still coming when compiling with MSVC.
This should solve it.

Copy link
Owner

@tbenthompson tbenthompson left a comment

Choose a reason for hiding this comment

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

thanks! this is great!

left one comment for an improvement but i hit approve since i don't think it's blocking.

cfg["compiler_args"] = ["-std=c++11", "-fvisibility=hidden"] + cfg["compiler_args"]
prefix_args = ["-std=c++11", "-fvisibility=hidden"]
# MSVC compiler do not support "-std=c++11" nor "-fvisibility=hidden"
if os.name == "nt":
Copy link
Owner

Choose a reason for hiding this comment

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

this feels a little awkward. what's the motivation for building the list and then remove entries versus just pushing the list inside the conditional?

if os.name == 'nt' and ...
    prefix_args = []
else:
    prefix_args = ["-std=c++11", "-fvisibility=hidden"]

@tbenthompson
Copy link
Owner

i also just added you as a maintainer on cppimport. =)

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.

3 participants