Repository navigation
Conversation
On Linux, Boost.Asio's serial port support includes <termios.h>, which defines B0, B1, ... as baud-rate macros. With ENABLE_BOOST=ON the BinarySolver and RingLpn tests failed to compile. Rename the locals to Bsh0/Bsh1. Fixes #186 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #186.
On Linux, Boost.Asio's serial port support includes
<termios.h>, which defines the baud ratesB0,B1, ... as macros. WithENABLE_BOOST=ON, local variables with those names inBinarySolver_Tests.cppandRingLpn_Tests.cppstoppedlibOTe_Testsfrom compiling. This renames them toBsh0/Bsh1. Nothing else in the tree uses those names as identifiers.Validation
GCC on Linux, with
<termios.h>force-included into every file (-DCMAKE_CXX_FLAGS=--include=termios.h). This is the same header Boost.Asio pulls in, so it reproduces the bug without building Boost. The build usedENABLE_ALL_OT, both DPF options andENABLE_RINGLPN.-u RingLpnpasses (9 tests). This also shows that no other identifier in the tree collides with a termios macro.RingLpn_Tests.cpp, the build fails at the oldB0line with the error reported in the issue.CI still doesn't build with Boost on Linux, so it can't catch a recurrence. Adding the flag above to a Linux job would.
🤖 Generated with Claude Code