Skip to content

Conversation

riidefi
Copy link
Contributor

@riidefi riidefi commented Feb 11, 2023

This fix was necessary for my project (C++ depending on Rust) to compile. The approach here is conservative, only deferring from the existing behavior when the compiler explicitly does not support exceptions via feature-test macros. There may be other approaches here, like attempting to compile a test file with throw.

@riidefi riidefi changed the title C++: Automatically use RUST_CXX_NO_EXCEPTIONS panic backend if exceptions are unsupported. C++: Fix build on no-except compilers Mar 10, 2023
@dtolnay dtolnay linked an issue Aug 8, 2025 that may be closed by this pull request
Copy link
Owner

@dtolnay dtolnay left a comment

Choose a reason for hiding this comment

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

Thanks!

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.

Disable exceptions without setting additional env flags
2 participants