fpm_manifest_preprocess Module

Implementation of the meta data for preprocessing.

A preprocess table can currently have the following fields

[preprocess]
[preprocess.cpp]
suffixes = ["F90", "f90"]
directories = ["src/feature1", "src/models"]
macros = []


Interfaces

public interface operator(==)

  • private function preprocess_is_same(this, that)

    All checks passed!

    Arguments

    Type IntentOptional Attributes Name
    class(preprocess_config_t), intent(in) :: this
    class(serializable_t), intent(in) :: that

    Return Value logical


Derived Types

type, public, extends(serializable_t) ::  preprocess_config_t

Configuration meta data for a preprocessor

Components

Type Visibility Attributes Name Initial
type(string_t), public, allocatable :: directories(:)

Directories to search for files to be preprocessed

type(string_t), public, allocatable :: macros(:)

Macros to be defined for the preprocessor

character(len=:), public, allocatable :: name

Name of the preprocessor

type(string_t), public, allocatable :: suffixes(:)

Suffixes of the files to be preprocessed

Type-Bound Procedures

procedure, public :: add_config
procedure, public :: destroy ../../

Operations

generic, public :: dump => dump_to_toml, dump_to_file, dump_to_unit
procedure, public :: dump_to_toml
procedure, public :: info ../../

Print information on this instance

procedure, public :: is_cpp ../../

Properties

procedure, public :: is_fypp
generic, public :: load => load_from_toml, load_from_file, load_from_unit
procedure, public :: load_from_toml
generic, public :: operator(==) => serializable_is_same
procedure, public :: serializable_is_same => preprocess_is_same ../../

Serialization interface

procedure, public, non_overridable :: test_serialization ../../

Test load/write roundtrip


Subroutines

public subroutine new_preprocess_config(self, table, error)

Construct a new preprocess configuration from TOML data structure

Arguments

Type IntentOptional Attributes Name
type(preprocess_config_t), intent(out) :: self

Instance of the preprocess configuration

type(toml_table), intent(inout) :: table

Instance of the TOML data structure.

type(error_t), intent(out), allocatable :: error

Error handling

public subroutine new_preprocessors(preprocessors, table, error)

Construct new preprocess array from a TOML data structure.

Arguments

Type IntentOptional Attributes Name
type(preprocess_config_t), intent(out), allocatable :: preprocessors(:)

Instance of the preprocess configuration

type(toml_table), intent(inout) :: table

Instance of the TOML data structure

type(error_t), intent(out), allocatable :: error

Error handling