Fortran-FOSS-Programmers / Fortran-FOSS-Programmers/ford

Issue with preprocessor includes/normal includes

Open
#119 10 comments 0 reactions 0 assignees View on GitHub
enhancement wishlist
Dominant language
Python
Stars
458
Forks
138
PR merge metrics
No merged PRs in 30d

Description

Hi,

Bothering you again with preprocessor things. With these files `foo.F90`:

``` fortran
function A
#include "bar.f90"
```

and `bar.f90`

``` fortran
function B
```

FORD will correctly parse both files via the proprocessor include. However, in the documentation for function B, if I click to view the source, only `foo.F90` is there, with the preprocessor macro unexpanded. Is this the desired output?

If i use `include "bar.f90"` instead of `#include "bar.f90"` the joined file will be shown by FORD.

Related issue: when using MPI I frequenctly need to add a line

``` fortran
include "mpif.h"
```

to the source. This causes FORD to not be very happy. Is there an easy way to add a

``` fortran
include "mpif.h" ! FORD_please_ignore_this
```

or equivalent thing? Sorry about joining questions, but they are sort of the same thing.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.