[Development] QMetaType templates

Craig.Scott at csiro.au Craig.Scott at csiro.au
Fri Dec 23 00:05:14 CET 2011


Given Jedrzej's recent post on QMetaType, it sounds like there are people looking at QMetaType in a bit more detail at the moment. That being the case, I'd appreciate a few more opinions on QTBUG-15313 which I believe was closed prematurely. The brief version is that I suggested that the documented requirements on types that can be used with QMetaType are tighter than they need to be. The current requirements are that types have a copy constructor, but as explained in the JIRA issue, simply being clonable would be enough in a useful set of cases. Similarly, the requirement for a public default constructor and destructor can also be relaxed. Because Qt needs to preserve binary compatibility from version to version, there are aspects of the implementation which, although not documented, are effectively part of the public API because they could not change without breaking binary compatibility. The JIRA issue merely asks for some of those things to be documented as part of the public API, specifically the qMetaTypeConstructHelper() and qMetaTypeDeleteHelper() template functions in the same way that qRegisterMetaType() is already documented.

Anyone willing to re-open discussion on that JIRA issue? Seems like little downside but definitely some upside.

--
Dr Craig Scott
Computational Software Engineering Team Leader, CSIRO (CMIS)
Melbourne, Australia






More information about the Development mailing list