We could let return .size() size_t and .ssize() ssize_t. So you can choose. 
std::span is going in that direction and I find it very pragmatical.

________________________________
From: Development <[email protected]> on behalf of 
Thiago Macieira <[email protected]>
Sent: Wednesday, December 5, 2018 5:20:07 PM
To: [email protected]
Subject: Re: [Development] Another integer typedef OR how to prepare for 64-bit 
in Qt 5

On Wednesday, 5 December 2018 05:36:36 PST Konstantin Tokarev wrote:
> > The point is that you don't need size_t.
>
> Unless you do need it, when interfacing with code which uses size_t. For
> example, WebKit code base uses size_t as size type across the board, which
> causes lots of conversions to signed in code which glues
> platform-independent code with Qt APIs.

Yes, you're right: size_t is needed when dealing with code that already used
size_t.

But for new API, we shouldn't use it. See Ville's email on another section of
this thread.

--
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center



_______________________________________________
Development mailing list
[email protected]
https://lists.qt-project.org/listinfo/development
_______________________________________________
Development mailing list
[email protected]
https://lists.qt-project.org/listinfo/development

Reply via email to