PURE Functions
PURE functions have no side effects
HPF ensures this by syntactic constraints:
- Globals cannot be used in any context that may cause the variable to become defined
- LHS of assignment, DO index, ALLOCATE
- Targets of pointer assignments (due to later misuse)
- Full list of restrictions is too long to fit on this slide!
- No external I/O or file operations
- No data remapping by HPF directives