[Development] Question about QCoreApplicationData::*_libpaths

Matthew Woehlke mwoehlke.floss at gmail.com
Thu Jan 21 18:01:06 CET 2016

On 2016-01-20 17:43, Giuseppe D'Angelo wrote:
> This poses further questions down the line, such as whether it's "ok"
> having an index API based on signed integers. (It is for convenience, it
> is not for correctness, but I guess that's all the topic here, isn't it?
> :))

As Thiago noted, C++ itself is moving *away* from size_t, even to using
int in some cases.

It's true, it would be nice if Qt (especially e.g. QByteArray) used
ssize_t instead of int, but there are various strong reasons for using a
signed integer rather than unsigned. (It makes 'did you find the index'
checks much less obnoxious, it allows tail-based indexing, ...)

> Qt containers are unsound for general-purpose storage.

...only if you use exceptions. Personally, I'm glad Qt *doesn't*.


More information about the Development mailing list