From: Francis Russell Date: Sun, 20 May 2012 19:27:01 +0000 (+0100) Subject: Place "allocatable" after type in declaration. X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=a6fe476be503407499b465937b80843428ce678a;p=francis%2Fofc.git Place "allocatable" after type in declaration. --- diff --git a/src/ofc/codegen/FortranGenerator.scala b/src/ofc/codegen/FortranGenerator.scala index 09dad75..d1f6bf2 100644 --- a/src/ofc/codegen/FortranGenerator.scala +++ b/src/ofc/codegen/FortranGenerator.scala @@ -48,12 +48,14 @@ class SymbolManager { def getDeclarations : Seq[String] = { for ((sym, info) <- symbols) yield { var attributeStrings : Seq[String] = Nil - attributeStrings ++:= sym.getType.getFortranAttributes + // It seems these properties need to go after the type-related attributes for(property <- sym.getProperties) property match { case (p: FortranProperty) => attributeStrings +:= p.getName case _ => () } + + attributeStrings ++:= sym.getType.getFortranAttributes attributeStrings.mkString(", ") + " :: " + info.getName } }.toSeq.sorted