diff --git a/cp0.json b/cp0.json index c923551..59ee75d 100644 --- a/cp0.json +++ b/cp0.json @@ -1354,7 +1354,25 @@ ] }, "value_flow": { - "doc_stack": "x_1 ... x_n - t" + "doc_stack": "x_1 ... x_n - t", + "inputs": { + "stack": [ + { + "type": "tuple", + "name": "x", + "length_var": "n" + } + ] + }, + "outputs": { + "stack": [ + { + "type": "simple", + "name": "t", + "value_types": ["Tuple"] + } + ] + } } }, { @@ -1423,7 +1441,25 @@ ] }, "value_flow": { - "doc_stack": "t - x_1 ... x_n" + "doc_stack": "t - x_1 ... x_n", + "inputs": { + "stack": [ + { + "type": "simple", + "name": "t", + "value_types": ["Tuple"] + } + ] + }, + "outputs": { + "stack": [ + { + "type": "tuple", + "name": "x", + "length_var": "n" + } + ] + } } }, { @@ -1449,7 +1485,25 @@ ] }, "value_flow": { - "doc_stack": "t - x_1 ... x_k" + "doc_stack": "t - x_1 ... x_k", + "inputs": { + "stack": [ + { + "type": "simple", + "name": "t", + "value_types": ["Tuple"] + } + ] + }, + "outputs": { + "stack": [ + { + "type": "tuple", + "name": "x", + "length_var": "k" + } + ] + } } }, { @@ -1475,7 +1529,30 @@ ] }, "value_flow": { - "doc_stack": "t - x_1 ... x_m m" + "doc_stack": "t - x_1 ... x_m m", + "inputs": { + "stack": [ + { + "type": "simple", + "name": "t", + "value_types": ["Tuple"] + } + ] + }, + "outputs": { + "stack": [ + { + "type": "tuple", + "name": "x", + "length_var": "m" + }, + { + "type": "simple", + "name": "m", + "value_types": ["Integer"] + } + ] + } } }, { @@ -1632,7 +1709,30 @@ "operands": [] }, "value_flow": { - "doc_stack": "x_1 ... x_n n - t" + "doc_stack": "x_1 ... x_n n - t", + "inputs": { + "stack": [ + { + "type": "tuple", + "name": "x", + "length_var": "n" + }, + { + "type": "simple", + "name": "n", + "value_types": ["Integer"] + } + ] + }, + "outputs": { + "stack": [ + { + "type": "simple", + "name": "t", + "value_types": ["Tuple"] + } + ] + } } }, { @@ -1690,7 +1790,30 @@ "operands": [] }, "value_flow": { - "doc_stack": "t n - x_1 ... x_n" + "doc_stack": "t n - x_1 ... x_n", + "inputs": { + "stack": [ + { + "type": "simple", + "name": "t", + "value_types": ["Tuple"] + }, + { + "type": "simple", + "name": "n", + "value_types": ["Integer"] + } + ] + }, + "outputs": { + "stack": [ + { + "type": "tuple", + "name": "x", + "length_var": "n" + } + ] + } } }, { @@ -1708,7 +1831,30 @@ "operands": [] }, "value_flow": { - "doc_stack": "t n - x_1 ... x_n" + "doc_stack": "t n - x_1 ... x_n", + "inputs": { + "stack": [ + { + "type": "simple", + "name": "t", + "value_types": ["Tuple"] + }, + { + "type": "simple", + "name": "n", + "value_types": ["Integer"] + } + ] + }, + "outputs": { + "stack": [ + { + "type": "tuple", + "name": "x", + "length_var": "n" + } + ] + } } }, { @@ -1726,7 +1872,35 @@ "operands": [] }, "value_flow": { - "doc_stack": "t n - x_1 ... x_m m" + "doc_stack": "t n - x_1 ... x_m m", + "inputs": { + "stack": [ + { + "type": "simple", + "name": "t", + "value_types": ["Tuple"] + }, + { + "type": "simple", + "name": "n", + "value_types": ["Integer"] + } + ] + }, + "outputs": { + "stack": [ + { + "type": "tuple", + "name": "x", + "length_var": "m" + }, + { + "type": "simple", + "name": "m", + "value_types": ["Integer"] + } + ] + } } }, { diff --git a/schema.json b/schema.json index ce97d51..f47f9a8 100644 --- a/schema.json +++ b/schema.json @@ -171,6 +171,24 @@ "$ref": "#/definitions/stack" } } + }, + { + "type": "object", + "additionalProperties": false, + "required": ["type", "name", "length_var"], + "properties": { + "type": { + "const": "tuple" + }, + "name": { + "name": "Variable name", + "type": "string" + }, + "length_var": { + "name": "Variable which contains tuple length", + "type": "string" + } + } } ] },