- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The following code does not compile:
ifort abc.f90 -o abc
abc.f90(23): error #6580: Name in only-list does not exist. [T_ADD]
use abc, only: t, t_add
-------------------^
Isn't the code fine? (just as a note, gfortran accepts it).
ifort -V
Intel Fortran Intel 64 Compiler Professional for applications running on Intel 64, Version 11.1 Build 20100414 Package ID: l_cprof_p_11.1.072
module abc
implicit none
public :: t, t_add
type t
integer :: i
contains
procedure, pass(t_obj) :: add => t_add
end type t
contains
pure subroutine t_add(t_obj,n)
class(t), intent(inout) :: t_obj
integer, intent(in) :: n
t_obj%i = t_obj%i + n
end subroutine t_add
end module abc
program p
use abc, only: t, t_add
implicit none
end program p
Link Copied
5 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
(Sorry, the formatting was lost in my previous post.)
The following code does not compile:
ifort abc.f90 -o abc
abc.f90(23): error #6580: Name in only-list does not exist. [T_ADD]
use abc, only: t, t_add
-------------------^
Isn't the code fine? (just as a note, gfortran accepts it).
ifort -V
Intel Fortran Intel 64 Compiler Professional for applications running on Intel 64, Version 11.1 Build 20100414 Package ID: l_cprof_p_11.1.072
module abc
implicit none
public :: t, t_add
type t
integer :: i
contains
procedure, pass(t_obj) :: add => t_add
end type t
contains
pure subroutine t_add(t_obj,n)
class(t), intent(inout) :: t_obj
integer, intent(in) :: n
t_obj%i = t_obj%i + n
end subroutine t_add
end module abc
program p
use abc, only: t, t_add
implicit none
end program p
The following code does not compile:
ifort abc.f90 -o abc
abc.f90(23): error #6580: Name in only-list does not exist. [T_ADD]
use abc, only: t, t_add
-------------------^
Isn't the code fine? (just as a note, gfortran accepts it).
ifort -V
Intel Fortran Intel 64 Compiler Professional for applications running on Intel 64, Version 11.1 Build 20100414 Package ID: l_cprof_p_11.1.072
module abc
implicit none
public :: t, t_add
type t
integer :: i
contains
procedure, pass(t_obj) :: add => t_add
end type t
contains
pure subroutine t_add(t_obj,n)
class(t), intent(inout) :: t_obj
integer, intent(in) :: n
t_obj%i = t_obj%i + n
end subroutine t_add
end module abc
program p
use abc, only: t, t_add
implicit none
end program p
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I believe I have seen a similar report in the past that I'll see if I can dig up.
The example compiles when removing the "only: t, t_add" from the USE in the main program if that offers a work-around.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The circumstances of the earlier sightings of this error were different. I reported this instance the Development.
(Internal tracking id: DPD200157976)
(Resolution Update on 11/30/2010): This defect is fixed in the Intel Fortran Composer XE 2011 initial release (12.0.0.084 - Linux)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I confirmed this defect is fixed in the next major release that will be available in a couple of months.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The Intel Fortran Composer XE 2011 initial release (12.0.0.084 - Linux) with the fix is available from the Intel Registration Center: https://registrationcenter.intel.com
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