[v8.x] backport some assert commits
Using assert became much more friendly recently. As long as we still have the chance to get some commits into 8 I thought I go ahead and open a backport for these.
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
tests and/or benchmarks are included -
documentation is changed or added -
commit message follows commit guidelines