From owner-sc22wg5@open-std.org  Fri Feb 12 16:37:32 2010
Return-Path: <owner-sc22wg5@open-std.org>
X-Original-To: sc22wg5-dom8
Delivered-To: sc22wg5-dom8@www2.open-std.org
Received: by www2.open-std.org (Postfix, from userid 521)
	id CEB50C3BA17; Fri, 12 Feb 2010 16:37:32 +0100 (CET)
X-Original-To: sc22wg5@open-std.org
Delivered-To: sc22wg5@open-std.org
Received: from mail1.cray.com (mail1.cray.com [136.162.62.100])
	by www2.open-std.org (Postfix) with ESMTP id EF392C178DA
	for <sc22wg5@open-std.org>; Fri, 12 Feb 2010 16:37:30 +0100 (CET)
Received: from beaver.us.cray.com (beaver.us.cray.com [172.30.74.51])
	by mail1.cray.com (8.13.6/8.13.3/gw-5323) with ESMTP id o1CFatdr024597
	(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL);
	Fri, 12 Feb 2010 09:36:55 -0600 (CST)
Received: from cfexcas01.americas.cray.com (cfexcas-2.us.cray.com [172.30.74.227])
	by beaver.us.cray.com (8.13.8/8.13.3/hub-5273) with ESMTP id o1CFagG3024910;
	Fri, 12 Feb 2010 09:36:53 -0600
Received: from fortran.us.cray.com (172.31.19.200) by
 cfexcas01.americas.cray.com (172.30.74.226) with Microsoft SMTP Server (TLS)
 id 8.1.393.1; Fri, 12 Feb 2010 09:27:51 -0600
Message-ID: <4B75737C.7000906@cray.com>
Date: Fri, 12 Feb 2010 09:27:56 -0600
From: Bill Long <longb@cray.com>
Reply-To: <longb@cray.com>
Organization: Cray Inc.
User-Agent: Thunderbird 2.0.0.23 (Macintosh/20090812)
MIME-Version: 1.0
To: Malcolm Cohen <malcolm@nag-j.co.jp>
Cc: WG5 <sc22wg5@open-std.org>
Subject: Re: [ukfortran] (SC22WG5.4174) (j3.2006) Urgent: letter ballot on
 interps
References: <20100201122928.54FB8C178E4@www2.open-std.org><20100210005356.4ABF5C3BA23@www2.open-std.org><Prayer.1.3.2.1002100840210.24280@hermes-2.csi.cam.ac.uk> <20100210185846.34028C178DA@www2.open-std.org> <32C1F39D51964BCAB7EB9BAF77B2F8CC@Marucomputer>
In-Reply-To: <32C1F39D51964BCAB7EB9BAF77B2F8CC@Marucomputer>
Content-Type: text/plain; charset="ISO-8859-1"; format=flowed
Content-Transfer-Encoding: 7bit
X-Cray-VirusStatus: clean
Sender: owner-sc22wg5@open-std.org
Precedence: bulk



Malcolm Cohen wrote:
> Bill Long wrote:
>> N.M. Maclaren wrote:
>>> On Feb 10 2010, Bill Long wrote:
>>>> Comment for F03/0039 - HYPOT()
>>>>
>
> No, there is no temptation and no possibility for confusion.
> 
> That is because the Note in question does not exist in F08.  We deleted it 
> specifically because it created more confusion than enlightenment.
> 

Of course, you are right.  I was looking a a printed 09-007r1 version at 
the time.  Sorry about that.

However, I believe I should have made another comment on this interp 
stronger.  I said

--------------
Further, instead of somewhat obscure

    HYPOT = SQRT(-1.0)

why not be clear about the intent and write

    HYPOT = IEEE_VALUE(X, IEEE_QUIET_NAN)
---------------

More than "obscure", the proposed code is not even legal.  The SQRT 
function explicitly requires that a real argument be >= 0, so SQRT(-1.0) 
has no interpretation in the standard.  The expected outcome of trying 
to compile this example would be a hard error at compile time.  Even 
more reason to go with the alternative, which is not only valid code, 
but effectively self-documenting, and does exactly what is desired. 
(That said, I still would prefer no edit at all.)

Cheers,
Bill




-- 
Bill Long                                           longb@cray.com
Fortran Technical Support    &                 voice: 651-605-9024
Bioinformatics Software Development            fax:   651-605-9142
Cray Inc./Cray Plaza, Suite 210/380 Jackson St./St. Paul, MN 55101


