- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I made the first steps in Fortran's computation world and get stuck. I want to run a regression tool from webstats.org for some PhD work. I just installed the current Compiler version and put it in a Visual Studio 2005 project.
After trying different compiler settings, I'm down to 2 errors. The 5508 was discussed previously. Though I can't remove it with the description there. After some cleaning steps, it might occur for some other function.
The 7836 error complains about some dummy argument. I don't know how to change its type, it's only dummy? Is there a special compiler option for it?
Thank you very much, Roland
Compiling with Intel Fortran 11.0.066 [IA-32]...
ifort /debug:full /Od /gen-interfaces /fixed /pad_source /f66 /d_lines /intconstant /assume:bscc /warn:none /warn:interfaces /Qauto_scalar /assume:dummy_aliases /names:as_is /module:"Debug\" /object:"Debug\" /traceback /libs:static /threads /dbglibs /c /extfor:f /Qvc8 /Qlocation,link,"C:\app\Microsoft Visual Studio 8\VC\bin" "C:\_Daten\DtTour\AlphaBusinessSol\ProQuaDim\MARS\FriedmanMARS-SAMSI.info2003\Fortran\mars.f"
Intel Visual Fortran Compiler Professional for applications running on IA-32, Version 11.0 Build 20081105 Package ID: w_cprof_p_11.0.066
Copyright (C) 1985-2008 Intel Corporation. All rights reserved.
30 DAY EVALUATION LICENSE
ifort: NOTE: The evaluation period for this product ends on 20-feb-2009 UTC.
C:\_Daten\DtTour\AlphaBusinessSol\ProQuaDim\MARS\FriedmanMARS-SAMSI.info2003\Fortran\mars.f(4476): error #7836: If the actual argument is scalar, the corresponding dummy argument shall be scalar unless the actual argument is an element of an array that is not an assumed-shape or pointer array, or a substring of such an element.
call gtrm(2,jp,l,nt,lv(lp(2,l1)),dum,dum,nk,tb,tc(la),sc(1,nv+1), 3970
-----------^
C:\_Daten\DtTour\AlphaBusinessSol\ProQuaDim\MARS\FriedmanMARS-SAMSI.info2003\Fortran\mars.f(4476): error #7836: If the actual argument is scalar, the corresponding dummy argument shall be scalar unless the actual argument is an element of an array that is not an assumed-shape or pointer array, or a substring of such an element. [fc]
call gtrm(2,jp,l,nt,lv(lp(2,l1)),dum,dum,nk,tb,tc(la),sc(1,nv+1), 3970
-----------^
C:\_Daten\DtTour\AlphaBusinessSol\ProQuaDim\MARS\FriedmanMARS-SAMSI.info2003\Fortran\mars.f(2054): error #5508: Declaration of routine 'cptb' conflicts with a previous declaration
subroutine cptb(nk,tb,ub) 1548
-----------------^
compilation aborted for C:\_Daten\DtTour\AlphaBusinessSol\ProQuaDim\MARS\FriedmanMARS-SAMSI.info2003\Fortran\mars.f (code 1)
MarsInFortran - 4 error(s), 0 warning(s)
After trying different compiler settings, I'm down to 2 errors. The 5508 was discussed previously. Though I can't remove it with the description there. After some cleaning steps, it might occur for some other function.
The 7836 error complains about some dummy argument. I don't know how to change its type, it's only dummy? Is there a special compiler option for it?
Thank you very much, Roland
Compiling with Intel Fortran 11.0.066 [IA-32]...
ifort /debug:full /Od /gen-interfaces /fixed /pad_source /f66 /d_lines /intconstant /assume:bscc /warn:none /warn:interfaces /Qauto_scalar /assume:dummy_aliases /names:as_is /module:"Debug\" /object:"Debug\" /traceback /libs:static /threads /dbglibs /c /extfor:f /Qvc8 /Qlocation,link,"C:\app\Microsoft Visual Studio 8\VC\bin" "C:\_Daten\DtTour\AlphaBusinessSol\ProQuaDim\MARS\FriedmanMARS-SAMSI.info2003\Fortran\mars.f"
Intel Visual Fortran Compiler Professional for applications running on IA-32, Version 11.0 Build 20081105 Package ID: w_cprof_p_11.0.066
Copyright (C) 1985-2008 Intel Corporation. All rights reserved.
30 DAY EVALUATION LICENSE
ifort: NOTE: The evaluation period for this product ends on 20-feb-2009 UTC.
C:\_Daten\DtTour\AlphaBusinessSol\ProQuaDim\MARS\FriedmanMARS-SAMSI.info2003\Fortran\mars.f(4476): error #7836: If the actual argument is scalar, the corresponding dummy argument shall be scalar unless the actual argument is an element of an array that is not an assumed-shape or pointer array, or a substring of such an element.
call gtrm(2,jp,l,nt,lv(lp(2,l1)),dum,dum,nk,tb,tc(la),sc(1,nv+1), 3970
-----------^
C:\_Daten\DtTour\AlphaBusinessSol\ProQuaDim\MARS\FriedmanMARS-SAMSI.info2003\Fortran\mars.f(4476): error #7836: If the actual argument is scalar, the corresponding dummy argument shall be scalar unless the actual argument is an element of an array that is not an assumed-shape or pointer array, or a substring of such an element. [fc]
call gtrm(2,jp,l,nt,lv(lp(2,l1)),dum,dum,nk,tb,tc(la),sc(1,nv+1), 3970
-----------^
C:\_Daten\DtTour\AlphaBusinessSol\ProQuaDim\MARS\FriedmanMARS-SAMSI.info2003\Fortran\mars.f(2054): error #5508: Declaration of routine 'cptb' conflicts with a previous declaration
subroutine cptb(nk,tb,ub) 1548
-----------------^
compilation aborted for C:\_Daten\DtTour\AlphaBusinessSol\ProQuaDim\MARS\FriedmanMARS-SAMSI.info2003\Fortran\mars.f (code 1)
MarsInFortran - 4 error(s), 0 warning(s)
Link Copied
4 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Quoting - rolandneumann
#7836: If the actual argument is scalar, the corresponding dummy argument shall be scalar unless the actual argument is an element of an array that is not an assumed-shape or pointer array, or a substring of such an element. [fc]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Roland
(error 7386)
you need to compare the actual arguments in theCALL GTRM in subroutine mars.f with the dummy arguments in the subroutine gtrm
i.e. the (2, jp, l, nt, etc) are the actual arguments which will be associated with the dummy arguments.
Somewhere in your code you will have
SUBROUTINE GTRM( ... ) where ... is a list of "dummy" arguments one of which is "x" and another is "fc"
These might be declared asarray variableseg REAL X(5) and REAL FC(10) for example, butyou are passing ascalar (in the actual list) wherethearray is expected.
(error 5508)
You appear to have two routines called CPTB with different specifications (dummy arguments list)
Les
(error 7386)
you need to compare the actual arguments in theCALL GTRM in subroutine mars.f with the dummy arguments in the subroutine gtrm
i.e. the (2, jp, l, nt, etc) are the actual arguments which will be associated with the dummy arguments.
Somewhere in your code you will have
SUBROUTINE GTRM( ... ) where ... is a list of "dummy" arguments one of which is "x" and another is "fc"
These might be declared asarray variableseg REAL X(5) and REAL FC(10) for example, butyou are passing ascalar (in the actual list) wherethearray is expected.
(error 5508)
You appear to have two routines called CPTB with different specifications (dummy arguments list)
Les
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you very much for your fast and kind replies. The point for the 5508 is, it is the only declaration of this function in the code. I triple checked it. I even renamed it and ghot the same error with the new name. Sometimes I get the same error for another function name.
The dummy type problem, I hesistate to change this rather complicated part of code since it's not mine. I would prefer to run it first and test all the parameters its functions need before changing. It's meant to run. Would you have an idea which compiler option would disable that check?
Roland
The dummy type problem, I hesistate to change this rather complicated part of code since it's not mine. I would prefer to run it first and test all the parameters its functions need before changing. It's meant to run. Would you have an idea which compiler option would disable that check?
Roland
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Roland
I'm not sure about the error 5508 it's not one I have encountered myself.
The dummy argument problem :I see you are using Fortran v11. I think that by default this has the options
Project->Properties->Fortran->Diagnostics Check Routine Interfaces and Generate Interface Blocks setYES, you could try setting them both to NO.
I had a similar problem where I had a routine which received an array of messages something like :
subroutine logmsg(n,msg)
integer n
character(80) msg
throughout the code there were routines that called the above
character(80) msg
msg = 'hello world'
call logmsg(1,msg)
(as well as calls which had more than one msg to pass)
In those routines which only passed one message I had to change the local definition of msg to
character(80) msg(1)
for it to build
Les

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