[Development] RFC: Proposal for a semi-radical change in Qt APIs taking strings
Marc Mutz
marc.mutz at kdab.com
Tue Oct 20 13:01:02 CEST 2015
On Tuesday 20 October 2015 11:08:51 Иван Комиссаров wrote:
> Btw, isn't the QStringView is the same as Range<Container>
> { Container::Iterator begin; Container::Iterator end; } ?
No. A string_view (or QStringView) is targeted at string operations. A range
is just a pair of iterators.
> Why we introduce only QStringView/QByteArrayView? Maybe we should think
> about adding range API to all containers?
We want to use the std functionalities in this area (ranges and array_view),
because the API differences are small, and this is not a core skill of Qt as a
library. Unicode string handling is. Our containers are all much weaker than
the std ones, from QVector over QPair to QSharedPointer, and that should give
you the hint that we don't have the manpower (nor should be have the desire)
to compete with the std on these matters.
Thanks,
Marc
--
Marc Mutz <marc.mutz at kdab.com> | Senior Software Engineer
KDAB (Deutschland) GmbH & Co.KG, a KDAB Group Company
Tel: +49-30-521325470
KDAB - The Qt Experts
More information about the Development
mailing list