[Wien] gfortran compilation and run problems for 19.1
Gavin Abo
gsabo at crimson.ua.edu
Wed Jun 26 03:37:22 CEST 2019
The == should work for C/C++ language. I don't recall ever seeing that
being used for Fortran.
A quote from a HP Doctor Fortran article [
https://software.intel.com/en-us/forums/intel-visual-fortran-compiler-for-windows/topic/274462
]:
"The real trouble with making assumptions about the internal value of
LOGICALs is when you try testing them for "equality" against another
logical expression. The way many Fortran programmers would naturally do
this is as follows:
IF (LOGVAL1 .EQ. LOGVAL2) ...
but the results of this can vary depending on the internal
representation. The Fortran language defines two operators exclusively
for use on logical values, .EQV. ("equivalent to") and .NEQV. ("not
equivalent to"). So the above test would be properly written as:
IF (LOGVAL1 .EQV. LOGVAL2) ..."
On 6/25/2019 3:14 PM, Fecher, Gerhard wrote:
> Does == work ?
>
> Ciao
> Gerhard
>
> DEEP THOUGHT in D. Adams; Hitchhikers Guide to the Galaxy:
> "I think the problem, to be quite honest with you,
> is that you have never actually known what the question is."
>
> ====================================
> Dr. Gerhard H. Fecher
> Institut of Inorganic and Analytical Chemistry
> Johannes Gutenberg - University
> 55099 Mainz
> and
> Max Planck Institute for Chemical Physics of Solids
> 01187 Dresden
> ________________________________________
> Von: Wien [wien-bounces at zeus.theochem.tuwien.ac.at] im Auftrag von Sam Trickey [trickey at qtp.ufl.edu]
> Gesendet: Dienstag, 25. Juni 2019 15:13
> An: wien at zeus.theochem.tuwien.ac.at
> Betreff: Re: [Wien] gfortran compilation and run problems for 19.1
>
> See below
>
> On 6/25/19 5:47 AM, Peter Blaha wrote:
> Hi,
>
> I can confirm the fix for inputpars.F. Of course, according to fortran standards a logical if should have an .eqv. operator (although I never "understood" what that should be good for ...).
>
> Keeps computer scientists occupied introducing needless and annoying distinctions.
>
> peace, Sam
>
>
> --
> Samuel B. Trickey
> QTP, Depts. of Physics and Chemistry
> 2324 Physics Building
> Box 118435
> Univ. of Florida
> Gainesville, FL 32611-8435
> Vox: 352-392-6978 (direct)
> Vox: 352-392-1597 (receptionist)
> Fax: 352-392-8722
> http://www.qtp.ufl.edu/ofdft
> http://users.clas.ufl.edu/trickey
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://zeus.theochem.tuwien.ac.at/pipermail/wien/attachments/20190625/880509aa/attachment.html>
More information about the Wien
mailing list