[Development] Proposal: Deprecate QVector in Qt 6

Matthew Woehlke mwoehlke.floss at gmail.com
Thu Apr 23 21:13:45 CEST 2020


On 23/04/2020 10.45, Giuseppe D'Angelo via Development wrote:
> (Otherwise, "list" in Python is heterogeneous, why isn't QList 
> heterogeneous?)

That doesn't count; *variables* in Python are heterogeneous.

   a = 5      # type(a) == int
   a = 'foo'  # type(a) == str

It should not surprise one that containers in a strongly typed language 
are exactly as homogeneous as any other variable is strongly typed. 
(That is, unless the "type" is actually a type-erasure type such as 
QVariant.)

-- 
Matthew


More information about the Development mailing list