[Tim] >> Given that, the assert() in question looks fine to me: >> ... |>> Either that, or the original author (and me, just above) made an error >> in analyzing what must be true at this point. | [David Hopwood] > You omitted to state an assumption that sizeof(errTxt) >= 4, since size_t > (and the constant 4) are unsigned. Also bytes_left must initially be nonnegative > so that the subexpression 'sizeof(errTxt) - bytes_left' cannot overflow. I don't care, but that's really the /point/: asserts are valuable precisely because any inference that's not utterly obvious at first glance at best stands a good chance of relying on hidden assumptions. assert() makes key assumptions and key inferences visible, and verifies them in a debug build of Python.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4