Skip to content

Fix named parameter overload of boykov_kolmogorov_max_flow#304

Merged
jeremy-murphy merged 3 commits intoboostorg:developfrom
sebrockm:fix-max-flows
Jul 25, 2022
Merged

Fix named parameter overload of boykov_kolmogorov_max_flow#304
jeremy-murphy merged 3 commits intoboostorg:developfrom
sebrockm:fix-max-flows

Conversation

@sebrockm
Copy link
Copy Markdown
Contributor

Fixes #232

@jeremy-murphy
Copy link
Copy Markdown
Collaborator

So I take it that test of the bundled properties failed until you fixed the return type of the named parameter overload?
I just want to understand exactly what the change fixes. And why does it need to use put instead of operator[] now?

@jeremy-murphy jeremy-murphy merged commit 2862644 into boostorg:develop Jul 25, 2022
@jeremy-murphy
Copy link
Copy Markdown
Collaborator

And... thank you!

@sebrockm sebrockm deleted the fix-max-flows branch July 25, 2022 07:44
@sebrockm
Copy link
Copy Markdown
Contributor Author

@jeremy-murphy Yes, the return type was the only error. It always expected the value type of the interior capacity property map, never the one provided via named parameters. (I sometimes hear people saying that they don't like auto as return type. From now on I will point them to this error 😅 )
put instead of operator[] was honestly just a leftover from some early trials of investigation of this error. At some point I had a test that used a property map that didn't have operator[] and compilation failed. The test itself turned out to be non-constructive for identifying this issue, so I removed it. But I kept the put because I think writable property maps are not required to support operator[], only put.

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.

Boost max flow algorithms do not compile

2 participants