tests: update with reordered argument typing
This commit is contained in:
@@ -4,7 +4,35 @@
|
|||||||
"type": "Warning",
|
"type": "Warning",
|
||||||
"location": {
|
"location": {
|
||||||
"start": [
|
"start": [
|
||||||
6,
|
8,
|
||||||
|
12
|
||||||
|
],
|
||||||
|
"end": [
|
||||||
|
8,
|
||||||
|
43
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"message": "ConstraintType not yet supported"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "Warning",
|
||||||
|
"location": {
|
||||||
|
"start": [
|
||||||
|
10,
|
||||||
|
10
|
||||||
|
],
|
||||||
|
"end": [
|
||||||
|
10,
|
||||||
|
18
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"message": "Unknown type 'datetime'"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "Warning",
|
||||||
|
"location": {
|
||||||
|
"start": [
|
||||||
|
13,
|
||||||
4
|
4
|
||||||
],
|
],
|
||||||
"end": [
|
"end": [
|
||||||
@@ -12,7 +40,7 @@
|
|||||||
5
|
5
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"message": "FrameType not yet supported"
|
"message": "Unknown type '_'"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"judgments": []
|
"judgments": []
|
||||||
|
|||||||
@@ -328,6 +328,19 @@
|
|||||||
},
|
},
|
||||||
"type": {}
|
"type": {}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L6:9",
|
||||||
|
"to": "L6:10"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 1
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L6:5",
|
"from": "L6:5",
|
||||||
@@ -373,19 +386,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L6:9",
|
|
||||||
"to": "L6:10"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 1
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L6:5",
|
"from": "L6:5",
|
||||||
@@ -407,6 +407,32 @@
|
|||||||
},
|
},
|
||||||
"type": {}
|
"type": {}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L7:9",
|
||||||
|
"to": "L7:10"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 1
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L7:12",
|
||||||
|
"to": "L7:15"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 2.0
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L7:5",
|
"from": "L7:5",
|
||||||
@@ -452,32 +478,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L7:9",
|
|
||||||
"to": "L7:10"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 1
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L7:12",
|
|
||||||
"to": "L7:15"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 2.0
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L7:5",
|
"from": "L7:5",
|
||||||
@@ -503,6 +503,32 @@
|
|||||||
},
|
},
|
||||||
"type": {}
|
"type": {}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L8:9",
|
||||||
|
"to": "L8:10"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 1
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L8:14",
|
||||||
|
"to": "L8:17"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 2.0
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L8:5",
|
"from": "L8:5",
|
||||||
@@ -548,32 +574,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L8:9",
|
|
||||||
"to": "L8:10"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 1
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L8:14",
|
|
||||||
"to": "L8:17"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 2.0
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L8:5",
|
"from": "L8:5",
|
||||||
@@ -600,6 +600,45 @@
|
|||||||
},
|
},
|
||||||
"type": {}
|
"type": {}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L9:9",
|
||||||
|
"to": "L9:10"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 1
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L9:12",
|
||||||
|
"to": "L9:15"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 2.0
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L9:17",
|
||||||
|
"to": "L9:23"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": "test"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "str"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L9:5",
|
"from": "L9:5",
|
||||||
@@ -645,45 +684,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L9:9",
|
|
||||||
"to": "L9:10"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 1
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L9:12",
|
|
||||||
"to": "L9:15"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 2.0
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L9:17",
|
|
||||||
"to": "L9:23"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": "test"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "str"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L9:5",
|
"from": "L9:5",
|
||||||
@@ -713,6 +713,45 @@
|
|||||||
},
|
},
|
||||||
"type": {}
|
"type": {}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L10:9",
|
||||||
|
"to": "L10:10"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 1
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L10:12",
|
||||||
|
"to": "L10:15"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 2.0
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L10:19",
|
||||||
|
"to": "L10:22"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 3.0
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L10:5",
|
"from": "L10:5",
|
||||||
@@ -758,45 +797,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L10:9",
|
|
||||||
"to": "L10:10"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 1
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L10:12",
|
|
||||||
"to": "L10:15"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 2.0
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L10:19",
|
|
||||||
"to": "L10:22"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 3.0
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L10:5",
|
"from": "L10:5",
|
||||||
@@ -827,6 +827,19 @@
|
|||||||
},
|
},
|
||||||
"type": {}
|
"type": {}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L11:11",
|
||||||
|
"to": "L11:12"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 1
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L11:5",
|
"from": "L11:5",
|
||||||
@@ -872,19 +885,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L11:11",
|
|
||||||
"to": "L11:12"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 1
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L11:5",
|
"from": "L11:5",
|
||||||
@@ -906,6 +906,19 @@
|
|||||||
},
|
},
|
||||||
"type": {}
|
"type": {}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L12:11",
|
||||||
|
"to": "L12:17"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": "test"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "str"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L12:5",
|
"from": "L12:5",
|
||||||
@@ -951,19 +964,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L12:11",
|
|
||||||
"to": "L12:17"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": "test"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "str"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L12:5",
|
"from": "L12:5",
|
||||||
@@ -985,6 +985,45 @@
|
|||||||
},
|
},
|
||||||
"type": {}
|
"type": {}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L14:10",
|
||||||
|
"to": "L14:11"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 1
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L14:13",
|
||||||
|
"to": "L14:16"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 2.0
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L14:20",
|
||||||
|
"to": "L14:26"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": "test"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "str"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L14:6",
|
"from": "L14:6",
|
||||||
@@ -1030,45 +1069,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L14:10",
|
|
||||||
"to": "L14:11"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 1
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L14:13",
|
|
||||||
"to": "L14:16"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 2.0
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L14:20",
|
|
||||||
"to": "L14:26"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": "test"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "str"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L14:6",
|
"from": "L14:6",
|
||||||
@@ -1101,6 +1101,45 @@
|
|||||||
"name": "bool"
|
"name": "bool"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L15:10",
|
||||||
|
"to": "L15:11"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 1
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L15:15",
|
||||||
|
"to": "L15:18"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 2.0
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L15:22",
|
||||||
|
"to": "L15:28"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": "test"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "str"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L15:6",
|
"from": "L15:6",
|
||||||
@@ -1146,45 +1185,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L15:10",
|
|
||||||
"to": "L15:11"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 1
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L15:15",
|
|
||||||
"to": "L15:18"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 2.0
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L15:22",
|
|
||||||
"to": "L15:28"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": "test"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "str"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L15:6",
|
"from": "L15:6",
|
||||||
@@ -1217,6 +1217,45 @@
|
|||||||
"name": "bool"
|
"name": "bool"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L16:10",
|
||||||
|
"to": "L16:11"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 1
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L16:15",
|
||||||
|
"to": "L16:21"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": "test"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "str"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L16:25",
|
||||||
|
"to": "L16:28"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 2.0
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L16:6",
|
"from": "L16:6",
|
||||||
@@ -1262,45 +1301,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L16:10",
|
|
||||||
"to": "L16:11"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 1
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L16:15",
|
|
||||||
"to": "L16:21"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": "test"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "str"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L16:25",
|
|
||||||
"to": "L16:28"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 2.0
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L16:6",
|
"from": "L16:6",
|
||||||
@@ -1333,6 +1333,45 @@
|
|||||||
"name": "bool"
|
"name": "bool"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L18:10",
|
||||||
|
"to": "L18:13"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": "a"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "str"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L18:15",
|
||||||
|
"to": "L18:16"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": 3
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L18:20",
|
||||||
|
"to": "L18:25"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "LiteralExpr",
|
||||||
|
"value": false
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "bool"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L18:6",
|
"from": "L18:6",
|
||||||
@@ -1378,45 +1417,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L18:10",
|
|
||||||
"to": "L18:13"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": "a"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "str"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L18:15",
|
|
||||||
"to": "L18:16"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": 3
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L18:20",
|
|
||||||
"to": "L18:25"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "LiteralExpr",
|
|
||||||
"value": false
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "bool"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L18:6",
|
"from": "L18:6",
|
||||||
|
|||||||
@@ -100,6 +100,32 @@
|
|||||||
"name": "float"
|
"name": "float"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L11:13",
|
||||||
|
"to": "L11:15"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "VariableExpr",
|
||||||
|
"name": "v1"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L11:17",
|
||||||
|
"to": "L11:19"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "VariableExpr",
|
||||||
|
"name": "v2"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L11:5",
|
"from": "L11:5",
|
||||||
@@ -135,32 +161,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L11:13",
|
|
||||||
"to": "L11:15"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "VariableExpr",
|
|
||||||
"name": "v1"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L11:17",
|
|
||||||
"to": "L11:19"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "VariableExpr",
|
|
||||||
"name": "v2"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L11:5",
|
"from": "L11:5",
|
||||||
|
|||||||
@@ -72,29 +72,6 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"judgments": [
|
"judgments": [
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L26:0",
|
|
||||||
"to": "L26:5"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "VariableExpr",
|
|
||||||
"name": "print"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"pos_args": [
|
|
||||||
{
|
|
||||||
"pos": 0,
|
|
||||||
"name": "object",
|
|
||||||
"type": {},
|
|
||||||
"required": true
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"args": [],
|
|
||||||
"kw_args": [],
|
|
||||||
"returns": {}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L27:4",
|
"from": "L27:4",
|
||||||
@@ -325,6 +302,29 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L26:0",
|
||||||
|
"to": "L26:5"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "VariableExpr",
|
||||||
|
"name": "print"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"pos_args": [
|
||||||
|
{
|
||||||
|
"pos": 0,
|
||||||
|
"name": "object",
|
||||||
|
"type": {},
|
||||||
|
"required": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"args": [],
|
||||||
|
"kw_args": [],
|
||||||
|
"returns": {}
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L26:0",
|
"from": "L26:0",
|
||||||
|
|||||||
@@ -63,31 +63,6 @@
|
|||||||
"name": "float"
|
"name": "float"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L6:11",
|
|
||||||
"to": "L6:15"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "VariableExpr",
|
|
||||||
"name": "bool"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"pos_args": [
|
|
||||||
{
|
|
||||||
"pos": 0,
|
|
||||||
"name": "object",
|
|
||||||
"type": {},
|
|
||||||
"required": false
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"args": [],
|
|
||||||
"kw_args": [],
|
|
||||||
"returns": {
|
|
||||||
"name": "bool"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L6:16",
|
"from": "L6:16",
|
||||||
@@ -135,6 +110,31 @@
|
|||||||
"name": "int"
|
"name": "int"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L6:11",
|
||||||
|
"to": "L6:15"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "VariableExpr",
|
||||||
|
"name": "bool"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"pos_args": [
|
||||||
|
{
|
||||||
|
"pos": 0,
|
||||||
|
"name": "object",
|
||||||
|
"type": {},
|
||||||
|
"required": false
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"args": [],
|
||||||
|
"kw_args": [],
|
||||||
|
"returns": {
|
||||||
|
"name": "bool"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L6:11",
|
"from": "L6:11",
|
||||||
@@ -367,6 +367,54 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L12:21",
|
||||||
|
"to": "L12:27"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "VariableExpr",
|
||||||
|
"name": "double"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"pos_args": [],
|
||||||
|
"args": [
|
||||||
|
{
|
||||||
|
"pos": 0,
|
||||||
|
"name": "value",
|
||||||
|
"type": {
|
||||||
|
"name": "float"
|
||||||
|
},
|
||||||
|
"required": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"kw_args": [],
|
||||||
|
"returns": {
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L12:29",
|
||||||
|
"to": "L12:35"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "VariableExpr",
|
||||||
|
"name": "floats"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "list",
|
||||||
|
"args": [
|
||||||
|
{
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"body": {
|
||||||
|
"name": "list"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L12:17",
|
"from": "L12:17",
|
||||||
@@ -455,54 +503,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L12:21",
|
|
||||||
"to": "L12:27"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "VariableExpr",
|
|
||||||
"name": "double"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"pos_args": [],
|
|
||||||
"args": [
|
|
||||||
{
|
|
||||||
"pos": 0,
|
|
||||||
"name": "value",
|
|
||||||
"type": {
|
|
||||||
"name": "float"
|
|
||||||
},
|
|
||||||
"required": true
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"kw_args": [],
|
|
||||||
"returns": {
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L12:29",
|
|
||||||
"to": "L12:35"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "VariableExpr",
|
|
||||||
"name": "floats"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "list",
|
|
||||||
"args": [
|
|
||||||
{
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"body": {
|
|
||||||
"name": "list"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L12:17",
|
"from": "L12:17",
|
||||||
@@ -538,6 +538,54 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L13:19",
|
||||||
|
"to": "L13:25"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "VariableExpr",
|
||||||
|
"name": "double"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"pos_args": [],
|
||||||
|
"args": [
|
||||||
|
{
|
||||||
|
"pos": 0,
|
||||||
|
"name": "value",
|
||||||
|
"type": {
|
||||||
|
"name": "float"
|
||||||
|
},
|
||||||
|
"required": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"kw_args": [],
|
||||||
|
"returns": {
|
||||||
|
"name": "float"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L13:27",
|
||||||
|
"to": "L13:31"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "VariableExpr",
|
||||||
|
"name": "ints"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "list",
|
||||||
|
"args": [
|
||||||
|
{
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"body": {
|
||||||
|
"name": "list"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L13:15",
|
"from": "L13:15",
|
||||||
@@ -626,54 +674,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L13:19",
|
|
||||||
"to": "L13:25"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "VariableExpr",
|
|
||||||
"name": "double"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"pos_args": [],
|
|
||||||
"args": [
|
|
||||||
{
|
|
||||||
"pos": 0,
|
|
||||||
"name": "value",
|
|
||||||
"type": {
|
|
||||||
"name": "float"
|
|
||||||
},
|
|
||||||
"required": true
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"kw_args": [],
|
|
||||||
"returns": {
|
|
||||||
"name": "float"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L13:27",
|
|
||||||
"to": "L13:31"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "VariableExpr",
|
|
||||||
"name": "ints"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "list",
|
|
||||||
"args": [
|
|
||||||
{
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"body": {
|
|
||||||
"name": "list"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L13:15",
|
"from": "L13:15",
|
||||||
@@ -699,6 +699,54 @@
|
|||||||
},
|
},
|
||||||
"type": {}
|
"type": {}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L14:15",
|
||||||
|
"to": "L14:21"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "VariableExpr",
|
||||||
|
"name": "is_odd"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"pos_args": [],
|
||||||
|
"args": [
|
||||||
|
{
|
||||||
|
"pos": 0,
|
||||||
|
"name": "value",
|
||||||
|
"type": {
|
||||||
|
"name": "int"
|
||||||
|
},
|
||||||
|
"required": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"kw_args": [],
|
||||||
|
"returns": {
|
||||||
|
"name": "bool"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"location": {
|
||||||
|
"from": "L14:23",
|
||||||
|
"to": "L14:27"
|
||||||
|
},
|
||||||
|
"expr": {
|
||||||
|
"_type": "VariableExpr",
|
||||||
|
"name": "ints"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"name": "list",
|
||||||
|
"args": [
|
||||||
|
{
|
||||||
|
"name": "int"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"body": {
|
||||||
|
"name": "list"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L14:11",
|
"from": "L14:11",
|
||||||
@@ -787,54 +835,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L14:15",
|
|
||||||
"to": "L14:21"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "VariableExpr",
|
|
||||||
"name": "is_odd"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"pos_args": [],
|
|
||||||
"args": [
|
|
||||||
{
|
|
||||||
"pos": 0,
|
|
||||||
"name": "value",
|
|
||||||
"type": {
|
|
||||||
"name": "int"
|
|
||||||
},
|
|
||||||
"required": true
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"kw_args": [],
|
|
||||||
"returns": {
|
|
||||||
"name": "bool"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"location": {
|
|
||||||
"from": "L14:23",
|
|
||||||
"to": "L14:27"
|
|
||||||
},
|
|
||||||
"expr": {
|
|
||||||
"_type": "VariableExpr",
|
|
||||||
"name": "ints"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"name": "list",
|
|
||||||
"args": [
|
|
||||||
{
|
|
||||||
"name": "int"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"body": {
|
|
||||||
"name": "list"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"location": {
|
"location": {
|
||||||
"from": "L14:11",
|
"from": "L14:11",
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ from midas.ast.midas import (
|
|||||||
Expr,
|
Expr,
|
||||||
ExtendStmt,
|
ExtendStmt,
|
||||||
ExtensionType,
|
ExtensionType,
|
||||||
|
FrameType,
|
||||||
FunctionType,
|
FunctionType,
|
||||||
GenericType,
|
GenericType,
|
||||||
GetExpr,
|
GetExpr,
|
||||||
@@ -197,3 +198,15 @@ class MidasAstJsonSerializer(
|
|||||||
"base": type.base.accept(self),
|
"base": type.base.accept(self),
|
||||||
"extension": type.extension.accept(self),
|
"extension": type.extension.accept(self),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
def visit_frame_type(self, type: FrameType) -> dict:
|
||||||
|
return {
|
||||||
|
"_type": "FrameType",
|
||||||
|
"columns": [self._serialize_column(col) for col in type.columns],
|
||||||
|
}
|
||||||
|
|
||||||
|
def _serialize_column(self, column: FrameType.Column):
|
||||||
|
return {
|
||||||
|
"name": column.name.lexeme,
|
||||||
|
"type": column.type.accept(self),
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user