Skip to content

C++20 removed std::result_of #1999

Description

@215020267

Description:
In /std:c++17 mode, this triggers a deprecation warning in recent versions of MSVC. In /std:c++latest mode, now that microsoft/STL#380 has been merged, this will trigger an error in VS 2019 16.6 Preview 2.

Reproduce steps:

  1. git clone https://github.com/davisking/dlib D:\Dlib\src
  2. cd D:\Dlib\src
  3. set CL=/D_HAS_AUTO_PTR_ETC=1 /D_WINSOCKAPI_
  4. mkdir build_amd64
  5. cd D:\Dlib\src\build_amd64
  6. cmake -G "Visual Studio 15 Win64" -DCMAKE_SYSTEM_VERSION=10.0.17134.0 ..
  7. cmake -G "Visual Studio 15 Win64" -DCMAKE_SYSTEM_VERSION=10.0.17134.0 ..\dlib\test
  8. msbuild /m /p:Platform=x64 /p:Configuration=Release Project.sln /t:Rebuild /p:PreferredToolArchitecture=x64

ErrorMessage:
F:\gitP\davisking\dlib\dlib\threads\async.h(55): error C2039: 'result_of': is not a member of 'std' (compiling source file F:\gitP\davisking\dlib\dlib\filtering\kalman_filter.cpp)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions