From: Scott Wheeler Date: Sun, 22 Mar 2009 19:27:38 +0000 (+0000) Subject: Less of The Big Ugly in the middle of the classes. X-Git-Tag: v1.6rc1~38 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=fad967ae0bacb3d7208cbd26210284d553d4ca5e;p=taglib Less of The Big Ugly in the middle of the classes. git-svn-id: svn://anonsvn.kde.org/home/kde/trunk/kdesupport/taglib@942880 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- diff --git a/taglib/fileref.h b/taglib/fileref.h index db2b7c77..0a7ecee0 100644 --- a/taglib/fileref.h +++ b/taglib/fileref.h @@ -91,16 +91,8 @@ namespace TagLib { class TAGLIB_EXPORT FileTypeResolver { -#ifdef __GNUC__ -#if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ > 1) -#pragma GCC diagnostic ignored "-Wnon-virtual-dtor" -#endif -#endif - + TAGLIB_IGNORE_MISSING_DESTRUCTOR public: - // do not fix compiler warning about missing virtual destructor - // since this would not be binary compatible - // let Scott fix it whenever he thinks BIC changes can next be applied /*! * This method must be overridden to provide an additional file type * resolver. If the resolver is able to determine the file type it should diff --git a/taglib/mpeg/id3v1/id3v1tag.h b/taglib/mpeg/id3v1/id3v1tag.h index c8e4f99f..28dddcf0 100644 --- a/taglib/mpeg/id3v1/id3v1tag.h +++ b/taglib/mpeg/id3v1/id3v1tag.h @@ -59,12 +59,7 @@ namespace TagLib { class TAGLIB_EXPORT StringHandler { -#ifdef __GNUC__ -#if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ > 1) -#pragma GCC diagnostic ignored "-Wnon-virtual-dtor" -#endif -#endif - + TAGLIB_IGNORE_MISSING_DESTRUCTOR public: // BIC: Add virtual destructor. diff --git a/taglib/toolkit/taglib.h b/taglib/toolkit/taglib.h index 3a63cdb9..de9ecd69 100644 --- a/taglib/toolkit/taglib.h +++ b/taglib/toolkit/taglib.h @@ -30,6 +30,12 @@ #define TAGLIB_MINOR_VERSION 5 #define TAGLIB_PATCH_VERSION 0 +#if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ > 1)) +#define TAGLIB_IGNORE_MISSING_DESTRUCTOR pragma GCC diagnostic ignored "-Wnon-virtual-dtor" +#else +#define TAGLIB_IGNORE_MISSING_DESTRUCTOR +#endif + #include //! A namespace for all TagLib related classes and functions