mdolab / pyspline

pySpline produces B-spline curves, surfaces, and volumes
Other
39 stars 26 forks source link

Fixed GCC10 + F2008 compliance #27

Closed ewu63 closed 3 years ago

ewu63 commented 3 years ago

Purpose

I added the -std=f2003 flag and fixed all the errors that came up. Since I'm on GCC 10, I also fixed the argument mismatch issue.

Note that some warnings still remain:

parameterizations.f90:38:61:

                       (X(3, K, J, I) - X(3, K, J, I-1)) ** 2)
                                                             1
Warning: Obsolescent feature: Statement function at (1)

As part of the process, I removed the norm function definition and replaced it by the F2008 intrinsic NORM2. I also replaced one scalar call to norm with the ABS function which is equivalent for scalars.

Type of change

What types of change is it? Select the appropriate type(s) that describe this PR

Testing

I updated the config file so the -std=f95 code will be tested, but since we are on GCC 9 I guess we should just observe that the argument mismatch warnings should no longer show up in the compile log.

Checklist

Put an x in the boxes that apply.

ewu63 commented 3 years ago

Okay I updated the following

There are other things that can be replaced by intrinsics, such as the dotproduct subroutine, but maybe we should save that for later. A lot of our codes can be modernized though.

bernardopacini commented 3 years ago

These new updates look good to me, but I want to wait for @eirikurj's approval before merging.