From 5bd3f7b58f33348a1a8113ff931061183c87c741 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Tue, 28 Apr 2015 21:59:39 +0200 Subject: [PATCH] GCC 4.6 compatibility: conflicting template and parameter names. --- src/Magnum/Buffer.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/Magnum/Buffer.h b/src/Magnum/Buffer.h index 2a993e8c4..c4d754406 100644 --- a/src/Magnum/Buffer.h +++ b/src/Magnum/Buffer.h @@ -840,9 +840,15 @@ class MAGNUM_EXPORT Buffer: public AbstractObject { } /** @overload */ + #ifdef CORRADE_GCC46_COMPATIBILITY + #define size size_ /* With GCC 4.6 it conflicts with size(). WTF. */ + #endif template Buffer& setLabel(const char(&label)[size]) { return setLabelInternal({label, size - 1}); } + #ifdef CORRADE_GCC46_COMPATIBILITY + #undef size + #endif /** @brief Target hint */ TargetHint targetHint() const { return _targetHint; }