This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/51913] New: bug when submitting a class pointer to a subroutine
- From: "nagl46 at web dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 20 Jan 2012 09:35:44 +0000
- Subject: [Bug fortran/51913] New: bug when submitting a class pointer to a subroutine
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51913
Bug #: 51913
Summary: bug when submitting a class pointer to a subroutine
Classification: Unclassified
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Severity: major
Priority: P3
Component: fortran
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: nagl46@web.de
Created attachment 26390
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=26390
buggy program
When I declare a pointer in main routine:
>> CLASS(sparseMatrix_t), pointer :: sparseMatrix
Then I pass this pointer to a subroutine
>> call test(sparseMatrix)
I get a compiler error message:
>> Error: Actual argument to 'matrix' at (1) must have the same declared type
Please find attached a small program that does not work and fails compiling
with this error. I find this fault in gfortran-4.6.1 and gfortran-4.7.0
20111210.
I compiled with 'gfortran main.f90'.