-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fparser failing to parse some subroutine formats #420
Comments
Is that second code fragment right? There are no line-continuation symbols so unless they've been stripped-out by the cut-n-paste (somehow) I don't think it's valid Fortran? |
I double checked and that seemed to be what I find. I think you might be correct that this is not technically valid fortran but compilers seem to be ok with it. |
That's really strange. I've never come across that and a google doesn't reveal anything either. Does the Socrates build system do some sort of preprocessing? |
Hmm, perhaps this file isn't used, i explored a little and doing |
Yes, I suggest we ignore it. (In NEMO we keep a list of files to ignore.) I don't know who we ask I'm afraid. Perhaps it's Norman? |
@rupertford I have had a quick look, and I think perhaps it might be to do with Files and the failure in fparser/code:
Where it falls over in fparser:
Estimated cause - the original source is missing line continuation statements - not an fparser bug.
Where it falls over in fparser:
Estimated cause - the original source is missing line continuation statements - not an fparser bug.
Where it falls over in fparser:
Estimated cause - the original source is missing line continuation statements - not an fparser bug.
I think this fails due to a subroutine containing a function inside the included file? I think this file (and its included The failing stack trace is:
Overall then, perhaps there are no fparser bugs here (one could argue the last one? But I couldn't narrow it down really). |
The socrates project appears to have some subroutines which cause fparser to fall over.
A .f file with this subroutine declaration fails:
This is the first code after the initial comments in the file, and fails like this:
I don't believe this is a fixed-format only problem, as there is a non-fixed format f90 file with this subroutine declaration:
Again - the first non-comment line in the file.
This also fails:
The text was updated successfully, but these errors were encountered: