refactor: remove boost.spirit graphviz parser#533
Open
Becheler wants to merge 1 commit into
Open
Conversation
|
Compiler-warning counts vs
|
Becheler
marked this pull request as ready for review
July 17, 2026 11:05
|
Boost dependency footprint vs Header-inclusion weights (graph files pulling each direct dependency in):
Transitive Boost modules: 69 → 69 (0) |
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.
Before submitting
developbranch.Type of change
Does this PR introduce a breaking change?
What this PR does
graphviz.hpp: removed both Boost.Spirit code paths in the tworead_graphvizoverloads (they now always callread_graphviz_new)classic_multi_passSpirit include.BOOST_GRAPH_USE_SPIRIT_PARSERstill recognized, but now emits aBOOST_PRAGMA_MESSAGEdeprecation notice and redirects to the default parser instead of selecting Spirit.detail/read_graphviz_spirit.hpp(the Spirit DOT reader that pulled in 10boost/spiritheaders).test/isomorphism.cpp: removed the incidental#define BOOST_GRAPH_USE_SPIRIT_PARSERbuild.jamandCMakeLists.txtdropped thespiritdependency.Motivation
The spirit-based graphviz parser has been non default, undocumented and untested for 16 years.
The Boost.Spirit library has 28 direct boost dependencies, and 54 indirect, effectively dragging most of Boost in BGL: https://alandefreitas.github.io/boostdep_graph/libs/spirit.html
This PR removes its implementation, effectively dropping spirit dependency and its direct+transitive chain.
The default parser uses Boost.Regex, that has a much better dependency chain: https://alandefreitas.github.io/boostdep_graph/libs/regex.html
Note: spirit is not effectively removed from the transitive dependencies chain, as Boost.Serialization pulls it in.
A next PR will drop Boost.Serialization for Boost.Core.Serialization.
Testing
Checklist
b2in thetest/directory).