Browse Source

Silence deprecated warnings in internals of deprecated build.

Together with recent Corrade changes is Magnum compiling without any
noise again (i.e. just one line of output from Ninja).
pull/51/head
Vladimír Vondruš 12 years ago
parent
commit
6f42745250
  1. 7
      src/Magnum/Framebuffer.cpp
  2. 7
      src/Magnum/Test/DebugGLTest.cpp

7
src/Magnum/Framebuffer.cpp

@ -221,7 +221,14 @@ Framebuffer& Framebuffer::attachTextureLayer(Framebuffer::BufferAttachment attac
#ifdef MAGNUM_BUILD_DEPRECATED
Framebuffer& Framebuffer::attachTexture2D(BufferAttachment attachment, Texture2D& texture, Int mipLevel) {
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
(this->*Context::current()->state().framebuffer->texture2DImplementation)(attachment, GLenum(texture.target()), texture.id(), mipLevel);
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif
return *this;
}
#endif

7
src/Magnum/Test/DebugGLTest.cpp

@ -111,7 +111,14 @@ void DebugGLTest::insertMessageFallback() {
#ifdef MAGNUM_BUILD_DEPRECATED
void DebugGLTest::deprecated() {
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
DebugMarker::mark("hello");
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif
MAGNUM_VERIFY_NO_ERROR();
}

Loading…
Cancel
Save