[vlc-devel] [RFC 3/3] vlc_arrays: append items in amortized O(1)
filip at atch.se
Fri Jul 20 11:39:07 CEST 2018
On 2018-07-20 11:36, Filip Roséen wrote:
> > I could, but I didn't do it because their failure would be triggered by
> > the following asserts anyway (e.g. if append() fails, count() will be
> > incorrect). And it would just add explicit assertions about
> > out-of-memory.
> We have other tests using `asserts` in some places, and tests that
> even `assert` that memory-allocation succeeds. The reason is precisely
> as you pointed out: if *append* fails, *count* will be flagged as the
Supposed to be *"in such cases"*, not *"some"*.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the vlc-devel