Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 5 Sep 2016 18:02:37 +0000 (UTC)
From:      Dimitry Andric <dim@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r305430 - head/contrib/gcclibs/libcpp
Message-ID:  <201609051802.u85I2bFp006758@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: dim
Date: Mon Sep  5 18:02:37 2016
New Revision: 305430
URL: https://svnweb.freebsd.org/changeset/base/305430

Log:
  Define libcpp's HAVE_DESIGNATED_INITIALIZERS in a defined and portable
  way.
  
  MFC after:	3 days

Modified:
  head/contrib/gcclibs/libcpp/system.h

Modified: head/contrib/gcclibs/libcpp/system.h
==============================================================================
--- head/contrib/gcclibs/libcpp/system.h	Mon Sep  5 17:56:52 2016	(r305429)
+++ head/contrib/gcclibs/libcpp/system.h	Mon Sep  5 18:02:37 2016	(r305430)
@@ -347,9 +347,12 @@ extern void abort (void);
    ??? C99 designated initializers are not supported by most C++
    compilers, including G++.  -- gdr, 2005-05-18  */
 #if !defined(HAVE_DESIGNATED_INITIALIZERS)
-#define HAVE_DESIGNATED_INITIALIZERS \
-  ((!defined(__cplusplus) && (GCC_VERSION >= 2007)) \
-   || (__STDC_VERSION__ >= 199901L))
+# if (!defined(__cplusplus) && (GCC_VERSION >= 2007)) \
+     ||(__STDC_VERSION__ >= 199901L)
+#  define HAVE_DESIGNATED_INITIALIZERS 1
+# else
+#  define HAVE_DESIGNATED_INITIALIZERS 0
+# endif
 #endif
 
 /* Be conservative and only use enum bitfields with GCC.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201609051802.u85I2bFp006758>