Skip to content
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

Missing Lahey intrinsics #2

Open
Huite opened this issue Jul 19, 2024 · 1 comment
Open

Missing Lahey intrinsics #2

Huite opened this issue Jul 19, 2024 · 1 comment

Comments

@Huite
Copy link
Collaborator

Huite commented Jul 19, 2024

The following ones seem like they need to be replaced:

  • nblank to find the number of non-blanks (?),
  • iostat_msg to print a meaningful IO error
  • timer to measure execution times
  • getcl to get command line arguments
Error: Function 'nblank' at (1) has no IMPLICIT type
../src/Gfmod.for:1323:5:

It seems like nblank isn't defined. From context, I'm guessing it might be replaced by something like:

      DO NCHA = 1, LEN(ACLINE)
        IF(ACLINE(NCHA:NCHA)==" ") EXIT 
      END DO
      NCHA = NCHA - 1

      ...

      DO NCHA = 1, LEN(AFILE2)
        IF(AFILE2(NCHA:NCHA).EQ." ") EXIT
      END DO
      NCHA = NCHA - 1
@Huite Huite changed the title Error: Function 'nblank' at (1) has no IMPLICIT type Missing Lahey intrinsics Jul 22, 2024
@Huite
Copy link
Collaborator Author

Huite commented Jul 31, 2024

nblank is len_trim
timer is either CPU_TIME or SYSTEM_TIME (later is probably better)
getcl is getarg(1, ...)

iostat_msg is hardest to replace, since there's no fortran standard apparently, although different compilers do provide their own functions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant