summaryrefslogtreecommitdiff
path: root/idlc
diff options
context:
space:
mode:
authorDavid Ostrovsky <David.Ostrovsky@gmx.de>2012-05-04 20:46:58 +0200
committerDavid Ostrovsky <David.Ostrovsky@gmx.de>2012-05-04 20:46:58 +0200
commit6f1a96249014c6144c638cfcf38db3e910f6a6bc (patch)
tree5021444af92da884fcbf0df795ccb59efae0074b /idlc
parent20a8768b1c6a6a1456cda9cd096a304e16473fbb (diff)
disable GCC diagnostic #pragma on older GCC versions
Change-Id: Ib0c1ec649b4e391359ef41cebad501b297579557
Diffstat (limited to 'idlc')
-rw-r--r--idlc/source/scanner.l2
1 files changed, 2 insertions, 0 deletions
diff --git a/idlc/source/scanner.l b/idlc/source/scanner.l
index 8675f2625f89..6847ba4ddf6a 100644
--- a/idlc/source/scanner.l
+++ b/idlc/source/scanner.l
@@ -257,8 +257,10 @@ static void parseLineAndFile(sal_Char* pBuf)
// Suppress any warnings from generated code:
#if defined __GNUC__
+#if (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 2))
#pragma GCC diagnostic ignored "-Wunused-function"
#pragma GCC diagnostic ignored "-Wunused-label"
+#endif
#elif defined __SUNPRO_CC
#pragma disable_warn
#elif defined _MSC_VER