new_preprocess_config Subroutine

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


Source Code

   subroutine new_preprocess_config(self, table, error)

      !> Instance of the preprocess configuration
      type(preprocess_config_t), intent(out) :: self

      !> Instance of the TOML data structure.
      type(toml_table), intent(inout) :: table

      !> Error handling
      type(error_t), allocatable, intent(out) :: error

      call check(table, error)
      if (allocated(error)) return

      call table%get_key(self%name)

      call get_list(table, "suffixes", self%suffixes, error)
      if (allocated(error)) return

      call get_list(table, "directories", self%directories, error)
      if (allocated(error)) return

      call get_list(table, "macros", self%macros, error)
      if (allocated(error)) return

   end subroutine new_preprocess_config