IMHO, it should be a Qt6 feature. It’s awesome. However, I liked the idea (is it deprecated or what?) of a template method template<typename T, typename Args…> std::observer_ptr<QObject> qMakeChild(gsll::not_null<std::observer_ptr<QObject>> parent, Args… args) { return parent->adoptChild(std::make_unique<T>(args)); }
With that method, you don’t need to implement stuff like QLibrary::QLibrary(QParentPtr<QObject *> parent, const QString &fileName), You just need to split ctor into safe and unsafe versions and deprecate unsafe. Maybe I’m asking too much, but it would be nice get rid of raw pointers completely switching to pair std::unique_ptr/std::observer_ptr > 3 мая 2019 г., в 19:22, Daniel Teske <q...@squorn.de> написал(а): > > So, who thinks that this is something that ought to be a Qt6 feature? > > And who wants to actually help make that happen? > > daniel > > _______________________________________________ > Development mailing list > Development@qt-project.org > https://lists.qt-project.org/listinfo/development
_______________________________________________ Development mailing list Development@qt-project.org https://lists.qt-project.org/listinfo/development