[Development] Suggested addition to wiki.qt.io/Coding_Conventions

Marc Mutz marc.mutz at kdab.com
Sat May 16 22:01:36 CEST 2015


On Wednesday 13 May 2015 09:30:05 Thiago Macieira wrote:
> The drawbacks only appear in debug builds, so is this worth the
> uglification?

Yet another example of things that go wrong when blindly exporting
classes wholesale:
  http://testresults.qt.io/logs/qt/qtdeclarative/472c6e2acc170082356db371eb32b518c449d600/windows7x86windows7x86msvc2010release_developer-
build/708d34c65c2d74994ac0344f9912adbefe88e067/buildlog.txt.gz
(from https://codereview.qt-project.org/112431).

Mind you, the Coding Conventions already forbid to inherit from
template classes. It's just that it wasn't fixed for Qt 5.

But the root problem isn't inheriting from templates, it's exporting
the whole subclass.

Convinced now?

Marc

-- 
Marc Mutz <marc.mutz at kdab.com> | Senior Software Engineer
KDAB (Deutschland) GmbH & Co.KG, a KDAB Group Company
Tel: +49-30-521325470
KDAB - The Qt Experts



More information about the Development mailing list