Il 14/09/20 23:48, Thiago Macieira ha scritto:
It's not inline, it's because you didn't define it.To use the extern in the header, you need to add the definition to the .cpp, after the Private class was defined. That effectively means repeating the body of the destructor we extern'ed. So we'd probably need a macro to ensure that.
As commented on the patch, this part of the story that eventually led to the design of QIntrusiveSharedDataPointer -- the previous incantations featured macros and the like, and the commit message talked about trouble in the presence of exported symbols, but I'm not sure what it was referring to. Does anyone remember? If it's no longer an issue, is pinning the smart pointer dtor the way we want to go? How to make it into a public API so that it's not just a Qt-specific trick? (After all, the smart pointers in question have public APIs)
Thanks, -- Giuseppe D'Angelo | [email protected] | Senior Software Engineer KDAB (France) S.A.S., a KDAB Group company Tel. France +33 (0)4 90 84 08 53, http://www.kdab.com KDAB - The Qt, C++ and OpenGL Experts
smime.p7s
Description: Firma crittografica S/MIME
_______________________________________________ Development mailing list [email protected] https://lists.qt-project.org/listinfo/development
