D17606: [WIP] Use <optional> if available.

Daniel Vrátil noreply at phabricator.kde.org
Sun Dec 16 10:44:01 GMT 2018


dvratil added a comment.


  I've recently run into the same problem on Akonadi on Windows, ended up allowing C++17 on Windows only and shipping a C++14-compatible implementation of C++17 optional in 3rdparty. Maybe we could just get rid of the `optional` in this agent until we can switch to C++17 proper. I hate not having it, but it's just one or two occurrences here and probably not worth the magic to satisfy all compilers.

INLINE COMMENTS

> CMakeLists.txt:3
>  
> -set(CMAKE_CXX_STANDARD 14)
>  

If even FreeBSD supports C++17 out of the box these days, I wonder if we can switch to 17 everywhere, or if we still need to support some ancient distros...in any case, for now, please stick to C++14.

Setting it to C++17 also triggers the `auto_ptr` error in Akonadi, since `auto_ptr` has been removed in C++17, but is present in 14. Current Akonadi master does have a fix for that , however (and couple others).

REPOSITORY
  R206 KMail

REVISION DETAIL
  https://phabricator.kde.org/D17606

To: tcberner, #freebsd, mlaurent, dvratil
Cc: kde-pim, dvasin, rodsevich, winterz, vkrause, mlaurent, knauss, dvratil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20181216/358133fa/attachment.html>


More information about the kde-pim mailing list