On Sunday, 24 November 2019 09:57:56 PST Olivier Goffart wrote:
> Adding a cast<T> function does not sound like a bad idea? But should it be
> done in Qt5.15 or Qt6. And should it return T or optional<T> (in case the
> conversion did not work)  or have a bool*ok=nullptr  parameter?

The problem with std::optional in Qt 5 is that you can't require it. So either 
you add an API behind #if (which is ok) or you have to wait for Qt 6.

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel System Software Products



_______________________________________________
Development mailing list
[email protected]
https://lists.qt-project.org/listinfo/development

Reply via email to