From: Francis Russell Date: Thu, 7 Jun 2012 18:45:41 +0000 (+0100) Subject: Generate 'use' statements for subroutine calls. X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=6860ed8c65f648d68cbcb65e9ac6013f643bdeef;p=francis%2Fofc.git Generate 'use' statements for subroutine calls. --- 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) } }