Re: auto QString(Builder) considered VERY HARMFUL -> use clazy, especially before releases

2018-09-27 Thread Albert Astals Cid
El dijous, 27 de setembre de 2018, a les 21:01:13 CEST, Friedrich W. H. Kossebau va escriure: > Am Donnerstag, 27. September 2018, 20:08:54 CEST schrieb Andreas Hartmetz: > > Today I fixed the third or so crash in KDE software due to the following > > pattern: > > > > const auto str = someString

Re: auto QString(Builder) considered VERY HARMFUL -> use clazy /w kdevelop

2018-09-27 Thread Friedrich W. H. Kossebau
Darn, forgot some obvious promo bits... see below: Am Donnerstag, 27. September 2018, 21:01:13 CEST schrieb Friedrich W. H. Kossebau: > Am Donnerstag, 27. September 2018, 20:08:54 CEST schrieb Andreas Hartmetz: > > Please take care. > > Care can be done e.g. by deploying clazy with > auto-unexpe

Re: auto QString(Builder) considered VERY HARMFUL

2018-09-27 Thread Elvis Angelaccio
On giovedì 27 settembre 2018 20:08:54 CEST, Andreas Hartmetz wrote: Hello, Today I fixed the third or so crash in KDE software due to the following pattern: const auto str = someString + anotherString; What happens is that the type of str ends up being QStringBuilder instead of QString. The

Re: auto QString(Builder) considered VERY HARMFUL -> use clazy, especially before releases

2018-09-27 Thread Friedrich W. H. Kossebau
Am Donnerstag, 27. September 2018, 20:08:54 CEST schrieb Andreas Hartmetz: > Today I fixed the third or so crash in KDE software due to the following > pattern: > > const auto str = someString + anotherString; > > What happens is that the type of str ends up being QStringBuilder > instead of QStr

Re: auto QString(Builder) considered VERY HARMFUL

2018-09-27 Thread Daniel Nicoletti
I would be awesome if clazy detected this :) Em qui, 27 de set de 2018 às 15:09, Andreas Hartmetz escreveu: > > Hello, > > Today I fixed the third or so crash in KDE software due to the following > pattern: > > const auto str = someString + anotherString; > > What happens is that the type of str e

auto QString(Builder) considered VERY HARMFUL

2018-09-27 Thread Andreas Hartmetz
Hello, Today I fixed the third or so crash in KDE software due to the following pattern: const auto str = someString + anotherString; What happens is that the type of str ends up being QStringBuilder instead of QString. The QStringBuilder is destroyed after the semicolon, and all access to "s