Files
modeling-app/rust/kcl-lib/tests/import_transform/ast.snap

288 lines
8.1 KiB
Plaintext
Raw Normal View History

---
source: kcl-lib/src/simulation_tests.rs
description: Result of parsing import_transform.kcl
---
{
"Ok": {
"body": [
{
"end": 0,
"path": {
"type": "Foreign",
"path": "2-5-long-m8-chc-screw.stl"
},
"selector": {
"type": "None",
"alias": {
"end": 0,
"name": "screw",
"start": 0,
"type": "Identifier"
}
},
"start": 0,
"type": "ImportStatement",
"type": "ImportStatement"
},
{
"end": 0,
"expression": {
"body": [
{
"end": 0,
"name": "screw",
"start": 0,
"type": "Identifier",
"type": "Identifier"
},
{
"arguments": [
{
"type": "LabeledArg",
"label": {
"end": 0,
"name": "roll",
"start": 0,
"type": "Identifier"
},
"arg": {
"end": 0,
"raw": "3.14",
"start": 0,
"type": "Literal",
"type": "Literal",
"value": {
"value": 3.14,
"suffix": "None"
}
}
},
{
"type": "LabeledArg",
"label": {
"end": 0,
"name": "pitch",
"start": 0,
"type": "Identifier"
},
"arg": {
"end": 0,
"raw": "3.14",
"start": 0,
"type": "Literal",
"type": "Literal",
"value": {
"value": 3.14,
"suffix": "None"
}
}
},
{
"type": "LabeledArg",
"label": {
"end": 0,
"name": "yaw",
"start": 0,
"type": "Identifier"
},
"arg": {
"end": 0,
"raw": "3.14",
"start": 0,
"type": "Literal",
"type": "Literal",
"value": {
"value": 3.14,
"suffix": "None"
}
}
}
],
"callee": {
"end": 0,
"name": "rotate",
"start": 0,
"type": "Identifier"
},
"end": 0,
"start": 0,
"type": "CallExpressionKw",
"type": "CallExpressionKw",
"unlabeled": {
"end": 0,
"start": 0,
"type": "PipeSubstitution",
"type": "PipeSubstitution"
}
},
{
"arguments": [
{
"type": "LabeledArg",
"label": {
"end": 0,
"name": "translate",
"start": 0,
"type": "Identifier"
},
"arg": {
"elements": [
{
"end": 0,
"raw": "3.14",
"start": 0,
"type": "Literal",
"type": "Literal",
"value": {
"value": 3.14,
"suffix": "None"
}
},
{
"end": 0,
"raw": "3.14",
"start": 0,
"type": "Literal",
"type": "Literal",
"value": {
"value": 3.14,
"suffix": "None"
}
},
{
"end": 0,
"raw": "3.14",
"start": 0,
"type": "Literal",
"type": "Literal",
"value": {
"value": 3.14,
"suffix": "None"
}
}
],
"end": 0,
"start": 0,
"type": "ArrayExpression",
"type": "ArrayExpression"
}
}
],
"callee": {
"end": 0,
"name": "translate",
"start": 0,
"type": "Identifier"
},
"end": 0,
"start": 0,
"type": "CallExpressionKw",
"type": "CallExpressionKw",
"unlabeled": {
"end": 0,
"start": 0,
"type": "PipeSubstitution",
"type": "PipeSubstitution"
}
},
{
"arguments": [
{
"type": "LabeledArg",
"label": {
"end": 0,
"name": "scale",
"start": 0,
"type": "Identifier"
},
"arg": {
"elements": [
{
"end": 0,
"raw": "3.14",
"start": 0,
"type": "Literal",
"type": "Literal",
"value": {
"value": 3.14,
"suffix": "None"
}
},
{
"end": 0,
"raw": "3.14",
"start": 0,
"type": "Literal",
"type": "Literal",
"value": {
"value": 3.14,
"suffix": "None"
}
},
{
"end": 0,
"raw": "3.14",
"start": 0,
"type": "Literal",
"type": "Literal",
"value": {
"value": 3.14,
"suffix": "None"
}
}
],
"end": 0,
"start": 0,
"type": "ArrayExpression",
"type": "ArrayExpression"
}
}
],
"callee": {
"end": 0,
"name": "scale",
"start": 0,
"type": "Identifier"
},
"end": 0,
"start": 0,
"type": "CallExpressionKw",
"type": "CallExpressionKw",
"unlabeled": {
"end": 0,
"start": 0,
"type": "PipeSubstitution",
"type": "PipeSubstitution"
}
}
],
"end": 0,
"start": 0,
"type": "PipeExpression",
"type": "PipeExpression"
},
"start": 0,
"type": "ExpressionStatement",
"type": "ExpressionStatement"
}
],
"end": 0,
"nonCodeMeta": {
"nonCodeNodes": {
"0": [
{
"end": 0,
"start": 0,
"type": "NonCodeNode",
"value": {
"type": "newLine"
}
}
]
},
"startNodes": []
},
"start": 0
}
}