---
source: kcl-lib/src/simulation_tests.rs
description: Result of parsing car-wheel-assembly.kcl
---
{
  "Ok": {
    "body": [
      {
        "commentStart": 0,
        "end": 0,
        "path": {
          "type": "Kcl",
          "filename": "car-wheel.kcl"
        },
        "preComments": [
          "// Import parts"
        ],
        "selector": {
          "type": "None",
          "alias": {
            "commentStart": 0,
            "end": 0,
            "name": "carWheel",
            "start": 0,
            "type": "Identifier"
          }
        },
        "start": 0,
        "type": "ImportStatement",
        "type": "ImportStatement"
      },
      {
        "commentStart": 0,
        "end": 0,
        "path": {
          "type": "Kcl",
          "filename": "car-rotor.kcl"
        },
        "selector": {
          "type": "None",
          "alias": {
            "commentStart": 0,
            "end": 0,
            "name": "carRotor",
            "start": 0,
            "type": "Identifier"
          }
        },
        "start": 0,
        "type": "ImportStatement",
        "type": "ImportStatement"
      },
      {
        "commentStart": 0,
        "end": 0,
        "path": {
          "type": "Kcl",
          "filename": "brake-caliper.kcl"
        },
        "selector": {
          "type": "None",
          "alias": {
            "commentStart": 0,
            "end": 0,
            "name": "brakeCaliper",
            "start": 0,
            "type": "Identifier"
          }
        },
        "start": 0,
        "type": "ImportStatement",
        "type": "ImportStatement"
      },
      {
        "commentStart": 0,
        "end": 0,
        "path": {
          "type": "Kcl",
          "filename": "lug-nut.kcl"
        },
        "selector": {
          "type": "None",
          "alias": {
            "commentStart": 0,
            "end": 0,
            "name": "lugNut",
            "start": 0,
            "type": "Identifier"
          }
        },
        "start": 0,
        "type": "ImportStatement",
        "type": "ImportStatement"
      },
      {
        "commentStart": 0,
        "end": 0,
        "path": {
          "type": "Kcl",
          "filename": "car-tire.kcl"
        },
        "selector": {
          "type": "None",
          "alias": {
            "commentStart": 0,
            "end": 0,
            "name": "carTire",
            "start": 0,
            "type": "Identifier"
          }
        },
        "start": 0,
        "type": "ImportStatement",
        "type": "ImportStatement"
      },
      {
        "commentStart": 0,
        "end": 0,
        "path": {
          "type": "Kcl",
          "filename": "parameters.kcl"
        },
        "preComments": [
          "",
          "",
          "// Import parameters"
        ],
        "selector": {
          "commentStart": 0,
          "end": 0,
          "start": 0,
          "type": "Glob"
        },
        "start": 0,
        "type": "ImportStatement",
        "type": "ImportStatement"
      },
      {
        "commentStart": 0,
        "end": 0,
        "expression": {
          "body": [
            {
              "abs_path": false,
              "commentStart": 0,
              "end": 0,
              "name": {
                "commentStart": 0,
                "end": 0,
                "name": "carRotor",
                "start": 0,
                "type": "Identifier"
              },
              "path": [],
              "start": 0,
              "type": "Name",
              "type": "Name"
            },
            {
              "arguments": [
                {
                  "type": "LabeledArg",
                  "label": {
                    "commentStart": 0,
                    "end": 0,
                    "name": "x",
                    "start": 0,
                    "type": "Identifier"
                  },
                  "arg": {
                    "commentStart": 0,
                    "end": 0,
                    "raw": "0",
                    "start": 0,
                    "type": "Literal",
                    "type": "Literal",
                    "value": {
                      "value": 0.0,
                      "suffix": "None"
                    }
                  }
                },
                {
                  "type": "LabeledArg",
                  "label": {
                    "commentStart": 0,
                    "end": 0,
                    "name": "y",
                    "start": 0,
                    "type": "Identifier"
                  },
                  "arg": {
                    "commentStart": 0,
                    "end": 0,
                    "raw": "0.5",
                    "start": 0,
                    "type": "Literal",
                    "type": "Literal",
                    "value": {
                      "value": 0.5,
                      "suffix": "None"
                    }
                  }
                },
                {
                  "type": "LabeledArg",
                  "label": {
                    "commentStart": 0,
                    "end": 0,
                    "name": "z",
                    "start": 0,
                    "type": "Identifier"
                  },
                  "arg": {
                    "commentStart": 0,
                    "end": 0,
                    "raw": "0",
                    "start": 0,
                    "type": "Literal",
                    "type": "Literal",
                    "value": {
                      "value": 0.0,
                      "suffix": "None"
                    }
                  }
                }
              ],
              "callee": {
                "abs_path": false,
                "commentStart": 0,
                "end": 0,
                "name": {
                  "commentStart": 0,
                  "end": 0,
                  "name": "translate",
                  "start": 0,
                  "type": "Identifier"
                },
                "path": [],
                "start": 0,
                "type": "Name"
              },
              "commentStart": 0,
              "end": 0,
              "start": 0,
              "type": "CallExpressionKw",
              "type": "CallExpressionKw",
              "unlabeled": null
            }
          ],
          "commentStart": 0,
          "end": 0,
          "nonCodeMeta": {
            "nonCodeNodes": {
              "1": [
                {
                  "commentStart": 0,
                  "end": 0,
                  "start": 0,
                  "type": "NonCodeNode",
                  "value": {
                    "type": "newLineBlockComment",
                    "value": "Place the car wheel",
                    "style": "line"
                  }
                }
              ]
            },
            "startNodes": []
          },
          "start": 0,
          "type": "PipeExpression",
          "type": "PipeExpression"
        },
        "preComments": [
          "",
          "",
          "// Place the car rotor"
        ],
        "start": 0,
        "type": "ExpressionStatement",
        "type": "ExpressionStatement"
      },
      {
        "commentStart": 0,
        "end": 0,
        "expression": {
          "abs_path": false,
          "commentStart": 0,
          "end": 0,
          "name": {
            "commentStart": 0,
            "end": 0,
            "name": "carWheel",
            "start": 0,
            "type": "Identifier"
          },
          "path": [],
          "start": 0,
          "type": "Name",
          "type": "Name"
        },
        "start": 0,
        "type": "ExpressionStatement",
        "type": "ExpressionStatement"
      },
      {
        "commentStart": 0,
        "end": 0,
        "expression": {
          "body": [
            {
              "abs_path": false,
              "commentStart": 0,
              "end": 0,
              "name": {
                "commentStart": 0,
                "end": 0,
                "name": "lugNut",
                "start": 0,
                "type": "Identifier"
              },
              "path": [],
              "start": 0,
              "type": "Name",
              "type": "Name"
            },
            {
              "arguments": [
                {
                  "type": "LabeledArg",
                  "label": {
                    "commentStart": 0,
                    "end": 0,
                    "name": "arcDegrees",
                    "start": 0,
                    "type": "Identifier"
                  },
                  "arg": {
                    "commentStart": 0,
                    "end": 0,
                    "raw": "360",
                    "start": 0,
                    "type": "Literal",
                    "type": "Literal",
                    "value": {
                      "value": 360.0,
                      "suffix": "None"
                    }
                  }
                },
                {
                  "type": "LabeledArg",
                  "label": {
                    "commentStart": 0,
                    "end": 0,
                    "name": "axis",
                    "start": 0,
                    "type": "Identifier"
                  },
                  "arg": {
                    "commentStart": 0,
                    "elements": [
                      {
                        "commentStart": 0,
                        "end": 0,
                        "raw": "0",
                        "start": 0,
                        "type": "Literal",
                        "type": "Literal",
                        "value": {
                          "value": 0.0,
                          "suffix": "None"
                        }
                      },
                      {
                        "commentStart": 0,
                        "end": 0,
                        "raw": "1",
                        "start": 0,
                        "type": "Literal",
                        "type": "Literal",
                        "value": {
                          "value": 1.0,
                          "suffix": "None"
                        }
                      },
                      {
                        "commentStart": 0,
                        "end": 0,
                        "raw": "0",
                        "start": 0,
                        "type": "Literal",
                        "type": "Literal",
                        "value": {
                          "value": 0.0,
                          "suffix": "None"
                        }
                      }
                    ],
                    "end": 0,
                    "start": 0,
                    "type": "ArrayExpression",
                    "type": "ArrayExpression"
                  }
                },
                {
                  "type": "LabeledArg",
                  "label": {
                    "commentStart": 0,
                    "end": 0,
                    "name": "center",
                    "start": 0,
                    "type": "Identifier"
                  },
                  "arg": {
                    "commentStart": 0,
                    "elements": [
                      {
                        "commentStart": 0,
                        "end": 0,
                        "raw": "0",
                        "start": 0,
                        "type": "Literal",
                        "type": "Literal",
                        "value": {
                          "value": 0.0,
                          "suffix": "None"
                        }
                      },
                      {
                        "commentStart": 0,
                        "end": 0,
                        "raw": "0",
                        "start": 0,
                        "type": "Literal",
                        "type": "Literal",
                        "value": {
                          "value": 0.0,
                          "suffix": "None"
                        }
                      },
                      {
                        "commentStart": 0,
                        "end": 0,
                        "raw": "0",
                        "start": 0,
                        "type": "Literal",
                        "type": "Literal",
                        "value": {
                          "value": 0.0,
                          "suffix": "None"
                        }
                      }
                    ],
                    "end": 0,
                    "start": 0,
                    "type": "ArrayExpression",
                    "type": "ArrayExpression"
                  }
                },
                {
                  "type": "LabeledArg",
                  "label": {
                    "commentStart": 0,
                    "end": 0,
                    "name": "instances",
                    "start": 0,
                    "type": "Identifier"
                  },
                  "arg": {
                    "abs_path": false,
                    "commentStart": 0,
                    "end": 0,
                    "name": {
                      "commentStart": 0,
                      "end": 0,
                      "name": "lugCount",
                      "start": 0,
                      "type": "Identifier"
                    },
                    "path": [],
                    "start": 0,
                    "type": "Name",
                    "type": "Name"
                  }
                },
                {
                  "type": "LabeledArg",
                  "label": {
                    "commentStart": 0,
                    "end": 0,
                    "name": "rotateDuplicates",
                    "start": 0,
                    "type": "Identifier"
                  },
                  "arg": {
                    "commentStart": 0,
                    "end": 0,
                    "raw": "false",
                    "start": 0,
                    "type": "Literal",
                    "type": "Literal",
                    "value": false
                  }
                }
              ],
              "callee": {
                "abs_path": false,
                "commentStart": 0,
                "end": 0,
                "name": {
                  "commentStart": 0,
                  "end": 0,
                  "name": "patternCircular3d",
                  "start": 0,
                  "type": "Identifier"
                },
                "path": [],
                "start": 0,
                "type": "Name"
              },
              "commentStart": 0,
              "end": 0,
              "start": 0,
              "type": "CallExpressionKw",
              "type": "CallExpressionKw",
              "unlabeled": null
            }
          ],
          "commentStart": 0,
          "end": 0,
          "nonCodeMeta": {
            "nonCodeNodes": {
              "1": [
                {
                  "commentStart": 0,
                  "end": 0,
                  "start": 0,
                  "type": "NonCodeNode",
                  "value": {
                    "type": "newLineBlockComment",
                    "value": "Place the brake caliper",
                    "style": "line"
                  }
                }
              ]
            },
            "startNodes": []
          },
          "start": 0,
          "type": "PipeExpression",
          "type": "PipeExpression"
        },
        "preComments": [
          "",
          "",
          "// Place the lug nuts"
        ],
        "start": 0,
        "type": "ExpressionStatement",
        "type": "ExpressionStatement"
      },
      {
        "commentStart": 0,
        "end": 0,
        "expression": {
          "body": [
            {
              "abs_path": false,
              "commentStart": 0,
              "end": 0,
              "name": {
                "commentStart": 0,
                "end": 0,
                "name": "brakeCaliper",
                "start": 0,
                "type": "Identifier"
              },
              "path": [],
              "start": 0,
              "type": "Name",
              "type": "Name"
            },
            {
              "arguments": [
                {
                  "type": "LabeledArg",
                  "label": {
                    "commentStart": 0,
                    "end": 0,
                    "name": "x",
                    "start": 0,
                    "type": "Identifier"
                  },
                  "arg": {
                    "commentStart": 0,
                    "end": 0,
                    "raw": "0",
                    "start": 0,
                    "type": "Literal",
                    "type": "Literal",
                    "value": {
                      "value": 0.0,
                      "suffix": "None"
                    }
                  }
                },
                {
                  "type": "LabeledArg",
                  "label": {
                    "commentStart": 0,
                    "end": 0,
                    "name": "y",
                    "start": 0,
                    "type": "Identifier"
                  },
                  "arg": {
                    "commentStart": 0,
                    "end": 0,
                    "raw": "0.5",
                    "start": 0,
                    "type": "Literal",
                    "type": "Literal",
                    "value": {
                      "value": 0.5,
                      "suffix": "None"
                    }
                  }
                },
                {
                  "type": "LabeledArg",
                  "label": {
                    "commentStart": 0,
                    "end": 0,
                    "name": "z",
                    "start": 0,
                    "type": "Identifier"
                  },
                  "arg": {
                    "commentStart": 0,
                    "end": 0,
                    "raw": "0",
                    "start": 0,
                    "type": "Literal",
                    "type": "Literal",
                    "value": {
                      "value": 0.0,
                      "suffix": "None"
                    }
                  }
                }
              ],
              "callee": {
                "abs_path": false,
                "commentStart": 0,
                "end": 0,
                "name": {
                  "commentStart": 0,
                  "end": 0,
                  "name": "translate",
                  "start": 0,
                  "type": "Identifier"
                },
                "path": [],
                "start": 0,
                "type": "Name"
              },
              "commentStart": 0,
              "end": 0,
              "start": 0,
              "type": "CallExpressionKw",
              "type": "CallExpressionKw",
              "unlabeled": null
            }
          ],
          "commentStart": 0,
          "end": 0,
          "nonCodeMeta": {
            "nonCodeNodes": {
              "1": [
                {
                  "commentStart": 0,
                  "end": 0,
                  "start": 0,
                  "type": "NonCodeNode",
                  "value": {
                    "type": "newLineBlockComment",
                    "value": "Place the car tire",
                    "style": "line"
                  }
                }
              ]
            },
            "startNodes": []
          },
          "start": 0,
          "type": "PipeExpression",
          "type": "PipeExpression"
        },
        "start": 0,
        "type": "ExpressionStatement",
        "type": "ExpressionStatement"
      },
      {
        "commentStart": 0,
        "end": 0,
        "expression": {
          "abs_path": false,
          "commentStart": 0,
          "end": 0,
          "name": {
            "commentStart": 0,
            "end": 0,
            "name": "carTire",
            "start": 0,
            "type": "Identifier"
          },
          "path": [],
          "start": 0,
          "type": "Name",
          "type": "Name"
        },
        "start": 0,
        "type": "ExpressionStatement",
        "type": "ExpressionStatement"
      }
    ],
    "commentStart": 0,
    "end": 0,
    "innerAttrs": [
      {
        "commentStart": 0,
        "end": 0,
        "name": {
          "commentStart": 0,
          "end": 0,
          "name": "settings",
          "start": 0,
          "type": "Identifier"
        },
        "preComments": [
          "// Car Wheel Assembly",
          "// A car wheel assembly with a rotor, tire, and lug nuts.",
          "",
          "",
          "// Set units"
        ],
        "properties": [
          {
            "commentStart": 0,
            "end": 0,
            "key": {
              "commentStart": 0,
              "end": 0,
              "name": "defaultLengthUnit",
              "start": 0,
              "type": "Identifier"
            },
            "start": 0,
            "type": "ObjectProperty",
            "value": {
              "abs_path": false,
              "commentStart": 0,
              "end": 0,
              "name": {
                "commentStart": 0,
                "end": 0,
                "name": "in",
                "start": 0,
                "type": "Identifier"
              },
              "path": [],
              "start": 0,
              "type": "Name",
              "type": "Name"
            }
          },
          {
            "commentStart": 0,
            "end": 0,
            "key": {
              "commentStart": 0,
              "end": 0,
              "name": "kclVersion",
              "start": 0,
              "type": "Identifier"
            },
            "start": 0,
            "type": "ObjectProperty",
            "value": {
              "commentStart": 0,
              "end": 0,
              "raw": "1.0",
              "start": 0,
              "type": "Literal",
              "type": "Literal",
              "value": {
                "value": 1.0,
                "suffix": "None"
              }
            }
          }
        ],
        "start": 0,
        "type": "Annotation"
      }
    ],
    "nonCodeMeta": {
      "nonCodeNodes": {},
      "startNodes": [
        {
          "commentStart": 0,
          "end": 0,
          "start": 0,
          "type": "NonCodeNode",
          "value": {
            "type": "newLine"
          }
        }
      ]
    },
    "start": 0
  }
}
