Skip to main content

Module parser

Module parser 

Source
Expand description

Solidity source file parser — parses source code into structured representations for deeper vulnerability analysis (CEI, access control, etc.).

Structs§

Contract
A contract, interface, or library definition.
ErrorDef
A custom error definition.
EventDef
An event definition at the contract level.
FunctionDef
A full function definition with parsed body.
ModifierDef
A modifier definition.
Param
A parameter in a function or event.
SourceFile
A parsed Solidity source file.
StateVariable
A single state variable definition.
Statement
A statement with its content, line number, and kind.
StructDef
A struct definition inside a contract.
UsingForDef
A using-for directive.

Enums§

CallTarget
Metadata about a function call target (which contract/interface is being called).
ContractKind
The kind of top-level type.
Mutability
State mutability of a function.
StatementKind
Classification of a single logical statement within a function body.
Visibility
Visibility of a function or state variable.

Functions§

extract_call_target
Extract the call target from a statement text.
parse_source
Parse a full Solidity source string into a structured representation.