[Qgis-psc] Curly braces initilization

Alessandro Pasotti apasotti at gmail.com
Thu Aug 19 07:20:56 PDT 2021


Hi Denis,

thank you for raising this topic, I just wanted to add another piece of
information:
https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#es23-prefer-the--initializer-syntax

and if you have a spare night here is some serious criticism:
http://mikelui.io/2019/01/03/seriously-bonkers.html

Another thing to consider is that we already have so many written (and
probably more unwritten) rules about coding style that I am afraid to add
another one if there isn't a very good reason, we don't want to scare new
potential developers.



On Thu, Aug 19, 2021 at 3:45 PM Denis Rouzaud <denis.rouzaud at gmail.com>
wrote:

> Dear PSC,
>
> I'd like to get your eyes on a technical discussion rising in a few PRs:
> curly braces initialization.
> It's a C++ coding guideline to define, and the topic seems a bit techincal.
>
> I'd like that we get our coding guidelines updated regarding this
> question. I believe this would require a few of our best low-level devs to
> discuss and take a decision.
>
> I don't know if you / who could take the lead on this. I'd be happy to
> help, maybe organize the discussion if you consider this is OK.
>
> Kind regards,
> Denis
>
> Some references:
> last discussion in PR:
> https://github.com/qgis/QGIS/pull/44710#issuecomment-901921304
> some technical reading about the question:
> https://stackoverflow.com/questions/18222926/why-is-list-initialization-using-curly-braces-better-than-the-alternatives
>


-- 
Alessandro Pasotti
QCooperative:  www.qcooperative.net
ItOpen:   www.itopen.it
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-psc/attachments/20210819/b16dec85/attachment.html>


More information about the Qgis-psc mailing list