[–] Panzerschrek 3mo ago ↗ > if (const auto& [is_successful, error_message] = foo(n))I don't like it. It's hard to reason what exactly serves as condition variable. [–] porise 3mo ago ↗ Yeah I wouldn't like this in a code review. Add one more line of code so I don't have to investigate foo().That's my fundamental gripe with C++int i = 0;function_0(i,...);...function_9(i,...);which one changes i? It's not obvious in a code review due to default mutable references.
[–] porise 3mo ago ↗ Yeah I wouldn't like this in a code review. Add one more line of code so I don't have to investigate foo().That's my fundamental gripe with C++int i = 0;function_0(i,...);...function_9(i,...);which one changes i? It's not obvious in a code review due to default mutable references.
2 comments
[ 3.6 ms ] story [ 15.9 ms ] threadI don't like it. It's hard to reason what exactly serves as condition variable.
That's my fundamental gripe with C++
int i = 0;
function_0(i,...);
...
function_9(i,...);
which one changes i? It's not obvious in a code review due to default mutable references.