Commit dffc2e01 authored by Maxime Perrotin's avatar Maxime Perrotin
Browse files

Render properly parameterless procedures

Procedures declared without textboxes were not properly rendered, as
reported by GMV
parent ba92837a
......@@ -77,18 +77,19 @@ def _block(ast, scene):
param=('(' + sig['type'].ReferencedTypeName.replace('-', '_') + ')')
if 'type' in sig else '')
for sig in ast.parent.signals]
procedures = ["procedure {proc.inputString};\n{fpar}\nexternal;\n"
procedures = ["procedure {proc.inputString};\n{optfpar}external;\n"
fpar="fpar\n " + u",\n ".join
([u"{direc} {fpar[name]} {asn1}"
optfpar="fpar\n " + u",\n ".join
([u"{direc} {fp[name]} {asn1}"
if fpar['direction']=='in'
else 'in/out',
'ReferencedTypeName', 'TYPE_ERROR')
.replace('-', '_'))
for fpar in proc.fpar]) + ';')
for fpar in proc.fpar]) + ';\n'
if proc.fpar else '')
for proc in ast.parent.procedures]
if signals or procedures:
text_area = ogAST.TextArea()
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment