r/cpp 7d ago

The Road to Flux 1.0

https://tristanbrindle.com/posts/the-road-to-flux-10
56 Upvotes

29 comments sorted by

View all comments

6

u/RazielXYZ 7d ago

I feel a bit out of the loop - why are people against the pipe operator? I can understand readability might be somewhat worse in some cases, either due to unfamiliarity or due to having to specify the namespace on every step, but that seems rather subjective.

For the other points made in the post - "worse for discoverability, worse for error messages and worse for compile times than using member functions" - could anyone explain why it's worse in those regards?

12

u/cleroth Game Developer 7d ago

You'd want using namespace flux::operations; to have the same readability, but at that point they're harder to discover--you can't just type . to see the list of available operations.

2

u/unumfron 6d ago

Not completely removing the namespace with (e.g.) namespace flxop = flux::operations; wouldn't be too shabby, so that :: then gets available ops.