Skip to content

Commit

Permalink
Merge pull request #249 from AgriculturalModelExchangeInitiative/fortran
Browse files Browse the repository at this point in the history
Fix a logical error in FOrtran gen
  • Loading branch information
pradal authored Oct 24, 2024
2 parents 01ef95a + ad80dc0 commit 71e398f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pycropml/transpiler/generators/fortranGenerator.py
Original file line number Diff line number Diff line change
Expand Up @@ -737,7 +737,7 @@ def visit_array_decl(self, node):
if ("feat" not in dir(node)) and (("elts" not in dir(node) or not node.elts or len(node.elts)==0)): # and node.name not in self.parameters :
self.write(", ALLOCATABLE ")
print(node.y)
if("feat" in dir(node) and node.feat=="OUT") and ("elts" in dir(node) or not node.elts or len(node.elts)==0):
if("feat" in dir(node) and node.feat=="OUT") and ("elts" in dir(node) and (not node.elts or len(node.elts)==0)):
self.write(", ALLOCATABLE ")

def visit_float_decl(self, node):
Expand Down

0 comments on commit 71e398f

Please sign in to comment.