- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi ?
I am a CVF 6.5A user on Intel NT 4.0.
I have a problem to initialize an array, declared as a pointer.
When I declare USE DFWINA, following errors are occurred.
But does not declare USE DFWINA, errors are cleaned.
Because of I should use many functions in DFWINA, above problems should be solved.
Help me please !
Thanks
*** Code ***
use dfwina
integer*4, pointer :: a(:) => null()
I = 10
if(not. associated(ia)) allocate(ia(n))
stop
end
*** Error ***
Compaq Visual Fortran Optimizing Compiler Version 6.5 (Update A)
Copyright 2001 Compaq Computer Corp. All rights reserved.
test.f90
test.f90(2) : Error: This array or function or substring is invalid in constant
expressions. [NULL]
integer*4, pointer :: ia(:) => null()
-------------------------------------^
test.f90(2) : Error: This is not a valid initialization expression. [NULL]
integer*4, pointer :: ia(:) => null()
-------------------------------------^
I am a CVF 6.5A user on Intel NT 4.0.
I have a problem to initialize an array, declared as a pointer.
When I declare USE DFWINA, following errors are occurred.
But does not declare USE DFWINA, errors are cleaned.
Because of I should use many functions in DFWINA, above problems should be solved.
Help me please !
Thanks
*** Code ***
use dfwina
integer*4, pointer :: a(:) => null()
I = 10
if(not. associated(ia)) allocate(ia(n))
stop
end
*** Error ***
Compaq Visual Fortran Optimizing Compiler Version 6.5 (Update A)
Copyright 2001 Compaq Computer Corp. All rights reserved.
test.f90
test.f90(2) : Error: This array or function or substring is invalid in constant
expressions. [NULL]
integer*4, pointer :: ia(:) => null()
-------------------------------------^
test.f90(2) : Error: This is not a valid initialization expression. [NULL]
integer*4, pointer :: ia(:) => null()
-------------------------------------^
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Bingo! -- I had the same problem and just after I saw your post I realized
what is the problem: DFWIN(A) defines NULL as an INTEGER, PARAMETER.
To use NULL() intrinsic you have to rename DFWIN'S NULL to something else, e.g. NUL:
USE DFWINA, NUL=>NULL
Jugoslav
what is the problem: DFWIN(A) defines NULL as an INTEGER, PARAMETER.
To use NULL() intrinsic you have to rename DFWIN'S NULL to something else, e.g. NUL:
USE DFWINA, NUL=>NULL
Jugoslav
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page