[PATCH] Allow reading of values on invalid KConfigGroups

Sebastian TrĂ¼g sebastian at trueg.de
Tue Feb 24 14:59:49 GMT 2009


On Tuesday 24 February 2009 15:08:34 Thomas Braxton wrote:
> I don't know why you would want to read from an invalid group, but
> wouldn't it make the patch a lot easier if you just returned the
> default right away if the group is invalid? i.e.
>
> replace
>     Q_ASSERT(isValid());
> with
>     if (!isValid()) {
>         return aDefault;
>     }

yes, I just like one-exit-point methods better. But I don't really care. :)




More information about the kde-core-devel mailing list