From owner-svn-src-all@FreeBSD.ORG Tue Jan 17 20:22:10 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B08B51065670; Tue, 17 Jan 2012 20:22:10 +0000 (UTC) (envelope-from ed@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A00788FC1D; Tue, 17 Jan 2012 20:22:10 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q0HKMABK006085; Tue, 17 Jan 2012 20:22:10 GMT (envelope-from ed@svn.freebsd.org) Received: (from ed@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q0HKMAsP006083; Tue, 17 Jan 2012 20:22:10 GMT (envelope-from ed@svn.freebsd.org) Message-Id: <201201172022.q0HKMAsP006083@svn.freebsd.org> From: Ed Schouten Date: Tue, 17 Jan 2012 20:22:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r230278 - head/include X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Jan 2012 20:22:10 -0000 Author: ed Date: Tue Jan 17 20:22:10 2012 New Revision: 230278 URL: http://svn.freebsd.org/changeset/base/230278 Log: Only use the static assertion when __generic is available. Reported by: tijl Modified: head/include/complex.h Modified: head/include/complex.h ============================================================================== --- head/include/complex.h Tue Jan 17 20:21:31 2012 (r230277) +++ head/include/complex.h Tue Jan 17 20:22:10 2012 (r230278) @@ -36,6 +36,9 @@ #define _Complex __complex__ #endif #define _Complex_I ((float _Complex)1.0i) +#endif + +#ifdef __generic _Static_assert(__generic(_Complex_I, float _Complex, 1, 0), "_Complex_I must be of type float _Complex"); #endif