From 29370cfee9e30e8f4ae4cd5e0f07dd095c9b7f6c Mon Sep 17 00:00:00 2001 From: PB Date: Thu, 15 Oct 2020 16:41:43 +0200 Subject: [PATCH] Get rid of wxCOMPILER_NO_OVERLOAD_ON_ENUM compile guard --- include/wx/brush.h | 7 ------- include/wx/font.h | 7 ------- include/wx/pen.h | 7 ------- 3 files changed, 21 deletions(-) diff --git a/include/wx/brush.h b/include/wx/brush.h index c4fb1da273..1ca1f1ff09 100644 --- a/include/wx/brush.h +++ b/include/wx/brush.h @@ -105,11 +105,6 @@ extern WXDLLIMPEXP_DATA_CORE(wxBrushList*) wxTheBrushList; // to compile without warnings which it would otherwise provoke from some // compilers as it compares elements of different enums -// Unfortunately some compilers have ambiguity issues when enum comparisons are -// overloaded so we have to disable the overloads in this case, see -// wxCOMPILER_NO_OVERLOAD_ON_ENUM definition in wx/platform.h for more details. -#ifndef wxCOMPILER_NO_OVERLOAD_ON_ENUM - wxDEPRECATED_MSG("use wxBRUSHSTYLE_XXX constants only") inline bool operator==(wxBrushStyle s, wxDeprecatedGUIConstants t) { @@ -122,6 +117,4 @@ inline bool operator!=(wxBrushStyle s, wxDeprecatedGUIConstants t) return static_cast(s) != static_cast(t); } -#endif // wxCOMPILER_NO_OVERLOAD_ON_ENUM - #endif // _WX_BRUSH_H_BASE_ diff --git a/include/wx/font.h b/include/wx/font.h index fa95bc192f..938e6aeaf1 100644 --- a/include/wx/font.h +++ b/include/wx/font.h @@ -677,11 +677,6 @@ extern WXDLLIMPEXP_DATA_CORE(wxFontList*) wxTheFontList; // to compile without warnings which it would otherwise provoke from some // compilers as it compares elements of different enums -// Unfortunately some compilers have ambiguity issues when enum comparisons are -// overloaded so we have to disable the overloads in this case, see -// wxCOMPILER_NO_OVERLOAD_ON_ENUM definition in wx/platform.h for more details. -#ifndef wxCOMPILER_NO_OVERLOAD_ON_ENUM - wxDEPRECATED_MSG("use wxFONTFAMILY_XXX constants") \ inline bool operator==(wxFontFamily s, wxDeprecatedGUIConstants t) { return static_cast(s) == static_cast(t); } @@ -701,6 +696,4 @@ wxDEPRECATED_MSG("use wxFONTWEIGHT_XXX constants") \ inline bool operator!=(wxFontWeight s, wxDeprecatedGUIConstants t) { return static_cast(s) != static_cast(t); } -#endif // // wxCOMPILER_NO_OVERLOAD_ON_ENUM - #endif // _WX_FONT_H_BASE_ diff --git a/include/wx/pen.h b/include/wx/pen.h index a8a7754304..411e3b882d 100644 --- a/include/wx/pen.h +++ b/include/wx/pen.h @@ -117,11 +117,6 @@ extern WXDLLIMPEXP_DATA_CORE(wxPenList*) wxThePenList; // to compile without warnings which it would otherwise provoke from some // compilers as it compares elements of different enums -// Unfortunately some compilers have ambiguity issues when enum comparisons are -// overloaded so we have to disable the overloads in this case, see -// wxCOMPILER_NO_OVERLOAD_ON_ENUM definition in wx/platform.h for more details. -#ifndef wxCOMPILER_NO_OVERLOAD_ON_ENUM - wxDEPRECATED_MSG("use wxPENSTYLE_XXX constants") inline bool operator==(wxPenStyle s, wxDeprecatedGUIConstants t) { @@ -134,6 +129,4 @@ inline bool operator!=(wxPenStyle s, wxDeprecatedGUIConstants t) return static_cast(s) != static_cast(t); } -#endif // wxCOMPILER_NO_OVERLOAD_ON_ENUM - #endif // _WX_PEN_H_BASE_