Skip to content

Clean up graph.hpp and graph.cpp#564

Merged
arcondello merged 5 commits into
dwavesystems:mainfrom
arcondello:feature/refactor-cpp-graphs
Jun 18, 2026
Merged

Clean up graph.hpp and graph.cpp#564
arcondello merged 5 commits into
dwavesystems:mainfrom
arcondello:feature/refactor-cpp-graphs

Conversation

@arcondello

Copy link
Copy Markdown
Member

Mostly non-functional changes: alphabetization, trailing underscores, logical operators, etc. The one real change is renaming the protected Graph methods.

I did let two other unrelated formatting changes sneak in 😳

See also #398, #399, #562

AI Generation Disclosure

No AI used.

@arcondello arcondello requested a review from wbernoudy June 17, 2026 19:01
@arcondello arcondello added the enhancement New feature or request label Jun 17, 2026
@arcondello arcondello marked this pull request as ready for review June 17, 2026 19:06
Comment thread dwave/optimization/include/dwave-optimization/graph.hpp Outdated
void Graph::topological_sort() {
if (topologically_sorted_) return;

// The decisions already have their topological index assigned

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think this got moved from two lines up?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

that's how it is in the original

// The decisions already have their topological index assigned

I am inclined to say it's weird but out of scope for this PR.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Fair

Co-authored-by: William Bernoudy <william@bernoudy.xyz>
@arcondello arcondello merged commit 4b15297 into dwavesystems:main Jun 18, 2026
14 checks passed
@arcondello arcondello deleted the feature/refactor-cpp-graphs branch June 18, 2026 22:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants