Date: prev next · Thread: first prev next last
2018 Archives by date, by thread · List index


On 07/09/18 11:26, Stephan Bergmann wrote:
> D:\cygwin\home\Hearthstone\lode\dev\core\framework\inc\helper\shareablemutex.hxx > 73    noExplicitConstructor    398    style    Class 'ShareGuard' has a constructor with 1 argument that is not explicit.

For all the nine noExplicitConstructor occurrences:  For one, what puzzles me is Cppcheck's fixation on "1 argument" ctors, as "explicit" has long surpassed being only relevant for ctors that can be called with one argument; if it warns about these, why doesn't it warn about ctors taking more arguments, too?  For another, for each individual ctor, they may be arguments for and against it being "explicit".  Would need deeper inspection, but generally feels on the level of rather unhelpful noise.

Especially, ctors that are part of the stable URE interface should likely not be changed to be explicit, to avoid incompatible changes. See the discussion at <https://gerrit.libreoffice.org/#/c/60123/> "Cppcheck: make 1-argument ctors explicit".

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.