MetOffice / MetOffice/Vernier

Add check to make sure Fortran compiler is 2018 compatible

Open
#261 0 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
C++
Stars
6
Forks
11
Avg merge
18h 7m
Merged PRs (30d)
1

Description

### Contact Details

_No response_

### Are there any linked Issues or Pull Requests?

_No response_

### Brief description

There are a couple instances where we use optional arguments in the Fortran API, this requires that the optional argument when not used be passed as a null pointer to the C layer which is Fortran 2018 functionality. As such we should have a check in the build system to make sure the Fortran compiler is both F2018 compatible and is running at that standard.

### Further details of the issue.

Usually in CMake you can set a variable to enforce language standards, this however is not available for Fortran and so will need a hand rolled implementation. See [CMAKE__STANDARD](https://cmake.org/cmake/help/latest/variable/CMAKE_LANG_STANDARD.html#variable:CMAKE_%3CLANG%3E_STANDARD)

Contributor guide

Open the contributing guide

Research direction

Start by inspecting the CMake build configuration and the Fortran API uses of optional arguments; compare the desired behavior with CMAKE__STANDARD documentation. The check is complete when the build verifies that the Fortran compiler supports and is invoked with Fortran 2018.

Written by the indexing model from the issue text.

Assessment

Tech stack
cmake, fortran
Domain
build-system
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
64/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.