final class DialectParser
Restricted visibility: declared "@visibility SqlSemantics". Code outside that scope must not name this declaration.

Selects and reuses the syntax parser for the semantic phase's language context.

Methods§

public function __construct(Dialect $dialect, string|null $version = null)

Parameters

$dialectDialect
$versionstring|nullA release tag shipped by sql-parser
Calls 1
public function parseScript(string $sql): list<Node>

Reads a script using lexer boundaries and complete grammar acceptance. Compound statements keep their internal semicolons because incomplete prefixes cannot be parsed as complete commands.

Parameters

$sqlstring

Returns

list<Node>

Throws

SourceException When any command is invalid
Test cases 2
Called from 1
Calls 4

Private surface 1§

Implementation details, listed for orientation only.

private SqlParser $parser

Test cases 72§

Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.

Dedicated tests 5
Other tests reaching this symbol 67

Relations§

Instantiated in 6
Method calls 9
Type declarations 3