replica nfl jerseysreplica nfl jerseyssoccer jerseyreplica nfl jerseys forums.silverfrost.com :: View topic - Bizarre error message
forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Bizarre error message

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Support
View previous topic :: View next topic  
Author Message
colt1954



Joined: 21 Dec 2010
Posts: 81

PostPosted: Thu Mar 06, 2014 3:21 pm    Post subject: Bizarre error message Reply with quote

I have a quite complex Fortran program that I recently decided to add some interim print outputs to see certain calculated values on the screen. I started getting this message 'Attempt to call a routine with four arguments when three were required' from Main program line 313 start of first subroutine call to start of a FFT subroutine at line 919...

Weird I assumed there was some variable assign problem error, so I ended by asking for the most trivial of print outs e.g. print *, 'check message' and it still gave the same error message above so its not a a variable assignment error I don't think, i have even tried this trivial print out before any subroutine still the same errors, and further if I removed the print line the same error occurs...ie I cannot get rid of this error the program falls over...I have a separate unedited source of the original code I don't touch fortunately..
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 8210
Location: Salford, UK

PostPosted: Thu Mar 06, 2014 3:52 pm    Post subject: Reply with quote

This looks like a run time error report generated for example by /CHECK.

Is it a valid error report? Does the code at this point need fixing?

If the error report is false then you can report it as a bug but we will need sample code that demonstrates the false error report.
Back to top
View user's profile Send private message AIM Address
JohnCampbell



Joined: 16 Feb 2006
Posts: 2615
Location: Sydney

PostPosted: Fri Mar 07, 2014 3:34 am    Post subject: Reply with quote

The error report says that on line 313 of the main program, you are calling a routine (which might be called FFT). The compiler has identified that for a call to this routine you have a different argument count to the number of arguments expected, or it is not consistent with other calls to this routine.
I think this is an error report and not a warning, so including print statements will not fix the problem.
Is your code overflowing the available length of the line ? (72 or 132 character limit)
You need to identify which routine is being called and search for all calls and also the actual routine and check the call list. Something is not consistent and you need to fix it.
You could use the Dos FIND command to search all fortran files.
A load map would indicate where the routine that is being loaded is located, which might help if you have multiple copies of the source.
Using /check would also help.

John
Back to top
View user's profile Send private message
colt1954



Joined: 21 Dec 2010
Posts: 81

PostPosted: Fri Mar 07, 2014 1:11 pm    Post subject: Uodate on Bizarre Reply with quote

Really sorry Chaps...I am an idiot, the original source code did have a genuine error so when I re-complied it without changing anything it still reported same error message, so the print output change was a red herring, and so somehow the original source code did not reflect the working compiled version, they had some how got out of sync. Anyway I tracked down the error its was obvious as stated by the actual error message I was passing only three variables when 4 were required...duh

Hope that makes sense....
Back to top
View user's profile Send private message
LitusSaxonicum



Joined: 23 Aug 2005
Posts: 2402
Location: Yateley, Hants, UK

PostPosted: Fri Mar 07, 2014 3:43 pm    Post subject: Reply with quote

The most prolific posters on this forum have all made the same sort of mistake sometime in their programming career.

The thing to learn from it is that FTN95 has the best diagnostics out there, and if it says something is wrong, then you are much better off believing it! The messages are only very occasionally inscrutable, unlike some other compilers, where the messages give numbers that aren't documented, along the lines of "I haven't got a clue what is wrong, but something is", or worse.

Eddie
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Support All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group