Specifying type of literal integer constants
From: André Janz (ALDUBOFMWIGO_at_spammotel.com)
Date: 02/11/04
- Next message: Steve Lionel: "Re: CVF6.6C memory leak"
- Previous message: David Ham: "Re: xml parsers in fortran"
- Next in thread: Steve Lionel: "Re: Specifying type of literal integer constants"
- Reply: Steve Lionel: "Re: Specifying type of literal integer constants"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Wed, 11 Feb 2004 18:25:15 +0100
Hi,
I'm just trying to figure out if there is a way to specify the type of a
literal integer constant. I couldn't find anything definite on the web
nor in the Usenet archive.
The problem is the following:
An existing program accesses files through constant unit numbers
eg.
open(unit=9998,file='local',status='unknown')
When I try to compile the program on an Itanium 2 machine (64 bit) with
the 7.1 Intel Fortran compiler I get error messages about the use of flush:
---
call flush(9994)
^
Error 260 at (489:userprog.f) : This subroutine has the wrong number of
arguments or arguments with the wrong name, type or rank
---
(This only happens when I 'USE IFLPORT' which is probably
Intel-specific. I'd like to keep this since it already provided some
very useful diagnostics.)
What I would like to do is something similar to specifying a double
precision constant as 1.d0. The compiler expects an INTEGER*4 value here.
Admittedly it would be good practice to use an integer variable for this
purpose but I also get this problem when I write rand(0) and this is
just ridiculous. (eg. integer*4 zero / zero=0 / dummy=rand(zero))
André
- Next message: Steve Lionel: "Re: CVF6.6C memory leak"
- Previous message: David Ham: "Re: xml parsers in fortran"
- Next in thread: Steve Lionel: "Re: Specifying type of literal integer constants"
- Reply: Steve Lionel: "Re: Specifying type of literal integer constants"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|