What is a pure function?

Yep. I haven’t quite worked out a convenient/user-friendly way of modelling Monads in Fortran yet, but it’s been rattling around in my head for a bit. I think it might be doable with intent(inout) derived types with type-bound subroutines, but I think the polymorphism in pure/simple procedures is still necessary.

1 Like