solang-parser 0.2.1

Solang Solidity Parser
Documentation
{
  "absolutePath": "a",
  "exportedSymbols":
  {
    "C":
    [
      12
    ]
  },
  "id": 13,
  "nodeType": "SourceUnit",
  "nodes":
  [
    {
      "abstract": false,
      "baseContracts": [],
      "canonicalName": "C",
      "contractDependencies": [],
      "contractKind": "contract",
      "fullyImplemented": true,
      "id": 12,
      "linearizedBaseContracts":
      [
        12
      ],
      "name": "C",
      "nameLocation": "9:1:1",
      "nodeType": "ContractDefinition",
      "nodes":
      [
        {
          "canonicalName": "C.S",
          "id": 3,
          "members":
          [
            {
              "constant": false,
              "id": 2,
              "mutability": "mutable",
              "name": "x",
              "nameLocation": "33:1:1",
              "nodeType": "VariableDeclaration",
              "scope": 3,
              "src": "28:6:1",
              "stateVariable": false,
              "storageLocation": "default",
              "typeDescriptions":
              {
                "typeIdentifier": "t_uint256",
                "typeString": "uint256"
              },
              "typeName":
              {
                "id": 1,
                "name": "uint",
                "nodeType": "ElementaryTypeName",
                "src": "28:4:1",
                "typeDescriptions":
                {
                  "typeIdentifier": "t_uint256",
                  "typeString": "uint256"
                }
              },
              "visibility": "internal"
            }
          ],
          "name": "S",
          "nameLocation": "24:1:1",
          "nodeType": "StructDefinition",
          "scope": 12,
          "src": "17:20:1",
          "visibility": "public"
        },
        {
          "constant": false,
          "id": 6,
          "mutability": "mutable",
          "name": "s",
          "nameLocation": "44:1:1",
          "nodeType": "VariableDeclaration",
          "scope": 12,
          "src": "42:3:1",
          "stateVariable": true,
          "storageLocation": "default",
          "typeDescriptions":
          {
            "typeIdentifier": "t_struct$_S_$3_storage",
            "typeString": "struct C.S"
          },
          "typeName":
          {
            "id": 5,
            "nodeType": "UserDefinedTypeName",
            "pathNode":
            {
              "id": 4,
              "name": "S",
              "nodeType": "IdentifierPath",
              "referencedDeclaration": 3,
              "src": "42:1:1"
            },
            "referencedDeclaration": 3,
            "src": "42:1:1",
            "typeDescriptions":
            {
              "typeIdentifier": "t_struct$_S_$3_storage_ptr",
              "typeString": "struct C.S"
            }
          },
          "visibility": "internal"
        },
        {
          "body":
          {
            "id": 10,
            "nodeType": "Block",
            "src": "76:70:1",
            "statements":
            [
              {
                "AST":
                {
                  "nodeType": "YulBlock",
                  "src": "95:45:1",
                  "statements":
                  [
                    {
                      "nodeType": "YulVariableDeclaration",
                      "src": "97:17:1",
                      "value":
                      {
                        "name": "s.offset",
                        "nodeType": "YulIdentifier",
                        "src": "106:8:1"
                      },
                      "variables":
                      [
                        {
                          "name": "x",
                          "nodeType": "YulTypedName",
                          "src": "101:1:1",
                          "type": ""
                        }
                      ]
                    },
                    {
                      "nodeType": "YulVariableDeclaration",
                      "src": "115:23:1",
                      "value":
                      {
                        "arguments":
                        [
                          {
                            "name": "s.slot",
                            "nodeType": "YulIdentifier",
                            "src": "128:6:1"
                          },
                          {
                            "kind": "number",
                            "nodeType": "YulLiteral",
                            "src": "136:1:1",
                            "type": "",
                            "value": "2"
                          }
                        ],
                        "functionName":
                        {
                          "name": "mul",
                          "nodeType": "YulIdentifier",
                          "src": "124:3:1"
                        },
                        "nodeType": "YulFunctionCall",
                        "src": "124:14:1"
                      },
                      "variables":
                      [
                        {
                          "name": "y",
                          "nodeType": "YulTypedName",
                          "src": "119:1:1",
                          "type": ""
                        }
                      ]
                    }
                  ]
                },
                "evmVersion": %EVMVERSION%,
                "externalReferences":
                [
                  {
                    "declaration": 6,
                    "isOffset": true,
                    "isSlot": false,
                    "src": "106:8:1",
                    "suffix": "offset",
                    "valueSize": 1
                  },
                  {
                    "declaration": 6,
                    "isOffset": false,
                    "isSlot": true,
                    "src": "128:6:1",
                    "suffix": "slot",
                    "valueSize": 1
                  }
                ],
                "id": 9,
                "nodeType": "InlineAssembly",
                "src": "86:54:1"
              }
            ]
          },
          "functionSelector": "ffae15ba",
          "id": 11,
          "implemented": true,
          "kind": "function",
          "modifiers": [],
          "name": "e",
          "nameLocation": "60:1:1",
          "nodeType": "FunctionDefinition",
          "parameters":
          {
            "id": 7,
            "nodeType": "ParameterList",
            "parameters": [],
            "src": "61:2:1"
          },
          "returnParameters":
          {
            "id": 8,
            "nodeType": "ParameterList",
            "parameters": [],
            "src": "76:0:1"
          },
          "scope": 12,
          "src": "51:95:1",
          "stateMutability": "pure",
          "virtual": false,
          "visibility": "public"
        }
      ],
      "scope": 13,
      "src": "0:148:1",
      "usedErrors": []
    }
  ],
  "src": "0:149:1"
}