[Development] HEADS-UP: QStringLiteral

André Pönitz apoenitz at t-online.de
Thu Aug 22 20:58:42 CEST 2019


On Thu, Aug 22, 2019 at 08:48:30PM +0200, André Pönitz wrote:
> On Thu, Aug 22, 2019 at 05:39:07PM +0200, Mutz, Marc via Development wrote:
> > I'm sorry if I sound blunt, but this is just nonsense. What you call
> > optimisation, isn't. Using QStringLiteral or QLatin1String is equally
> > readable. As is just using "".
> 
> I am not sorry to sound blunt here, but calling
> 
>      a["b"] = "c"
> 
> "equally readable" to
> 
>      a[QStringLiteral("b")] = QStringLiteral("c")
> 
> requires a kind of proficiency that's rare to find in real life.

And to make it clear: I am not that proficient. To me the second version is
70% line noise and I in ordinary cases I happily pay cycles to have not to
write or read that.

Andre'



More information about the Development mailing list