From 6860ed8c65f648d68cbcb65e9ac6013f643bdeef Mon Sep 17 00:00:00 2001 From: Francis Russell Date: Thu, 7 Jun 2012 19:45:41 +0100 Subject: [PATCH] Generate 'use' statements for subroutine calls. --- src/ofc/codegen/FortranGenerator.scala | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/ofc/codegen/FortranGenerator.scala b/src/ofc/codegen/FortranGenerator.scala index 42e7379..dbf02cc 100644 --- a/src/ofc/codegen/FortranGenerator.scala +++ b/src/ofc/codegen/FortranGenerator.scala @@ -213,7 +213,10 @@ class FortranGenerator { case (i : IfStatement) => processIf(i) case (a : AllocateStatement) => processAllocate(a) case (d : DeallocateStatement) => processDeallocate(d) - case (f : FunctionCallStatement) => processFunctionCallStatement(f) + case (f : FunctionCallStatement) => { + symbolManager.addSymbol(f.getCall.getSignature) + processFunctionCallStatement(f) + } case x => throw new UnimplementedException("Unknown statement type in FORTRAN generator: " + x.toString) } } -- 2.47.3