Browse Source

MSVC 2017, you too.

I wanted to just ignore these, but the RT builds for some reason have
warnings-as-error enabled by default and, UGH, I just want this thing to
finally pass the CI.
master
Vladimír Vondruš 8 hours ago
parent
commit
ac013346a4
  1. 7
      src/Magnum/Magnum.h
  2. 12
      src/Magnum/Resource.h

7
src/Magnum/Magnum.h

@ -1363,7 +1363,12 @@ class CompressedPixelStorage;
enum class CORRADE_DEPRECATED_ENUM("the ResourceManager class is obsolete") ResourceState: UnsignedByte;
enum class CORRADE_DEPRECATED_ENUM("the ResourceManager class is obsolete") ResourceDataState: UnsignedByte;
enum class CORRADE_DEPRECATED_ENUM("the ResourceManager class is obsolete") ResourcePolicy: UnsignedByte;
template<class T, class U = T> class CORRADE_DEPRECATED("the ResourceManager class is obsolete") Resource;
template<class T, class U = T> class
#ifndef CORRADE_MSVC2017_COMPATIBILITY
/* See Resource.h for details why this is removed on MSVC 2017 */
CORRADE_DEPRECATED("the ResourceManager class is obsolete")
#endif
Resource;
class CORRADE_DEPRECATED("the ResourceManager class is obsolete") ResourceKey;
template<class...> class CORRADE_DEPRECATED("the ResourceManager class is obsolete") ResourceManager;
#endif

12
src/Magnum/Resource.h

@ -161,7 +161,17 @@ template<class T, class U = T>
#else
template<class T, class U>
#endif
class CORRADE_DEPRECATED("the ResourceManager class is obsolete") Resource {
class
#ifndef CORRADE_MSVC2017_COMPATIBILITY
/* MSVC 2017 warns in DebugTools/ForceRenderer.cpp and ObjectRenderer.cpp
about use of ~Resource() from the (defaulted!) class destructor. The
warning cannot be suppressed and is reported at the very last line of
the files, and all warnings are treated as errors in the RT build, so
just skip the deprecation macro there. Ugh. */
CORRADE_DEPRECATED("the ResourceManager class is obsolete")
#endif
Resource
{
public:
/**
* @brief Default constructor

Loading…
Cancel
Save