--- a/plcopen/structures.py Wed Aug 27 13:33:08 2008 +0200
+++ b/plcopen/structures.py Wed Aug 27 16:55:16 2008 +0200
@@ -63,12 +63,7 @@
if body_type == "FBD" or body_type == "SFC":
value = generator.ComputeFBDExpression(body, connections[0], executionOrderId > 0)
elif body_type == "LD":
- paths = generator.GenerateLDPaths(variable.connectionPointIn.getConnections(), body)
- if len(paths) > 0:
- paths = tuple(paths)
- else:
- paths = paths[0]
- value = generator.ComputeLDExpression(paths, True)
+ value = generator.ComputeLDExpression(body, variable.connectionPointIn.getConnections())
vars.append(generator.ExtractModifier(variable, value, input_info))
generator.Program += [(generator.CurrentIndent, ()),
(output_name, output_info),
@@ -90,12 +85,7 @@
if body_type == "FBD" or body_type == "SFC":
value = generator.ComputeFBDExpression(body, connections[0], executionOrderId > 0)
elif body_type == "LD":
- paths = generator.GenerateLDPaths(variable.connectionPointIn.getconnections(), body)
- if len(paths) > 0:
- paths = tuple(paths)
- else:
- paths = paths[0]
- value = generator.ComputeLDExpression(paths, True)
+ value = generator.ComputeLDExpression(body, variable.connectionPointIn.getconnections())
vars.append([(parameter, input_info),
(" := ", ())] + generator.ExtractModifier(variable, value, input_info))
generator.Program += [(generator.CurrentIndent, ()),