X-Spam-Check-By: sourceware.org
Reply-To: <cygwin@cygwin.com>, <newlib@sources.redhat.com>
From: "Dave Korn" <dave.korn@artimi.com>
To: <gdr@integrable-solutions.net>
Cc: <cygwin@cygwin.com>, <libstdc++@gcc.gnu.org>, <newlib@sources.redhat.com>
Subject: RE: gcc-3.4.4-1: c++: cmath: calling std::isnan results in endless loop
Date: Mon, 27 Feb 2006 17:18:26 -0000
Message-ID: <01d701c63bc1$d20e7e90$a501a8c0@CAM.ARTIMI.COM>
MIME-Version: 1.0
Content-Type: text/plain; 	charset="us-ascii"
Content-Transfer-Encoding: 7bit
In-Reply-To: <m34q2kg2k3.fsf@uniton.integrable-solutions.net>
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

On 27 February 2006 17:00, gdr@integrable-solutions.net wrote:

> "Dave Korn" <dave.korn@artimi.com> writes:
> 
> [...]
> 
>>   It looks to me like the cygwin/newlib combination is not being compliant
>> if it implements isnan as a function rather than a macro.  I couldn't see
>> anything in the standard that says it can be a function, and every
>> reference to it describes it as a macro, not a function.  It may be the
>> case that libstdc++ is within its rights to assume that isnan is a macro
>> after all. 
> 
> yes, isnan and friends are supposed to be macros only, not functions.

  Thanks for the confirmation.  I have yet to figure out whether this is
specific to newlib-on-cygwin, or applies to other newlib configurations as
well, but that rules out libstdc++ from being the underlying cause of the
problem here.

>>   OTOH it may be that libstdc++ was only supposed to be shadowing those
>> ctype macros that are guaranteed to have underlying function
>> implementations; I don't know what the shadowing is for, so I can't
>> comment. 
> 
> libstdc++ is supposed to shadow ctype macros -- and it also expect
> them to have a function implementation.

  Ah, does that imply it is also /supposed/ to shadow math.h macros, but it
does /not/ expect them to have a function implementation?  Or that it is /not/
supposed to shadow math macros, only ctype ones, /because/ only they are
guaranteed to have a function implementation as well/


    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

