Non standard return fails to compile
Open
- Dominant language
- C++
- Stars
- 24
- Forks
- 55
- PR merge metrics
- No merged PRs in 30d
Description
This statement:
return BOOST_ASSERT_MSG( i < N, "out of range" ), elems[i];
is a non-standard form of return.
In case we compile optimized code that lacks assert function but still want something this code fails to compile.
Separating this to a more standard form solves the issue:
BOOST_ASSERT_MSG( i < N, "out of range" );
return elems[i];
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.