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

embind: Ensure embind works under c++11. #21100

Merged
merged 1 commit into from
Jan 22, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions test/test_other.py
Original file line number Diff line number Diff line change
Expand Up @@ -2971,9 +2971,10 @@ def test_embind_closure_no_dynamic_execution(self):
'wasm64': ['-sMEMORY64', '-Wno-experimental'],
})
@parameterized({
# With no arguments we are effectively testing c++17 since it is the default.
'': [],
# Ensure embind compiles under C++17 where "noexcept" became part of the function signature.
'cxx17': ['-std=c++17'],
# Ensure embind compiles under C++11 which is the miniumum supported version.
'cxx11': ['-std=c++11'],
Copy link
Collaborator

Choose a reason for hiding this comment

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

Should we run this in c++17 and c++20 too?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

17 is currently the default. 20 would be good but it currently fails. I've filed llvm/llvm-project#78614 to look into it.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Perhaps mention this in comments? i.e. # With no arguments we are effectively testing c++17 since it is the default

'o1': ['-O1'],
'o2': ['-O2'],
'o2_mem_growth': ['-O2', '-sALLOW_MEMORY_GROWTH', test_file('embind/isMemoryGrowthEnabled=true.cpp')],
Expand Down