From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32723 invoked by alias); 6 Jul 2013 04:10:06 -0000 Mailing-List: contact glibc-bugs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: glibc-bugs-owner@sourceware.org Received: (qmail 32620 invoked by uid 48); 6 Jul 2013 04:09:54 -0000 From: "bugdal at aerifal dot cx" To: glibc-bugs@sourceware.org Subject: [Bug libc/15720] New: stdc-predef.h wrongly defines __STDC_IEC_559_COMPLEX__ Date: Sat, 06 Jul 2013 04:10:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: libc X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: bugdal at aerifal dot cx X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter cc Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-07/txt/msg00022.txt.bz2 http://sourceware.org/bugzilla/show_bug.cgi?id=15720 Bug ID: 15720 Summary: stdc-predef.h wrongly defines __STDC_IEC_559_COMPLEX__ Product: glibc Version: unspecified Status: NEW Severity: normal Priority: P2 Component: libc Assignee: unassigned at sourceware dot org Reporter: bugdal at aerifal dot cx CC: drepper.fsp at gmail dot com Based on the comment in stdc-predef.h, somebody apparently assumed __STDC_IEC_559_COMPLEX__ means the implementation supports complex arithmetic. This is not what it means. Complex arithmetic is mandatory in C99, and in C11 implementations that lack complex arithmetic must define __STDC_NO_COMPLEX__. The meaning of __STDC_IEC_559_COMPLEX__ is that the implementation conforms to Annex G, which among other things, requires the existence of the otherwise-optional _Imaginary types which GCC does not support. This is a fairly serious issue for applications, since on an implementation conforming to Annex G, I*INFINITY is interpreted as intended, whereas on an implementation lacking _Imaginary types and defining I as _Complex_I, I*INFINITY results in a NAN due to the 0*INFINITY term. -- You are receiving this mail because: You are on the CC list for the bug.