|
@@ -11,7 +11,10 @@ Class main {
|
|
|
constructor_body = $
|
|
|
Void function const(attributes : Element, parameters : Element):
|
|
|
dict_overwrite(attributes, "a", 0)
|
|
|
- dict_overwrite(attributes, "id", 0)
|
|
|
+ if (element_eq(parameters, read_root())):
|
|
|
+ dict_overwrite(attributes, "id", 0)
|
|
|
+ else:
|
|
|
+ dict_overwrite(attributes, "id", parameters)
|
|
|
return !
|
|
|
$
|
|
|
}
|
|
@@ -113,7 +116,7 @@ transition (x_a, x_b) {
|
|
|
Void function script(attributes : Element, evt_param : Element):
|
|
|
log("In script")
|
|
|
dict_overwrite(attributes, "a", 1)
|
|
|
- dict_overwrite(attributes, "b", 2)
|
|
|
+ dict_overwrite(attributes, "id", 2)
|
|
|
return!
|
|
|
$
|
|
|
}
|
|
@@ -132,7 +135,7 @@ transition (x_b, x_c) {
|
|
|
cond = $
|
|
|
Boolean function cond(attributes : Element, evt_param : Element):
|
|
|
log("In condition")
|
|
|
- return integer_lt(attributes["a"], attributes["b"])!
|
|
|
+ return integer_lt(attributes["a"], attributes["id"])!
|
|
|
$
|
|
|
}
|
|
|
|
|
@@ -151,8 +154,9 @@ Raise create_new_class {
|
|
|
result = create_node()
|
|
|
list_append(result, "Main")
|
|
|
list_append(result, attributes["id"])
|
|
|
- list_append(result, read_root())
|
|
|
dict_overwrite(attributes, "id", integer_addition(attributes["id"], 1))
|
|
|
+ list_append(result, attributes["id"])
|
|
|
+ return result!
|
|
|
$
|
|
|
}
|
|
|
|