Fix build with msvc
AcceptedPublic

Authored by vonreth on Mar 20 2019, 7:51 AM.

Details

Summary

For the decltype change see https://stackoverflow.com/a/51347067

Diff Detail

Repository
R159 KActivities Statistics
Branch
master
Lint
Lint Skipped
Unit
Unit Tests Skipped
Build Status
Buildable 9889
Build 9907: arc lint + arc unit
vonreth created this revision.Mar 20 2019, 7:51 AM
Restricted Application added a project: Frameworks. · View Herald TranscriptMar 20 2019, 7:51 AM
Restricted Application added a subscriber: kde-frameworks-devel. · View Herald Transcript
vonreth requested review of this revision.Mar 20 2019, 7:51 AM

btw

.vim-template:cpp
.vim-template:h

aren't valid file names on windows, and look strange for unix too

aacid added a comment.Mar 20 2019, 8:21 PM

Which MSVC is that? it seems the decltype change is workarounding non C++14 support?

Msvc2017.
I think frameworks is still c++11?

Msvc2017.
I think frameworks is still c++11?

Not sure, probably yes.

So then the workaround is correct, I haven't tried whether the original code compiles with CMAKE_CXX_STANDARD=17

aacid accepted this revision.Mon, Mar 25, 7:29 PM

I don't know who is responsible for this, but noone seems to disagree, so if this fixes the build for MSVC and doesn't break other platforms let's go for it?

This revision is now accepted and ready to land.Mon, Mar 25, 7:29 PM