Skip to content

Conversation

@sdebionne
Copy link
Contributor

Description

Switch Point concept from Boost.ConceptCheck to C++20 concepts.

References

Discussed on boost-gil cpplang

Tasklist

  • Adapt test case(s)
  • Ensure all CI builds pass
  • Review and approve

@sdebionne sdebionne self-assigned this Jan 23, 2026
@sdebionne sdebionne added the cat/refactoring Any nonfunctional changes label Jan 23, 2026
@sdebionne sdebionne requested a review from mloskot January 23, 2026 11:47
@sdebionne
Copy link
Contributor Author

I am not sure what to do with the CI. Obviously all builds with cxxstd < 20 will fail.

///
template <typename P>
struct PointNDConcept
concept PointNDConcept = requires(P point, typename P::template axis<0>::coord_t ft, typename P::template axis<P::num_dimensions - 1>::coord_t lt)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

concept should be lower case?

}
P point;
typename P::value_type;
requires std::regular<typename P::value_type>;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Better write with concept conjunctions?

concept PointNDConcept = std::regular<typename P::value_type> && requires(P point, typename...

@mloskot
Copy link
Member

mloskot commented Jan 23, 2026

Obviously all builds with cxxstd < 20 will fail.

Well, any build other than c++20 will fail, no?

Since GIL cannot afford the luxury of https://github.com/boostorg/cobalt, I don't know any tricks other than the old-school
https://github.com/boostorg/url/blob/f4a80080b1012a0f0a7fb6cd472ff662fa8daefe/include/boost/url/grammar/charset.hpp#L69

@sdebionne
Copy link
Contributor Author

Right, another option would be GIL v2.

@mloskot
Copy link
Member

mloskot commented Jan 24, 2026

If we would be allowed to consider GIL up to Boost 1.90 as last GIL that supports mixture of older and newer compilers, and any GIL released after Boost 1.90 require >= C++20, that would be great! It would be an opportunity for more thorough refactoring and better experience for implementing new features.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cat/refactoring Any nonfunctional changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants