@prisma/orm-framework 8.0.0-rc.17-dev.40 → 8.0.0-rc.17-dev.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{binder-C54tCWu0-C66Qu7Oy.d.mts → binder-Eeh-nJsx-BkT5IXHe.d.mts} +15 -18
- package/dist/binder-Eeh-nJsx-BkT5IXHe.d.mts.map +1 -0
- package/dist/components.d.mts +1 -1
- package/dist/components__control.d.mts +1 -1
- package/dist/{config-types-ChGfgO0H.d.mts → config-types-DnfvNRK4.d.mts} +3 -2
- package/dist/config-types-DnfvNRK4.d.mts.map +1 -0
- package/dist/config.d.mts +1 -1
- package/dist/config__config-types.d.mts +1 -1
- package/dist/{control-rWaFpiNP.d.mts → control-510XVXM6.d.mts} +2 -1
- package/dist/{control-rWaFpiNP.d.mts.map → control-510XVXM6.d.mts.map} +1 -1
- package/dist/control-BdigmuMj.d.mts +1 -0
- package/dist/{control-C11hV6zc-CyU5mC4U.d.mts → control-C11hV6zc-CEHP41aJ.d.mts} +2 -2
- package/dist/{control-C11hV6zc-CyU5mC4U.d.mts.map → control-C11hV6zc-CEHP41aJ.d.mts.map} +1 -1
- package/dist/errors.d.mts +4 -4
- package/dist/errors__control.d.mts +2 -2
- package/dist/errors__execution.d.mts +1 -1
- package/dist/errors__migration.d.mts +1 -1
- package/dist/{execution-Dwe5KeZR.d.mts → execution-CQlE9CHq.d.mts} +3 -3
- package/dist/{execution-Dwe5KeZR.d.mts.map → execution-CQlE9CHq.d.mts.map} +1 -1
- package/dist/{migration-mo8np4v0.d.mts → migration-CFOAAVqQ.d.mts} +2 -2
- package/dist/{migration-mo8np4v0.d.mts.map → migration-CFOAAVqQ.d.mts.map} +1 -1
- package/dist/{parse-DdIfS_Zs-IruUu4RY.mjs → parse-BxcaGLV1-yhRJIgS-.mjs} +8 -11
- package/dist/parse-BxcaGLV1-yhRJIgS-.mjs.map +1 -0
- package/dist/{parse-CJtBvEYy-DSJkhfVG.d.mts → parse-CJtBvEYy-CBkiQrF-.d.mts} +2 -2
- package/dist/{parse-CJtBvEYy-DSJkhfVG.d.mts.map → parse-CJtBvEYy-CBkiQrF-.d.mts.map} +1 -1
- package/dist/psl-parser.d.mts +4 -4
- package/dist/psl-parser.mjs +78 -90
- package/dist/psl-parser.mjs.map +1 -1
- package/dist/psl-parser__format.d.mts +1 -1
- package/dist/psl-parser__format.mjs +1 -1
- package/dist/psl-parser__format.mjs.map +1 -1
- package/dist/psl-parser__interpret.d.mts +3 -3
- package/dist/psl-parser__syntax.d.mts +1 -1
- package/dist/psl-parser__syntax.mjs +1 -1
- package/package.json +15 -15
- package/dist/binder-C54tCWu0-C66Qu7Oy.d.mts.map +0 -1
- package/dist/config-types-ChGfgO0H.d.mts.map +0 -1
- package/dist/control-n_yMh33m.d.mts +0 -1
- package/dist/parse-DdIfS_Zs-IruUu4RY.mjs.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parse-BxcaGLV1-yhRJIgS-.mjs","names":["#filename","#text","#lineStarts","#lineIndexAt","#lineStartAt","#lineEndAt","#sourcesByRoot","#stack","#tokenizer","#sourceFile","#diagnostics","#offset","#depth","#builder","#advance"],"sources":["../../../../1-framework/2-authoring/psl-parser/dist/parse-BxcaGLV1.mjs"],"sourcesContent":["import { r as isTerminatedStringLiteral, t as Tokenizer } from \"./tokenizer-C-GTKKjR.mjs\";\nimport { u as createSyntaxTree } from \"./ast-helpers-CzydMPdh.mjs\";\nimport { n as DocumentAst } from \"./declarations-DuSbyF44.mjs\";\nimport { UNSPECIFIED_PSL_NAMESPACE_ID } from \"@internal/framework-components/psl-ast\";\nimport { InternalError } from \"@internal/utils/internal-error\";\n//#region src/source-file.ts\nconst CARRIAGE_RETURN = 13;\nconst LINE_FEED = 10;\nvar SourceFile = class {\n\t#filename;\n\t#text;\n\t#lineStarts;\n\tconstructor(filename, text) {\n\t\tthis.#filename = filename;\n\t\tthis.#text = text;\n\t\tconst lineStarts = [0];\n\t\tfor (let offset = 0; offset < text.length; offset++) if (text.charCodeAt(offset) === LINE_FEED) lineStarts.push(offset + 1);\n\t\tthis.#lineStarts = lineStarts;\n\t}\n\tget filename() {\n\t\treturn this.#filename;\n\t}\n\tget text() {\n\t\treturn this.#text;\n\t}\n\tget length() {\n\t\treturn this.#text.length;\n\t}\n\tget lineCount() {\n\t\treturn this.#lineStarts.length;\n\t}\n\tlineStartOffsets() {\n\t\treturn this.#lineStarts;\n\t}\n\tlineStartOffset(line) {\n\t\tif (line <= 0) return 0;\n\t\treturn this.#lineStarts[line] ?? this.#text.length;\n\t}\n\tlineEndOffset(line) {\n\t\tif (line < 0) return 0;\n\t\tconst nextLineStart = this.#lineStarts[line + 1];\n\t\tif (nextLineStart === void 0) return this.#text.length;\n\t\tconst lineFeedOffset = nextLineStart - 1;\n\t\tconst carriageReturnOffset = lineFeedOffset - 1;\n\t\treturn this.#text.charCodeAt(carriageReturnOffset) === CARRIAGE_RETURN ? carriageReturnOffset : lineFeedOffset;\n\t}\n\tpositionAt(offset) {\n\t\tconst clamped = clamp(offset, 0, this.#text.length);\n\t\tconst line = this.#lineIndexAt(clamped);\n\t\treturn {\n\t\t\tline,\n\t\t\tcharacter: clamped - this.#lineStartAt(line)\n\t\t};\n\t}\n\toffsetAt(position) {\n\t\tconst line = clamp(position.line, 0, this.#lineStarts.length - 1);\n\t\tconst lineStart = this.#lineStartAt(line);\n\t\tconst lineEnd = this.#lineEndAt(line);\n\t\treturn clamp(lineStart + position.character, lineStart, lineEnd);\n\t}\n\toffsetToPslPosition(offset) {\n\t\tconst position = this.positionAt(offset);\n\t\treturn {\n\t\t\toffset,\n\t\t\tline: position.line + 1,\n\t\t\tcolumn: position.character + 1\n\t\t};\n\t}\n\trangeToPslSpan(range) {\n\t\treturn {\n\t\t\tstart: this.offsetToPslPosition(this.offsetAt(range.start)),\n\t\t\tend: this.offsetToPslPosition(this.offsetAt(range.end))\n\t\t};\n\t}\n\tpslSpanToRange(span) {\n\t\treturn {\n\t\t\tstart: this.positionAt(span.start.offset),\n\t\t\tend: this.positionAt(span.end.offset)\n\t\t};\n\t}\n\t#lineStartAt(line) {\n\t\treturn this.#lineStarts[line] ?? 0;\n\t}\n\t#lineEndAt(line) {\n\t\treturn line + 1 < this.#lineStarts.length ? this.#lineStartAt(line + 1) - 1 : this.#text.length;\n\t}\n\t#lineIndexAt(offset) {\n\t\tconst lineStarts = this.#lineStarts;\n\t\tlet low = 0;\n\t\tlet high = lineStarts.length - 1;\n\t\twhile (low < high) {\n\t\t\tconst mid = low + high + 1 >>> 1;\n\t\t\tif ((lineStarts[mid] ?? 0) <= offset) low = mid;\n\t\t\telse high = mid - 1;\n\t\t}\n\t\treturn low;\n\t}\n};\nvar PslSources = class PslSources {\n\t#sourcesByRoot = /* @__PURE__ */ new Map();\n\tconstructor(entries) {\n\t\tfor (const [root, sourceFile] of entries) this.#sourcesByRoot.set(root, sourceFile);\n\t}\n\t/**\n\t* A new registry uniting this one with `others` — e.g. the per-document\n\t* `PslSources` registries `parse()` returns for each member of a\n\t* multi-file schema, united into the one registry `buildSymbolTable` and\n\t* the interpreters expect.\n\t*/\n\tmerge(...others) {\n\t\treturn new PslSources([...this.#sourcesByRoot, ...others.flatMap((other) => [...other.#sourcesByRoot])]);\n\t}\n\tsourceFileNamed(filename) {\n\t\tlet match;\n\t\tfor (const sourceFile of this.#sourcesByRoot.values()) {\n\t\t\tif (sourceFile.filename !== filename) continue;\n\t\t\tif (match !== void 0 && match.text !== sourceFile.text) throw new InternalError(`Ambiguous PSL diagnostic filename \"${filename}\": registered sources have different text`);\n\t\t\tmatch = sourceFile;\n\t\t}\n\t\tif (match === void 0) throw new InternalError(`No SourceFile registered for PSL diagnostic filename \"${filename}\"`);\n\t\treturn match;\n\t}\n\tsourceFileFor(node) {\n\t\tconst root = node.root();\n\t\tconst sourceFile = this.#sourcesByRoot.get(root);\n\t\tif (sourceFile === void 0) throw new InternalError(\"No SourceFile registered for PSL syntax root\");\n\t\treturn sourceFile;\n\t}\n};\nfunction clamp(value, min, max) {\n\tif (value < min) return min;\n\tif (value > max) return max;\n\treturn value;\n}\n//#endregion\n//#region src/syntax/green.ts\nfunction greenToken(kind, text) {\n\treturn {\n\t\ttype: \"token\",\n\t\tkind,\n\t\ttext\n\t};\n}\nfunction greenNode(kind, children) {\n\tlet textLength = 0;\n\tfor (const child of children) textLength += child.type === \"token\" ? child.text.length : child.textLength;\n\treturn {\n\t\ttype: \"node\",\n\t\tkind,\n\t\tchildren,\n\t\ttextLength\n\t};\n}\n//#endregion\n//#region src/syntax/green-builder.ts\nvar GreenNodeBuilder = class {\n\t#stack = [];\n\tstartNode(kind) {\n\t\tthis.#stack.push({\n\t\t\tkind,\n\t\t\tchildren: []\n\t\t});\n\t}\n\ttoken(kind, text) {\n\t\tconst current = this.#stack.at(-1);\n\t\tif (!current) throw new InternalError(\"GreenNodeBuilder: token() called with no open node\");\n\t\tcurrent.children.push(greenToken(kind, text));\n\t}\n\tfinishNode() {\n\t\tconst completed = this.#stack.pop();\n\t\tif (!completed) throw new InternalError(\"GreenNodeBuilder: finishNode() called with no open node\");\n\t\tconst node = greenNode(completed.kind, completed.children);\n\t\tconst parent = this.#stack.at(-1);\n\t\tif (parent) parent.children.push(node);\n\t\treturn node;\n\t}\n};\n//#endregion\n//#region src/parse.ts\nconst TRIVIA_KINDS = /* @__PURE__ */ new Set([\n\t\"Whitespace\",\n\t\"Newline\",\n\t\"Comment\"\n]);\n/**\n* The fault-tolerant parser substrate the parse functions below drive. Trivia is flushed\n* into the enclosing open node, so every child node spans exactly its first\n* through last significant token.\n*/\nvar Cursor = class {\n\t#tokenizer;\n\t#sourceFile;\n\t#builder = new GreenNodeBuilder();\n\t#diagnostics = [];\n\t#offset = 0;\n\t#depth = 0;\n\tconstructor(filename, source) {\n\t\tthis.#tokenizer = new Tokenizer(source);\n\t\tthis.#sourceFile = new SourceFile(filename, source);\n\t}\n\tget diagnostics() {\n\t\treturn this.#diagnostics;\n\t}\n\tget sourceFile() {\n\t\treturn this.#sourceFile;\n\t}\n\tpeekKind(ahead = 0) {\n\t\treturn this.peekToken(ahead).kind;\n\t}\n\tpeekToken(ahead = 0) {\n\t\tlet rawIndex = 0;\n\t\tlet remaining = ahead;\n\t\tfor (;;) {\n\t\t\tconst token = this.#tokenizer.peek(rawIndex);\n\t\t\tif (token.kind === \"Eof\") return token;\n\t\t\tif (TRIVIA_KINDS.has(token.kind)) {\n\t\t\t\trawIndex++;\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif (remaining === 0) return token;\n\t\t\tremaining--;\n\t\t\trawIndex++;\n\t\t}\n\t}\n\tnewlineBefore(ahead = 0) {\n\t\tlet rawIndex = 0;\n\t\tlet remaining = ahead;\n\t\tlet newline = false;\n\t\tfor (;;) {\n\t\t\tconst token = this.#tokenizer.peek(rawIndex);\n\t\t\tif (token.kind === \"Eof\") return newline;\n\t\t\tif (TRIVIA_KINDS.has(token.kind)) {\n\t\t\t\tif (token.kind === \"Newline\") newline = true;\n\t\t\t\trawIndex++;\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif (remaining === 0) return newline;\n\t\t\tremaining--;\n\t\t\tnewline = false;\n\t\t\trawIndex++;\n\t\t}\n\t}\n\t/** Span of the significant token `lookahead` positions ahead (`mark(0)` = the next). */\n\tmark(lookahead = 0) {\n\t\tlet rawIndex = 0;\n\t\tlet offset = this.#offset;\n\t\tlet remaining = lookahead;\n\t\tfor (;;) {\n\t\t\tconst token = this.#tokenizer.peek(rawIndex);\n\t\t\tif (token.kind === \"Eof\") return {\n\t\t\t\toffset,\n\t\t\t\tlength: token.text.length\n\t\t\t};\n\t\t\tif (!TRIVIA_KINDS.has(token.kind) && remaining === 0) return {\n\t\t\t\toffset,\n\t\t\t\tlength: token.text.length\n\t\t\t};\n\t\t\tif (!TRIVIA_KINDS.has(token.kind)) remaining--;\n\t\t\toffset += token.text.length;\n\t\t\trawIndex++;\n\t\t}\n\t}\n\t/**\n\t* Zero-width mark just past the last consumed significant token — anchors an\n\t* \"expected here\" diagnostic, e.g. the `{` missing after a declaration's name.\n\t*/\n\tmarkAfterLastToken() {\n\t\treturn {\n\t\t\toffset: this.#offset,\n\t\t\tlength: 0\n\t\t};\n\t}\n\tstartNode(kind) {\n\t\tif (this.#depth > 0) this.flushTrivia();\n\t\tthis.#builder.startNode(kind);\n\t\tthis.#depth++;\n\t}\n\tfinishNode() {\n\t\tthis.#depth--;\n\t\treturn this.#builder.finishNode();\n\t}\n\tbump() {\n\t\tthis.flushTrivia();\n\t\tconst token = this.#tokenizer.peek();\n\t\tif (token.kind === \"Eof\") return token;\n\t\tthis.#builder.token(token.kind, token.text);\n\t\tthis.#advance();\n\t\treturn token;\n\t}\n\trecoverToSyncPoint() {\n\t\tfor (;;) {\n\t\t\tconst token = this.#tokenizer.peek();\n\t\t\tif (token.kind === \"Eof\" || token.kind === \"Newline\" || token.kind === \"RBrace\") return;\n\t\t\tthis.#builder.token(token.kind, token.text);\n\t\t\tthis.#advance();\n\t\t}\n\t}\n\tflushTrivia() {\n\t\tfor (;;) {\n\t\t\tconst token = this.#tokenizer.peek();\n\t\t\tif (!TRIVIA_KINDS.has(token.kind)) return;\n\t\t\tthis.#builder.token(token.kind, token.text);\n\t\t\tthis.#advance();\n\t\t}\n\t}\n\tdiagnostic(code, message, mark) {\n\t\tconst start = mark.offset;\n\t\tconst end = start + mark.length;\n\t\tthis.#diagnostics.push({\n\t\t\tfilename: this.#sourceFile.filename,\n\t\t\tcode,\n\t\t\tmessage,\n\t\t\trange: {\n\t\t\t\tstart: this.#sourceFile.positionAt(start),\n\t\t\t\tend: this.#sourceFile.positionAt(end)\n\t\t\t}\n\t\t});\n\t}\n\t#advance() {\n\t\tthis.#offset += this.#tokenizer.next().text.length;\n\t}\n};\nfunction parseIdentifier(cursor) {\n\tcursor.startNode(\"Identifier\");\n\tcursor.bump();\n\tcursor.finishNode();\n}\n/**\n* Returns `undefined` when the next significant token does not start a\n* recognised expression, leaving recovery to the caller.\n*/\nfunction parseExpression(cursor) {\n\treturn parseStringLiteralExpr(cursor) ?? parseNumberLiteralExpr(cursor) ?? parseArrayLiteral(cursor) ?? parseObjectLiteralExpr(cursor) ?? parseTaggedLiteral(cursor) ?? parseFunctionCall(cursor) ?? parsePathExpr(cursor) ?? parseBooleanLiteralExpr(cursor) ?? parseIdentifierExpr(cursor);\n}\n/** A string literal outside a tagged literal, where a backtick string is refused. */\nfunction parseStringLiteralExpr(cursor) {\n\tif (cursor.peekKind() !== \"StringLiteral\") return void 0;\n\tif (cursor.peekToken().text.startsWith(\"`\")) cursor.diagnostic(\"PSL_BACKTICK_STRING_REQUIRES_TAG\", \"A backtick string must follow a tag, as in tag`...`.\", cursor.mark());\n\treturn parseStringLiteral(cursor);\n}\nfunction parseStringLiteral(cursor) {\n\tconst stringMark = cursor.mark();\n\tconst text = cursor.peekToken().text;\n\tcursor.startNode(\"StringLiteralExpr\");\n\tcursor.bump();\n\tif (!isTerminatedStringLiteral(text)) cursor.diagnostic(\"PSL_UNTERMINATED_STRING\", \"Unterminated string literal\", stringMark);\n\treturn cursor.finishNode();\n}\nfunction parseNumberLiteralExpr(cursor) {\n\tif (cursor.peekKind() !== \"NumberLiteral\") return void 0;\n\tcursor.startNode(\"NumberLiteralExpr\");\n\tcursor.bump();\n\treturn cursor.finishNode();\n}\n/**\n* Parses a namespace-qualified name `[space ':']? Ident ('.' Ident)*`. The\n* caller guarantees a leading `Ident`.\n*\n* Parsing the whole chain up front lets a position decide\n* constructor-vs-reference by peeking exactly one token for `(`, with no scan of\n* the dotted chain's length.\n*/\nfunction parseQualifiedName(cursor) {\n\tcursor.startNode(\"QualifiedName\");\n\tparseIdentifier(cursor);\n\tparseQualifiedSegments(cursor, \"Colon\");\n\tparseQualifiedSegments(cursor, \"Dot\");\n\tcursor.finishNode();\n}\n/**\n* A well-formed name carries at most one colon space and one dot namespace, so\n* each separator past the first of its kind reports `PSL_INVALID_QUALIFIED_NAME`.\n* The separator is consumed regardless, keeping the lossless round-trip intact.\n*/\nfunction parseQualifiedSegments(cursor, separator) {\n\tlet seen = 0;\n\twhile (cursor.peekKind() === separator && !cursor.newlineBefore()) {\n\t\tseen++;\n\t\tconst separatorMark = cursor.mark();\n\t\tcursor.bump();\n\t\tif (seen > 1) cursor.diagnostic(\"PSL_INVALID_QUALIFIED_NAME\", \"Qualified name has too many segments\", separatorMark);\n\t\tif (cursor.peekKind() === \"Ident\" && !cursor.newlineBefore()) parseIdentifier(cursor);\n\t\telse reportMissingSegment(cursor);\n\t}\n}\nfunction reportMissingSegment(cursor) {\n\tcursor.diagnostic(\"PSL_INVALID_QUALIFIED_NAME\", \"Qualified name is missing a name after the separator\", cursor.markAfterLastToken());\n}\n/**\n* Whether the next tokens open a tagged literal: a bare `Ident` or a\n* namespace-qualified `Ident.Ident`, then a string. Trivia may sit anywhere\n* between them. Bounded like {@link isCallAhead}.\n*/\nfunction isTaggedLiteralAhead(cursor) {\n\tif (cursor.peekKind() !== \"Ident\") return false;\n\tif (cursor.peekKind(1) === \"StringLiteral\") return true;\n\treturn cursor.peekKind(1) === \"Dot\" && cursor.peekKind(2) === \"Ident\" && cursor.peekKind(3) === \"StringLiteral\";\n}\n/** Parses `` tag`body` ``, `tag\"body\"`, or `tag'body'`: a qualified name, then a string literal. */\nfunction parseTaggedLiteral(cursor) {\n\tif (!isTaggedLiteralAhead(cursor)) return void 0;\n\tcursor.startNode(\"TaggedLiteral\");\n\tparseQualifiedName(cursor);\n\tparseStringLiteral(cursor);\n\treturn cursor.finishNode();\n}\nfunction parseBooleanLiteralExpr(cursor) {\n\tif (cursor.peekKind() !== \"Ident\") return void 0;\n\tconst text = cursor.peekToken().text;\n\tif (text !== \"true\" && text !== \"false\") return void 0;\n\tcursor.startNode(\"BooleanLiteralExpr\");\n\tcursor.bump();\n\treturn cursor.finishNode();\n}\nfunction parseIdentifierExpr(cursor) {\n\tif (cursor.peekKind() !== \"Ident\") return void 0;\n\tcursor.startNode(\"Identifier\");\n\tcursor.bump();\n\treturn cursor.finishNode();\n}\nfunction parseArrayLiteral(cursor) {\n\tif (cursor.peekKind() !== \"LBracket\") return void 0;\n\tcursor.startNode(\"ArrayLiteral\");\n\tcursor.bump();\n\twhile (cursor.peekKind() !== \"RBracket\" && cursor.peekKind() !== \"Eof\") {\n\t\tif (!parseExpression(cursor)) break;\n\t\tif (cursor.peekKind() === \"Comma\") cursor.bump();\n\t\telse break;\n\t}\n\tif (cursor.peekKind() === \"RBracket\") cursor.bump();\n\treturn cursor.finishNode();\n}\nfunction parseObjectLiteralExpr(cursor) {\n\tif (cursor.peekKind() !== \"LBrace\") return void 0;\n\tconst braceMark = cursor.mark();\n\tcursor.startNode(\"ObjectLiteralExpr\");\n\tcursor.bump();\n\twhile (cursor.peekKind() !== \"RBrace\" && cursor.peekKind() !== \"Eof\") {\n\t\tparseObjectField(cursor);\n\t\tif (cursor.peekKind() === \"Comma\") cursor.bump();\n\t\telse if (cursor.peekKind() === \"Ident\") cursor.diagnostic(\"PSL_INVALID_OBJECT_LITERAL\", \"Expected \\\",\\\" between object-literal fields\", cursor.markAfterLastToken());\n\t\telse break;\n\t}\n\tif (cursor.peekKind() === \"RBrace\") cursor.bump();\n\telse cursor.diagnostic(\"PSL_INVALID_OBJECT_LITERAL\", \"Unterminated object literal\", braceMark);\n\treturn cursor.finishNode();\n}\nfunction parseObjectField(cursor) {\n\tcursor.startNode(\"ObjectField\");\n\tconst keyMark = cursor.mark();\n\tconst keyText = cursor.peekToken().text;\n\tif (cursor.peekKind() === \"Ident\") parseIdentifier(cursor);\n\telse if (cursor.peekKind() === \"StringLiteral\") parseStringLiteralExpr(cursor);\n\tif (cursor.peekKind() === \"Colon\") {\n\t\tcursor.bump();\n\t\tif (!parseExpression(cursor)) cursor.diagnostic(\"PSL_INVALID_OBJECT_LITERAL\", \"Expected a value after \\\":\\\"\", cursor.mark());\n\t} else {\n\t\tcursor.diagnostic(\"PSL_INVALID_OBJECT_LITERAL\", `Expected \":\" after \"${keyText}\"`, keyMark);\n\t\tif (!(cursor.peekKind() === \"Ident\" && cursor.peekKind(1) === \"Colon\")) parseExpression(cursor);\n\t}\n\treturn cursor.finishNode();\n}\n/**\n* The dotted chain `Ident ('.' Ident)*` at the cursor, which stays on one line. `length` counts its\n* significant tokens: 1 for `a`, 3 for `a.b`, 5 for `a.b.c`; 0 when no `Ident` is next.\n* `trailingDot` marks a chain that ends in a `.` with no name after it, as in `auth.`.\n*/\nfunction dottedChain(cursor) {\n\tif (cursor.peekKind() !== \"Ident\") return {\n\t\tlength: 0,\n\t\ttrailingDot: false\n\t};\n\tlet length = 1;\n\twhile (cursor.peekKind(length) === \"Dot\" && !cursor.newlineBefore(length)) {\n\t\tif (cursor.peekKind(length + 1) !== \"Ident\" || cursor.newlineBefore(length + 1)) return {\n\t\t\tlength,\n\t\t\ttrailingDot: true\n\t\t};\n\t\tlength += 2;\n\t}\n\treturn {\n\t\tlength,\n\t\ttrailingDot: false\n\t};\n}\n/**\n* Whether the next tokens open a call: a dotted chain followed by `(`, such as\n* `autoincrement(`, `temporal.updatedAt(` or `address.geo.lat(`. A dotted chain\n* with no `(` after it, like `a.b`, is a path, not a call.\n*/\nfunction isCallAhead(cursor) {\n\tconst chain = dottedChain(cursor);\n\treturn chain.length > 0 && !chain.trailingDot && cursor.peekKind(chain.length) === \"LParen\";\n}\n/**\n* Parses a function/constructor call — bare `autoincrement()` or dotted\n* `address.city(sort: Asc)`. A dotted callee is a `PathExpr`, the node the same\n* chain gets without the call, so `address.city` has one shape whether or not\n* it is called; a bare callee is a `QualifiedName`. Returns `undefined` unless\n* {@link isCallAhead} confirms a trailing `(`, so the `parseExpression` chain\n* falls through to the path, boolean and bare-identifier forms.\n*/\nfunction parseFunctionCall(cursor) {\n\tif (!isCallAhead(cursor)) return void 0;\n\tconst chain = dottedChain(cursor);\n\tcursor.startNode(\"FunctionCall\");\n\tif (chain.length > 1) parsePath(cursor, chain);\n\telse parseQualifiedName(cursor);\n\tif (cursor.peekKind() === \"LParen\") parseParenArgs(cursor);\n\treturn cursor.finishNode();\n}\n/**\n* Parses a member path `Ident ('.' Ident)+` that is neither a call nor the tag\n* of a tagged literal, such as `address.city` in `@@index([address.city])`. A\n* path that ends in a `.` keeps the dot and reports the missing name, as in\n* `auth.` while the member is still being typed.\n*/\nfunction parsePathExpr(cursor) {\n\tconst chain = dottedChain(cursor);\n\tif (chain.length < 3 && !chain.trailingDot) return void 0;\n\treturn parsePath(cursor, chain);\n}\nfunction parsePath(cursor, chain) {\n\tcursor.startNode(\"PathExpr\");\n\tparseIdentifier(cursor);\n\tfor (let consumed = 1; consumed < chain.length; consumed += 2) {\n\t\tcursor.bump();\n\t\tparseIdentifier(cursor);\n\t}\n\tif (chain.trailingDot) {\n\t\tcursor.bump();\n\t\treportMissingSegment(cursor);\n\t}\n\treturn cursor.finishNode();\n}\n/** Parses a parenthesised, comma-separated `AttributeArg` list into the currently open node. */\nfunction parseParenArgs(cursor) {\n\tcursor.bump();\n\twhile (cursor.peekKind() !== \"RParen\" && cursor.peekKind() !== \"Eof\") {\n\t\tparseAttributeArg(cursor);\n\t\tif (cursor.peekKind() === \"Comma\") cursor.bump();\n\t\telse break;\n\t}\n\tif (cursor.peekKind() === \"RParen\") cursor.bump();\n}\nfunction parseAttributeArg(cursor) {\n\tconst kind = cursor.peekKind();\n\tif (kind !== \"Ident\" && kind !== \"StringLiteral\" && kind !== \"NumberLiteral\" && kind !== \"LBracket\" && kind !== \"LBrace\") return;\n\tcursor.startNode(\"AttributeArg\");\n\tif (cursor.peekKind() === \"Ident\" && cursor.peekKind(1) === \"Colon\") {\n\t\tparseIdentifier(cursor);\n\t\tcursor.bump();\n\t}\n\tparseArgValue(cursor);\n\tcursor.finishNode();\n}\nfunction parseArgValue(cursor) {\n\tparseExpression(cursor);\n}\nfunction parseAttributeArgList(cursor) {\n\tcursor.startNode(\"AttributeArgList\");\n\tparseParenArgs(cursor);\n\treturn cursor.finishNode();\n}\nconst LIST_CLOSERS = {\n\tAttributeArgList: \"RParen\",\n\tFunctionCall: \"RParen\",\n\tArrayLiteral: \"RBracket\",\n\tObjectLiteralExpr: \"RBrace\"\n};\nfunction isUnclosed(node) {\n\tconst closer = LIST_CLOSERS[node.kind];\n\tif (closer === void 0) return node.children.some((child) => child.type === \"node\" && isUnclosed(child));\n\tconst last = node.children.at(-1);\n\treturn last?.type !== \"token\" || last.kind !== closer;\n}\nfunction consumeLeftover(cursor, code, place, diagnosticsBefore) {\n\tconst kind = cursor.peekKind();\n\tif (kind === \"Eof\" || kind === \"RBrace\" || cursor.newlineBefore()) return false;\n\tif (cursor.diagnostics.length === diagnosticsBefore) cursor.diagnostic(code, `Unexpected \"${cursor.peekToken().text}\" in ${place}`, cursor.mark());\n\tcursor.recoverToSyncPoint();\n\treturn true;\n}\nfunction parseAttribute(cursor) {\n\tconst isBlockAttribute = cursor.peekKind() === \"DoubleAt\";\n\tconst attributeMark = cursor.mark();\n\tconst diagnosticsBefore = cursor.diagnostics.length;\n\tcursor.startNode(isBlockAttribute ? \"ModelAttribute\" : \"FieldAttribute\");\n\tcursor.bump();\n\tif (cursor.peekKind() === \"Ident\") parseQualifiedName(cursor);\n\telse cursor.diagnostic(\"PSL_INVALID_ATTRIBUTE_SYNTAX\", \"Attribute name expected\", attributeMark);\n\tif (cursor.peekKind() === \"LParen\" && isUnclosed(parseAttributeArgList(cursor))) consumeLeftover(cursor, \"PSL_INVALID_ATTRIBUTE_SYNTAX\", \"attribute arguments\", diagnosticsBefore);\n\treturn cursor.finishNode();\n}\n/**\n* A type annotation: `QualifiedName (argList)? (?)? ([])? (?)?`, e.g.\n* `pgvector.Vector(1536)?[]?`. The two `?` positions are distinct axes: a `?`\n* before `[]` makes the list elements nullable; a `?` after `[]` makes the\n* list itself nullable. Without a `[]`, a single `?` is the field-level\n* optional (`Foo?`), so a second `?` (`Foo??`) is malformed. When the field\n* has no type, no node is emitted — a missing type is the absence of a\n* `TypeAnnotation`, not a zero-width one.\n*/\nfunction parseTypeAnnotation(cursor, memberCode) {\n\tconst kind = cursor.peekKind();\n\tif (kind !== \"Ident\" && kind !== \"LBracket\" && kind !== \"Question\") return;\n\tcursor.startNode(\"TypeAnnotation\");\n\tif (cursor.peekKind() === \"Ident\") {\n\t\tparseQualifiedName(cursor);\n\t\tconst diagnosticsBefore = cursor.diagnostics.length;\n\t\tif (cursor.peekKind() === \"LParen\" && isUnclosed(parseAttributeArgList(cursor)) && consumeLeftover(cursor, memberCode, \"type arguments\", diagnosticsBefore)) {\n\t\t\tcursor.finishNode();\n\t\t\treturn;\n\t\t}\n\t}\n\tconst hasLeadingQuestion = cursor.peekKind() === \"Question\";\n\tif (hasLeadingQuestion) cursor.bump();\n\tlet isListType = false;\n\tif (cursor.peekKind() === \"LBracket\") {\n\t\tisListType = true;\n\t\tcursor.bump();\n\t\tif (cursor.peekKind() === \"RBracket\") cursor.bump();\n\t}\n\tlet trailingAllowed = isListType || !hasLeadingQuestion;\n\twhile (cursor.peekKind() === \"Question\") {\n\t\tif (!trailingAllowed) cursor.diagnostic(memberCode, \"Unexpected \\\"?\\\"; a type may be optional (`Foo?`), a list (`Foo[]`), have nullable elements (`Foo?[]`), or both (`Foo?[]?`)\", cursor.mark());\n\t\tcursor.bump();\n\t\ttrailingAllowed = false;\n\t}\n\tcursor.finishNode();\n}\n/**\n* Parses a full PSL document. Never throws — malformed input yields diagnostics\n* and a recovered tree, not an exception.\n*/\nfunction parse(source, filename, options = {}) {\n\tconst cursor = new Cursor(filename, source);\n\tconst root = createSyntaxTree(parseDocument(cursor, options));\n\tconst document = DocumentAst.cast(root) ?? new DocumentAst(root);\n\tconst sources = new PslSources([[document.syntax, cursor.sourceFile]]);\n\treturn {\n\t\tdocument,\n\t\tdiagnostics: cursor.diagnostics,\n\t\tsources\n\t};\n}\nfunction parseDocument(cursor, options) {\n\tcursor.startNode(\"Document\");\n\twhile (cursor.peekKind() !== \"Eof\") parseDeclaration(cursor, false, options);\n\tcursor.flushTrivia();\n\treturn cursor.finishNode();\n}\nconst RESERVED_BLOCK_KEYWORDS = /* @__PURE__ */ new Set([\n\t\"model\",\n\t\"namespace\",\n\t\"type\",\n\t\"types\"\n]);\nconst MIXIN_KEYWORD = \"mixin\";\nconst KEYWORDS_WITHOUT_MIXINS = /* @__PURE__ */ new Set([\n\t\"namespace\",\n\t\"types\",\n\tMIXIN_KEYWORD\n]);\nfunction isMixinHeaderAhead(cursor) {\n\treturn cursor.peekKind() === \"Ident\" && cursor.peekKind(1) === \"Ident\" && cursor.peekToken(1).text === MIXIN_KEYWORD;\n}\nfunction keywordIs(cursor, keyword) {\n\treturn cursor.peekKind() === \"Ident\" && cursor.peekToken().text === keyword;\n}\n/**\n* Each alternative is a no-op on non-match, consuming nothing, so the\n* forward-only cursor is never left half-consumed by a rejected alternative.\n* Recovery runs via the `if (!node)` tail rather than as a `??` arm, because it\n* appends raw tokens to the open parent instead of returning a child node.\n*/\nfunction parseDeclaration(cursor, insideNamespace, options) {\n\tif (isMixinHeaderAhead(cursor)) {\n\t\tparseMixinDeclaration(cursor, options);\n\t\treturn;\n\t}\n\tconst name = cursor.peekKind(1) === \"Ident\" ? cursor.peekToken(1).text : \"\";\n\tif (insideNamespace && keywordIs(cursor, \"namespace\")) cursor.diagnostic(\"PSL_INVALID_NAMESPACE_BLOCK\", `Recursive \"namespace ${name}\" block is not allowed; namespace blocks may not nest`, cursor.mark());\n\telse if (insideNamespace && keywordIs(cursor, \"types\")) cursor.diagnostic(\"PSL_INVALID_NAMESPACE_BLOCK\", \"`types` blocks must be declared at the document top level, not inside a namespace block\", cursor.mark());\n\telse if (keywordIs(cursor, \"namespace\") && name === UNSPECIFIED_PSL_NAMESPACE_ID) cursor.diagnostic(\"PSL_INVALID_NAMESPACE_BLOCK\", `Namespace name \"${UNSPECIFIED_PSL_NAMESPACE_ID}\" is reserved for the parser-synthesised bucket for top-level declarations`, cursor.mark(1));\n\tif (!(parseModel(cursor) ?? parseNamespace(cursor, options) ?? parseCompositeType(cursor) ?? parseTypesBlock(cursor) ?? parseGenericBlock(cursor, options))) parseUnsupportedTopLevel(cursor);\n}\n/**\n* Reports only the first missing piece — a missing name suppresses the\n* missing-brace diagnostic. `nameRequired` is false only for the `types` block.\n*/\nfunction parseBlock(cursor, kind, nameRequired, parseMember) {\n\tconst keyword = cursor.peekToken().text;\n\tconst keywordMark = cursor.mark();\n\tcursor.startNode(kind);\n\tcursor.bump();\n\tconst hasName = nameRequired && cursor.peekKind() === \"Ident\";\n\tif (hasName) parseIdentifier(cursor);\n\tif (nameRequired && !hasName) cursor.diagnostic(\"PSL_INVALID_DECLARATION\", `Expected a name after \"${keyword}\"`, keywordMark);\n\telse if (cursor.peekKind() !== \"LBrace\") cursor.diagnostic(\"PSL_INVALID_DECLARATION\", `Expected \"{\" to open the \"${keyword}\" block`, cursor.markAfterLastToken());\n\tif (cursor.peekKind() === \"LBrace\") parseBlockBody(cursor, parseMember);\n\telse cursor.recoverToSyncPoint();\n\treturn cursor.finishNode();\n}\nfunction parseModel(cursor) {\n\tif (!keywordIs(cursor, \"model\")) return void 0;\n\treturn parseBlock(cursor, \"ModelDeclaration\", true, parseModelMember);\n}\nfunction parseMixinDeclaration(cursor, options) {\n\tconst keyword = cursor.peekToken().text;\n\tconst keywordMark = cursor.mark();\n\tconst mixinMark = cursor.mark(1);\n\tcursor.startNode(\"MixinDeclaration\");\n\tcursor.bump();\n\tcursor.bump();\n\tconst hasName = cursor.peekKind() === \"Ident\" && (!cursor.newlineBefore() || cursor.peekKind(1) === \"LBrace\");\n\tif (hasName) parseIdentifier(cursor);\n\tconst hasBody = cursor.peekKind() === \"LBrace\";\n\tif (KEYWORDS_WITHOUT_MIXINS.has(keyword)) cursor.diagnostic(\"PSL_INVALID_DECLARATION\", `A mixin cannot be declared for \"${keyword}\"`, keywordMark);\n\telse if (!hasName) cursor.diagnostic(\"PSL_INVALID_DECLARATION\", `Expected a mixin name after \"${MIXIN_KEYWORD}\"`, mixinMark);\n\telse if (!hasBody) cursor.diagnostic(\"PSL_INVALID_DECLARATION\", `Expected \"{\" to open the \"${keyword} ${MIXIN_KEYWORD}\" block`, cursor.markAfterLastToken());\n\tif (hasBody) parseBlockBody(cursor, mixinMemberParser(keyword, options));\n\telse cursor.recoverToSyncPoint();\n\treturn cursor.finishNode();\n}\nfunction mixinMemberParser(keyword, options) {\n\tif (keyword === \"namespace\") return (inner) => parseDeclaration(inner, true, options);\n\tif (keyword === \"types\") return parseNamedTypeMember;\n\tif (keyword === \"model\" || keyword === \"type\") return parseModelMember;\n\treturn genericBlockMemberParser(keyword, options);\n}\n/**\n* Excluding the reserved keywords keeps a malformed reserved block (e.g. `model\n* {` with no name) routed to its dedicated parser. The generic keyword set is\n* open, so a bare identifier with no brace (e.g. `oops`) is read as an unfinished\n* custom declaration rather than unsupported content.\n*/\nfunction parseGenericBlock(cursor, options) {\n\tif (cursor.peekKind() !== \"Ident\") return void 0;\n\tconst keyword = cursor.peekToken().text;\n\tif (RESERVED_BLOCK_KEYWORDS.has(keyword)) return void 0;\n\tconst hasName = cursor.peekKind(1) === \"Ident\" && cursor.peekKind(2) === \"LBrace\";\n\tcursor.startNode(\"GenericBlockDeclaration\");\n\tcursor.bump();\n\tif (hasName) parseIdentifier(cursor);\n\tif (cursor.peekKind() === \"LBrace\") parseBlockBody(cursor, genericBlockMemberParser(keyword, options));\n\telse {\n\t\tcursor.diagnostic(\"PSL_INVALID_DECLARATION\", `Expected \"{\" to open the \"${keyword}\" block`, cursor.markAfterLastToken());\n\t\tcursor.recoverToSyncPoint();\n\t}\n\treturn cursor.finishNode();\n}\nfunction parseNamespace(cursor, options) {\n\tif (!keywordIs(cursor, \"namespace\")) return void 0;\n\treturn parseBlock(cursor, \"Namespace\", true, (inner) => parseDeclaration(inner, true, options));\n}\nfunction parseCompositeType(cursor) {\n\tif (!keywordIs(cursor, \"type\")) return void 0;\n\treturn parseBlock(cursor, \"CompositeTypeDeclaration\", true, parseModelMember);\n}\n/** `types` (plural) is the no-name types block; the singular `type` is the composite type above. */\nfunction parseTypesBlock(cursor) {\n\tif (!keywordIs(cursor, \"types\")) return void 0;\n\treturn parseBlock(cursor, \"TypesBlock\", false, parseNamedTypeMember);\n}\n/** Every `parseMember` consumes at least one significant token, so the loop always terminates. */\nfunction parseBlockBody(cursor, parseMember) {\n\tconst braceMark = cursor.mark();\n\tcursor.bump();\n\tfor (;;) {\n\t\tconst kind = cursor.peekKind();\n\t\tif (kind === \"RBrace\" || kind === \"Eof\") break;\n\t\tparseMember(cursor);\n\t}\n\tif (cursor.peekKind() === \"RBrace\") cursor.bump();\n\telse cursor.diagnostic(\"PSL_UNTERMINATED_BLOCK\", \"Unterminated block declaration\", braceMark);\n}\nfunction parseUnsupportedTopLevel(cursor) {\n\tconst offending = cursor.peekToken().text;\n\tconst message = cursor.peekKind(1) === \"LBrace\" ? `Unsupported top-level block \"${offending}\"` : `Unsupported top-level declaration \"${offending}\"`;\n\tcursor.diagnostic(\"PSL_UNSUPPORTED_TOP_LEVEL_BLOCK\", message, cursor.mark());\n\tcursor.bump();\n\tcursor.recoverToSyncPoint();\n}\n/**\n* Matches a leading `@@` block attribute, a no-op otherwise. Single-`@`\n* attributes belong to fields and are parsed inside `parseField`.\n*/\nfunction parseBlockAttribute(cursor) {\n\tif (cursor.peekKind() !== \"DoubleAt\") return void 0;\n\treturn parseAttribute(cursor);\n}\nfunction parseMixinInclusion(cursor, memberCode) {\n\tif (cursor.peekKind() !== \"Plus\") return void 0;\n\tconst plusMark = cursor.mark();\n\tcursor.startNode(\"MixinInclusion\");\n\tcursor.bump();\n\tif (cursor.peekKind() === \"Ident\" && !cursor.newlineBefore()) parseQualifiedName(cursor);\n\telse {\n\t\tcursor.diagnostic(memberCode, \"Expected a mixin name after \\\"+\\\"\", plusMark);\n\t\tcursor.recoverToSyncPoint();\n\t}\n\treturn cursor.finishNode();\n}\nfunction parseModelMember(cursor) {\n\tif (!(parseMixinInclusion(cursor, \"PSL_INVALID_MODEL_MEMBER\") ?? parseBlockAttribute(cursor) ?? parseField(cursor))) invalidMember(cursor, \"PSL_INVALID_MODEL_MEMBER\", `Invalid model member declaration \"${cursor.peekToken().text}\"`);\n}\nfunction parseNamedTypeMember(cursor) {\n\tif (!parseNamedType(cursor)) invalidMember(cursor, \"PSL_INVALID_TYPES_MEMBER\", `Invalid types declaration \"${cursor.peekToken().text}\"`);\n}\n/**\n* A generic block reads `key = value` entries and bare keys; in an `enum` block those may carry `@`\n* attributes (`USER @map(\"user\")`). In the `prisma-7` grammar, a `view` body is read like a model\n* body. Each interpreter decides whether it accepts the block and its members.\n*/\nfunction genericBlockMemberParser(keyword, options) {\n\tif (keyword === \"view\" && options.grammar === \"prisma-7\") return parseModelMember;\n\tif (keyword === \"enum\") return parseEnumMember;\n\treturn parseKeyValueMember;\n}\n/**\n* A generic-block member is either a `@@`-block attribute or a `key = value`\n* entry. The block-attribute alternative is purely syntactic — it does not judge\n* whether the attribute is valid for the block's kind.\n*/\nfunction parseKeyValueMember(cursor) {\n\tif (!(parseMixinInclusion(cursor, \"PSL_INVALID_EXTENSION_BLOCK_MEMBER\") ?? parseBlockAttribute(cursor) ?? parseKeyValue(cursor))) invalidMember(cursor, \"PSL_INVALID_EXTENSION_BLOCK_MEMBER\", \"Invalid block entry\");\n}\nfunction parseEnumMember(cursor) {\n\tif (!(parseMixinInclusion(cursor, \"PSL_INVALID_EXTENSION_BLOCK_MEMBER\") ?? parseBlockAttribute(cursor) ?? parseKeyValue(cursor, { memberAttributes: true }))) invalidMember(cursor, \"PSL_INVALID_EXTENSION_BLOCK_MEMBER\", \"Invalid block entry\");\n}\nfunction invalidMember(cursor, code, message) {\n\tcursor.diagnostic(code, message, cursor.mark());\n\tcursor.bump();\n\tcursor.recoverToSyncPoint();\n}\nfunction parseField(cursor) {\n\tif (cursor.peekKind() !== \"Ident\") return void 0;\n\tcursor.startNode(\"FieldDeclaration\");\n\tconst nameMark = cursor.mark();\n\tconst nameText = cursor.peekToken().text;\n\tparseIdentifier(cursor);\n\tif (cursor.peekKind() !== \"Ident\") cursor.diagnostic(\"PSL_INVALID_MODEL_MEMBER\", `Expected a type after field \"${nameText}\"`, nameMark);\n\tparseTypeAnnotation(cursor, \"PSL_INVALID_MODEL_MEMBER\");\n\twhile (cursor.peekKind() === \"At\") parseAttribute(cursor);\n\treturn cursor.finishNode();\n}\nfunction parseNamedType(cursor) {\n\tif (cursor.peekKind() !== \"Ident\") return void 0;\n\tcursor.startNode(\"NamedTypeDeclaration\");\n\tconst nameMark = cursor.mark();\n\tconst nameText = cursor.peekToken().text;\n\tparseIdentifier(cursor);\n\tif (cursor.peekKind() === \"Equals\") cursor.bump();\n\telse cursor.diagnostic(\"PSL_INVALID_TYPES_MEMBER\", `Expected \"=\" after \"${nameText}\"`, nameMark);\n\tparseTypeAnnotation(cursor, \"PSL_INVALID_TYPES_MEMBER\");\n\twhile (cursor.peekKind() === \"At\") parseAttribute(cursor);\n\treturn cursor.finishNode();\n}\n/**\n* A generic-block entry is either `key = value` or a bare `key` (committing a\n* `KeyValuePair` carrying only the key). With `memberAttributes` (enum blocks) any number of `@`\n* attributes may follow, as in `USER @map(\"user\")`. A `key =` with no following expression is\n* flagged.\n*/\nfunction parseKeyValue(cursor, options = { memberAttributes: false }) {\n\tif (cursor.peekKind() !== \"Ident\") return void 0;\n\tcursor.startNode(\"KeyValuePair\");\n\tparseIdentifier(cursor);\n\tif (cursor.peekKind() === \"Equals\") {\n\t\tcursor.bump();\n\t\tconst diagnosticsBefore = cursor.diagnostics.length;\n\t\tconst value = parseExpression(cursor);\n\t\tif (!value) cursor.diagnostic(\"PSL_INVALID_EXTENSION_BLOCK_MEMBER\", \"Expected a value after \\\"=\\\"\", cursor.mark());\n\t\tif (!value || isUnclosed(value)) consumeLeftover(cursor, \"PSL_INVALID_EXTENSION_BLOCK_MEMBER\", \"the entry value\", diagnosticsBefore);\n\t}\n\twhile (options.memberAttributes && cursor.peekKind() === \"At\") parseAttribute(cursor);\n\treturn cursor.finishNode();\n}\n//#endregion\nexport { PslSources as a, greenToken as i, GreenNodeB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I,OAAO,SAAS,MAAM,SAAS,OAAO,KAAK;CAC/C,OAAO,UAAU,cAAc;CAC/B,gBAAgB,MAAM;CACtB,IAAI,OAAO,SAAS,MAAM,UAAU;EACnC,OAAO,KAAK;EACZ,MAAM,oBAAoB,OAAO,YAAY;EAC7C,MAAM,QAAQ,gBAAgB,MAAM;EACpC,IAAI,CAAC,OAAO,OAAO,WAAW,sCAAsC,gCAAgC,OAAO,KAAK,CAAC;EACjH,IAAI,CAAC,SAAS,WAAW,KAAK,GAAG,gBAAgB,QAAQ,sCAAsC,mBAAmB,iBAAiB;CACpI;CACA,OAAO,QAAQ,oBAAoB,OAAO,SAAS,MAAM,MAAM,eAAe,MAAM;CACpF,OAAO,OAAO,WAAW;AAC1B"}
|
|
@@ -2,7 +2,7 @@ import { U as PslSpan } from "./framework-authoring-BaBmrcxi-DV-OErsx.mjs";
|
|
|
2
2
|
import { d as TaggedLiteralCanonicalization } from "./written-value--KnOpj99-BA9i2Wto.mjs";
|
|
3
3
|
import "./authoring-D--mDfh-.mjs";
|
|
4
4
|
import "./psl-ast-Dho77tVl.mjs";
|
|
5
|
-
import { h as PslParserOptions, r as ContractSourceDiagnostic } from "./config-types-
|
|
5
|
+
import { h as PslParserOptions, r as ContractSourceDiagnostic } from "./config-types-DnfvNRK4.mjs";
|
|
6
6
|
import { n as TokenKind, t as Token } from "./tokenizer-i8RaVWVa-7fRwlCPP.mjs";
|
|
7
7
|
//#region ../../../1-framework/2-authoring/psl-parser/dist/parse-CJtBvEYy.d.mts
|
|
8
8
|
//#region src/syntax/syntax-kind.d.ts
|
|
@@ -553,4 +553,4 @@ interface ParseResult {
|
|
|
553
553
|
declare function parse(source: string, filename: string, options?: PslParserOptions): ParseResult;
|
|
554
554
|
//#endregion
|
|
555
555
|
export { TypeAnnotationAst as $, NamespaceDeclarationAst as A, PslDiagnosticCollector as B, IdentifierAst as C, ModelAttributeAst as D, MixinInclusionAst as E, ParseDiagnostic as F, StringLiteralExprAst as G, QualifiedNameAst as H, ParseResult as I, SyntaxKind as J, StringLiteralQuote as K, PathExprAst as L, NumberLiteralExprAst as M, ObjectFieldAst as N, ModelDeclarationAst as O, ObjectLiteralExprAst as P, TokenAtOffset as Q, Position as R, HasDocComment as S, MixinDeclarationAst as T, Range as U, PslSources as V, SourceFile as W, SyntaxToken as X, SyntaxNode as Y, TaggedLiteralExprAst as Z, GenericBlockDeclarationAst as _, AttributeAst as a, diagnosticFromSpan as at, GreenNode as b, BracedBlock as c, filterChildren as ct, DiagnosticSource as d, greenNode as dt, TypesBlockAst as et, DocumentAst as f, greenToken as ft, FunctionCallAst as g, FieldDeclarationAst as h, printSyntax as ht, AttributeArgListAst as i, createSyntaxTree as it, NamespaceMemberAst as j, NamedTypeDeclarationAst as k, CompositeTypeDeclarationAst as l, findChildToken as lt, FieldAttributeAst as m, parse as mt, AstNode as n, castExpression as nt, BlockMemberAst as o, diagnosticSource as ot, ExpressionAst as p, mapPslDiagnostics as pt, SyntaxElement as q, AttributeArgAst as r, createPslDiagnosticCollector as rt, BooleanLiteralExprAst as s, dottedPathsIn as st, ArrayLiteralAst as t, any as tt, DeclarationAst as u, findFirstChild as ut, GenericBlockMemberAst as v, KeyValuePairAst as w, GreenToken as x, GreenElement as y, PslDiagnostic as z };
|
|
556
|
-
//# sourceMappingURL=parse-CJtBvEYy-
|
|
556
|
+
//# sourceMappingURL=parse-CJtBvEYy-CBkiQrF-.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parse-CJtBvEYy-
|
|
1
|
+
{"version":3,"file":"parse-CJtBvEYy-CBkiQrF-.d.mts","names":[],"sources":["../../../../1-framework/2-authoring/psl-parser/dist/parse-CJtBvEYy.d.mts"],"mappings":";;;;;;;;KAKK;;;UAGK;WACC;WACA,MAAM;WACN;;UAED;WACC;WACA,MAAM;WACN,UAAU,cAAc;WACxB;;KAEN,eAAe,YAAY;iBACf,WAAW,MAAM,WAAW,eAAe;iBAC3C,UAAU,MAAM,YAAY,UA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U;EACV,gBAAgB,SAAS;SAClB,KAAK,MAAM,aAAa;;cAEnB,sCAAsC,aAAa;WACtD,QAAQ;EACjB,YAAY,QAAQ;EACpB,WAAW;EACX,QAAQ;EACR,UAAU;EACV,UAAU;EACV,WAAW,SAAS;;EAEpB,UAAU,SAAS;EACnB,cAAc,SAAS;EACvB,cAAc,SAAS;EACvB,WAAW,SAAS;EACpB;SACO,KAAK,MAAM,aAAa;;cAEnB,+BAA+B,aAAa;WAC/C,QAAQ;EACjB,YAAY,QAAQ;EACpB,WAAW;EACX,gBAAgB;EAChB,QAAQ;EACR,UAAU;EACV,UAAU;EACV,UAAU,SAAS;EACnB,WAAW,SAAS;EACpB,cAAc,SAAS;;EAEvB,cAAc,SAAS;EACvB,WAAW,SAAS,iBAAiB;EACrC;SACO,KAAK,MAAM,aAAa;;cAEnB,6BAA6B;WAChC,QAAQ;EACjB,YAAY,QAAQ;EACpB,QAAQ;EACR,QAAQ;SACD,KAAK,MAAM,aAAa;;cAEnB,2BAA2B;WAC9B,QAAQ;EACjB,YAAY,QAAQ;EACpB,OAAO;EACP,UAAU;EACV,SAAS;;EAET,cAAc,SAAS;SAChB,KAAK,MAAM,aAAa;;cAEnB,+BAA+B,SAAS;WAC3C,QAAQ;EACjB,YAAY,QAAQ;EACpB,QAAQ;EACR,kBAAkB;EAClB,cAAc,SAAS;EACvB;SACO,KAAK,MAAM,aAAa;;cAEnB,mCAAmC,SAAS;WAC/C,QAAQ;EACjB,YAAY,QAAQ;EACpB,QAAQ;EACR,UAAU;EACV,kBAAkB;EAClB,cAAc,SAAS;EACvB;SACO,KAAK,MAAM,aAAa;;;;KAI5B,kBAAkB;UACb;WACC,UAAU;WACV,sBAAsB;WACtB,SAAS;;;;;;iBAMH,MAAM,gBAAgB,kBAAkB,UAAU,mBAAmB"}
|
package/dist/psl-parser.d.mts
CHANGED
|
@@ -6,11 +6,11 @@ import { m as WrittenScalar, n as DataTypeSupport } from "./written-value--KnOpj
|
|
|
6
6
|
import "./authoring-D--mDfh-.mjs";
|
|
7
7
|
import "./codec-DXDkDjYm.mjs";
|
|
8
8
|
import { C as PslTypesBlock, O as flatPslModels, S as PslTypeConstructorCall, _ as PslModelAttribute, a as PslAttributePositionalArgument, c as PslDefaultFunctionValue, f as PslDocumentAst, g as PslModel, i as PslAttributeNamedArgument, j as namespacePslExtensionBlocks, l as PslDefaultLiteralValue, m as PslFieldAttribute, n as PslAttribute, o as PslAttributeTarget, p as PslField, r as PslAttributeArgument, s as PslCompositeType, u as PslDefaultValue, v as PslNamedTypeDeclaration, y as PslNamespace } from "./psl-ast-BER6m646-c8XvWGXr.mjs";
|
|
9
|
-
import { r as AssembledAuthoringContributions } from "./control-
|
|
9
|
+
import { r as AssembledAuthoringContributions } from "./control-510XVXM6.mjs";
|
|
10
10
|
import "./psl-ast-Dho77tVl.mjs";
|
|
11
11
|
import { i as isPslIdentifier } from "./tokenizer-i8RaVWVa-7fRwlCPP.mjs";
|
|
12
|
-
import { B as PslDiagnosticCollector, D as ModelAttributeAst, V as PslSources, Y as SyntaxNode, at as diagnosticFromSpan, d as DiagnosticSource, m as FieldAttributeAst, n as AstNode, ot as diagnosticSource, p as ExpressionAst, pt as mapPslDiagnostics, r as AttributeArgAst, rt as createPslDiagnosticCollector, z as PslDiagnostic } from "./parse-CJtBvEYy-
|
|
13
|
-
import { $ as ModelSymbol, A as DescribeUnresolvedType, At as SymbolTableResult, B as FixedStrArgType, Bt as
|
|
12
|
+
import { B as PslDiagnosticCollector, D as ModelAttributeAst, V as PslSources, Y as SyntaxNode, at as diagnosticFromSpan, d as DiagnosticSource, m as FieldAttributeAst, n as AstNode, ot as diagnosticSource, p as ExpressionAst, pt as mapPslDiagnostics, r as AttributeArgAst, rt as createPslDiagnosticCollector, z as PslDiagnostic } from "./parse-CJtBvEYy-CBkiQrF-.mjs";
|
|
13
|
+
import { $ as ModelSymbol, A as DescribeUnresolvedType, At as SymbolTableResult, B as FixedStrArgType, Bt as createBinder, C as ContributedTypeNamespace, Ct as ResolvedAttributeArg, D as CtxOf, Dt as Scope, E as CreateBinderInput, Et as ResolvedTypeConstructorCall, F as FieldAttributeCtx, Ft as UnrestrictedNumArgType, G as InferAttr, Gt as memberEntries, H as FuncCallSig, Ht as isNamespaceLike, I as FieldRefArgType, It as UnrestrictedStrArgType, J as JsonArgType, Jt as readResolvedAttributes, K as InspectableArgType, Kt as nodePslSpan, L as FieldSymbol, Lt as UnsupportedAttribute, M as EntityDeclaration, Mt as TypedFuncCall, N as EntityRefArgType, Nt as UnresolvedTypeReference, O as DataTypeValueArgType, Ot as ScopeResolution, P as EntitySelector, Pt as UnrestrictedIdentifierArgType, Q as ModelAttributeCtx, R as FixedIdentifierArgType, Rt as buildSymbolTable, S as ContributedTypeDescriptor, St as ResolvedAttribute, T as ContributedTypeSymbol, Tt as ResolvedNamedTypeBinding, U as FunctionSymbol, Ut as keywordPslSpan, V as FuncCallArgType, Vt as entityReference, W as IdentifierArgType, Wt as matchesSelector, X as ListArgType, Xt as typeReferenceNode, Y as JsonValueArgType, Yt as readResolvedConstructorCall, Z as MixinSymbol, _ as CompositeTypeSymbol, _t as RecordArgType, a as AttributeLevel, at as NumLiteralArgType, b as ContributedMember, bt as RequiredContextFor, c as AttributeSymbol, ct as OutOf, d as BinderResult, dt as ParameterSymbol, et as NamedOut, f as BlockAttributeCtx, ft as ParsedTaggedLiteral, g as BuildSymbolTableOptions, gt as PslSymbol, h as BoundSpec, ht as PositionalParam, i as AttributeCtx, it as NumLiteral, j as DescribeUnsupportedAttribute, jt as TaggedLiteralArgType, k as DeclarationFor, kt as SymbolTable, l as Binder, lt as PSL_UNRESOLVED_REFERENCE, m as BoolArgType, mt as PosOut, n as ArgType, nt as NamespaceSymbol, o as AttributeOut, ot as OneOfArgType, p as BlockSymbol, pt as ParsedTypedValue, q as IntArgType, qt as readResolvedAttribute, r as ArgTypeKind, rt as NullArgType, s as AttributeSpec, st as OptionalArgType, t as AnyArgType, tt as NamedTypeSymbol, u as BinderContext, ut as Param, v as ConstantSymbol, vt as ReferencedFieldRefArgType, w as ContributedTypeScope, wt as ResolvedEntityReference, x as ContributedNamespaceSymbol, xt as Resolution, y as ContextForRequirement, yt as RejectingArgType, z as FixedNumArgType, zt as contributedTypeOf } from "./binder-Eeh-nJsx-BkT5IXHe.mjs";
|
|
14
14
|
//#region ../../../1-framework/2-authoring/psl-parser/dist/index.d.mts
|
|
15
15
|
//#region src/attribute-helpers.d.ts
|
|
16
16
|
declare function getPositionalArgument(attribute: PslAttribute, index?: number): string | undefined;
|
|
@@ -320,5 +320,5 @@ type WrittenScalarResult = {
|
|
|
320
320
|
/** Reads a PSL literal expression as a `WrittenScalar`, for a position that takes a value of a data type. ADR 254. */
|
|
321
321
|
declare function readWrittenScalar(expression: ExpressionAst): WrittenScalarResult;
|
|
322
322
|
//#endregion
|
|
323
|
-
export { type ArgBindingSpec, type ArgType, type ArgTypeKind, type AssembledAttributeSpecs, type AttributeCtx, type AttributeLevel, type AttributeOut, type AttributeSpec, type AttributeSpecContext, type AttributeSpecNamespace, type AttributeSymbol, type Binder, type BinderContext, type BinderResult, type BlockAttributeCtx, type BlockAttributeSpecFactory, type BlockEntryValueSpec, type BlockSpec, type BlockSpecContext, type BlockSpecFactory, type BlockSymbol, type BoundSpec, type BuildSymbolTableOptions, type CompositeTypeSymbol, type ConstantSymbol, type ContributedMember, type ContributedNamespaceSymbol, type ContributedTypeDescriptor, type ContributedTypeNamespace, type ContributedTypeScope, type ContributedTypeSymbol, type CreateBinderInput, type DataTypeValueArgType, type DeclarationFor, type DescribeUnresolvedType, type DescribeUnsupportedAttribute, type DiagnosticSource, EMPTY_DATA_TYPES, type EntityDeclaration, type EntityRefArgType, type EntitySelector, type FieldAttributeCtx, type FieldAttributeSpecContext, type FieldAttributeSpecFactory, type FieldSymbol, type FixedIdentifierArgType, type FuncCallSig, type FunctionSymbol, type IdentifierArgType, type InferAttr, type InferBlock, type InspectableArgType, type InterpretExtensionBlockAttributesInput, type InterpretExtensionBlockInput, type InterpretExtensionBlocksResult, type JsonValueArgType, type ListOptions, type MapBlockSpec, type MixinSymbol, type ModelAttributeCtx, type ModelAttributeSpecFactory, type ModelSymbol, NAME_THE_PSL_SOURCE_LOSES, type NamedOut, type NamedTypeSymbol, type NamespaceSymbol, type NullArgType, type NumLiteral, type OptionalArgType, type OutOf, PSL_UNRESOLVED_REFERENCE, type Param, type ParameterSymbol, type ParsedPslExtensionBlock, type ParsedTaggedLiteral, type ParsedTypedValue, type ParsedWrittenList, type ParsedWrittenScalar, type PosOut, type PositionalParam, type PslAttribute, type PslAttributeArgument, type PslAttributeNamedArgument, type PslAttributePositionalArgument, type PslAttributeTarget, type PslBlockSpecDescriptor, type PslCompositeType, type PslDefaultFunctionValue, type PslDefaultLiteralValue, type PslDefaultValue, type PslDiagnostic, type PslDiagnosticCode, type PslDiagnosticCollector, type PslDocumentAst, type PslExtensionBlock, type PslExtensionBlockAttribute, type PslExtensionBlockAttributeArg, type PslExtensionBlockParsedAttribute, type PslExtensionBlockPrintEntry, type PslField, type PslFieldAttribute, type PslModel, type PslModelAttribute, type PslNamedTypeDeclaration, type PslNamespace, type PslPosition, type PslSpan, type PslSymbol, type PslTypeConstructorCall, type PslTypesBlock, type RejectingArgType, type Resolution, type ResolvedAttribute, type ResolvedAttributeArg, type ResolvedEntityReference, type ResolvedNamedTypeBinding, type ResolvedTypeConstructorCall, type Scope, type ScopeResolution, type StructBlockSpec, type SymbolTable, type SymbolTableResult, type TaggedLiteralArgType, type
|
|
323
|
+
export { type ArgBindingSpec, type ArgType, type ArgTypeKind, type AssembledAttributeSpecs, type AttributeCtx, type AttributeLevel, type AttributeOut, type AttributeSpec, type AttributeSpecContext, type AttributeSpecNamespace, type AttributeSymbol, type Binder, type BinderContext, type BinderResult, type BlockAttributeCtx, type BlockAttributeSpecFactory, type BlockEntryValueSpec, type BlockSpec, type BlockSpecContext, type BlockSpecFactory, type BlockSymbol, type BoundSpec, type BuildSymbolTableOptions, type CompositeTypeSymbol, type ConstantSymbol, type ContributedMember, type ContributedNamespaceSymbol, type ContributedTypeDescriptor, type ContributedTypeNamespace, type ContributedTypeScope, type ContributedTypeSymbol, type CreateBinderInput, type DataTypeValueArgType, type DeclarationFor, type DescribeUnresolvedType, type DescribeUnsupportedAttribute, type DiagnosticSource, EMPTY_DATA_TYPES, type EntityDeclaration, type EntityRefArgType, type EntitySelector, type FieldAttributeCtx, type FieldAttributeSpecContext, type FieldAttributeSpecFactory, type FieldSymbol, type FixedIdentifierArgType, type FuncCallSig, type FunctionSymbol, type IdentifierArgType, type InferAttr, type InferBlock, type InspectableArgType, type InterpretExtensionBlockAttributesInput, type InterpretExtensionBlockInput, type InterpretExtensionBlocksResult, type JsonValueArgType, type ListOptions, type MapBlockSpec, type MixinSymbol, type ModelAttributeCtx, type ModelAttributeSpecFactory, type ModelSymbol, NAME_THE_PSL_SOURCE_LOSES, type NamedOut, type NamedTypeSymbol, type NamespaceSymbol, type NullArgType, type NumLiteral, type OptionalArgType, type OutOf, PSL_UNRESOLVED_REFERENCE, type Param, type ParameterSymbol, type ParsedPslExtensionBlock, type ParsedTaggedLiteral, type ParsedTypedValue, type ParsedWrittenList, type ParsedWrittenScalar, type PosOut, type PositionalParam, type PslAttribute, type PslAttributeArgument, type PslAttributeNamedArgument, type PslAttributePositionalArgument, type PslAttributeTarget, type PslBlockSpecDescriptor, type PslCompositeType, type PslDefaultFunctionValue, type PslDefaultLiteralValue, type PslDefaultValue, type PslDiagnostic, type PslDiagnosticCode, type PslDiagnosticCollector, type PslDocumentAst, type PslExtensionBlock, type PslExtensionBlockAttribute, type PslExtensionBlockAttributeArg, type PslExtensionBlockParsedAttribute, type PslExtensionBlockPrintEntry, type PslField, type PslFieldAttribute, type PslModel, type PslModelAttribute, type PslNamedTypeDeclaration, type PslNamespace, type PslPosition, type PslSpan, type PslSymbol, type PslTypeConstructorCall, type PslTypesBlock, type RejectingArgType, type Resolution, type ResolvedAttribute, type ResolvedAttributeArg, type ResolvedEntityReference, type ResolvedNamedTypeBinding, type ResolvedTypeConstructorCall, type Scope, type ScopeResolution, type StructBlockSpec, type SymbolTable, type SymbolTableResult, type TaggedLiteralArgType, type TypedFuncCall, type UnresolvedTypeReference, type UnrestrictedIdentifierArgType, type UnsupportedAttribute, type WrittenScalarResult, assembleAttributeSpecs, blockAttribute, blockSpecContext, blockSpecFactoryOf, bool, buildSymbolTable, contributedTypeOf, createBinder, createPslDiagnosticCollector, dataTypeValue, diagnosticFromSpan, diagnosticSource, entityRef, entityReference, fieldAttribute, fieldRef, findBlockDescriptor, flatPslModels, funcCall, getPositionalArgument, identifier, int, interpretArgs, interpretAttribute, interpretExtensionBlock, interpretExtensionBlockAttributes, interpretExtensionBlocks, isNamespaceLike, isPrismaNextSchema, isPslIdentifier, json, jsonValue, keywordPslSpan, leafDiagnostic, list, mapArg, mapBlock, mapPslDiagnostics, matchesSelector, memberEntries, modelAttribute, namespacePslExtensionBlocks, nodePslSpan, num, numLiteral, oneOf, optional, parseQuotedStringLiteral, readResolvedAttribute, readResolvedAttributes, readResolvedConstructorCall, readWrittenScalar, record, referencedFieldRef, renameLegacyDirective, str, structBlock, taggedLiteral, typeReferenceNode, writtenList, writtenScalar };
|
|
324
324
|
//# sourceMappingURL=psl-parser.d.mts.map
|
package/dist/psl-parser.mjs
CHANGED
|
@@ -3,13 +3,14 @@ import { t as InternalError } from "./internal-error-ChGYPVpq-DhUD05u0.mjs";
|
|
|
3
3
|
import { a as or, i as okVoid, n as notOk, r as ok, t as and } from "./result-8OXF26MN.mjs";
|
|
4
4
|
import { r as createDataTypeLookup } from "./data-type-4xQlxYB5-DD158cOq.mjs";
|
|
5
5
|
import { S as isAuthoringPslBlockDescriptor, f as describeTaggedLiteralFailure, x as isAuthoringModelAttributeDescriptor } from "./temporal-presets-DEyPX8qQ-Bz4DdZ8v.mjs";
|
|
6
|
+
import { r as UNBOUND_NAMESPACE_ID } from "./namespace-VUH2dgnS-By5y75h9.mjs";
|
|
6
7
|
import { a as describeExpected, b as tagForm, i as describeAdmittedForms, n as admittedTags, o as describeRefusal, p as exactRewrite, r as castTypedValue, t as admittedForms, y as readWrittenValue } from "./authoring-axlemDvs.mjs";
|
|
7
|
-
import { a as flatPslModels, c as namespacePslExtensionBlocks } from "./psl-ast-CyvE6CR-.mjs";
|
|
8
|
+
import { a as flatPslModels, c as namespacePslExtensionBlocks, n as UNBOUND_PSL_NAMESPACE_NAME } from "./psl-ast-CyvE6CR-.mjs";
|
|
8
9
|
import { l as printSyntax } from "./ast-helpers-CzydMPdh-Mi0SrZRa.mjs";
|
|
9
10
|
import { n as isPslIdentifier } from "./tokenizer-C-GTKKjR-B1vOzJy0.mjs";
|
|
10
11
|
import { D as TypesBlockAst, S as PathExprAst, T as TaggedLiteralExprAst, a as CompositeTypeDeclarationAst, c as FieldDeclarationAst, d as IdentifierAst, f as KeyValuePairAst, g as ModelDeclarationAst, h as ModelAttributeAst, i as BooleanLiteralExprAst, l as FunctionCallAst, p as MixinDeclarationAst, t as ArrayLiteralAst, u as GenericBlockDeclarationAst, v as NamespaceDeclarationAst, w as StringLiteralExprAst, x as ObjectLiteralExprAst, y as NumberLiteralExprAst } from "./declarations-DuSbyF44-Bee8mK-C.mjs";
|
|
11
12
|
import { a as mapPslDiagnostics, c as readResolvedAttributes, i as keywordPslSpan, l as readResolvedConstructorCall, n as diagnosticFromSpan, o as nodePslSpan, r as diagnosticSource, s as readResolvedAttribute, t as createPslDiagnosticCollector } from "./resolve-C8PUf8zv-QAvnPhCt.mjs";
|
|
12
|
-
//#region ../../../1-framework/2-authoring/psl-parser/dist/binder-
|
|
13
|
+
//#region ../../../1-framework/2-authoring/psl-parser/dist/binder-C1D2hDgY.mjs
|
|
13
14
|
function* modelAttributeDescriptors(namespace) {
|
|
14
15
|
for (const value of Object.values(namespace)) {
|
|
15
16
|
if (isAuthoringModelAttributeDescriptor(value)) {
|
|
@@ -219,6 +220,15 @@ function findBlockDescriptor(descriptors, keyword) {
|
|
|
219
220
|
if (nested !== void 0) return nested;
|
|
220
221
|
}
|
|
221
222
|
}
|
|
223
|
+
function namespaceIdOfPslName(name) {
|
|
224
|
+
return name === "unbound" ? UNBOUND_NAMESPACE_ID : name;
|
|
225
|
+
}
|
|
226
|
+
function pslNameOfNamespaceId(id) {
|
|
227
|
+
return id === "__unbound__" ? UNBOUND_PSL_NAMESPACE_NAME : id;
|
|
228
|
+
}
|
|
229
|
+
function pslNamesOfNamespaceId(id) {
|
|
230
|
+
return id === "__unbound__" ? [UNBOUND_PSL_NAMESPACE_NAME, UNBOUND_NAMESPACE_ID] : [id];
|
|
231
|
+
}
|
|
222
232
|
function* recordNames(...records) {
|
|
223
233
|
for (const record of records) yield* Object.keys(record);
|
|
224
234
|
}
|
|
@@ -288,48 +298,31 @@ var ContributedScope = class extends Scope {
|
|
|
288
298
|
}
|
|
289
299
|
};
|
|
290
300
|
var DocumentScope = class extends Scope {
|
|
291
|
-
#
|
|
292
|
-
constructor(
|
|
301
|
+
#symbols;
|
|
302
|
+
constructor(symbols, parent) {
|
|
293
303
|
super(parent);
|
|
294
|
-
this.#
|
|
304
|
+
this.#symbols = symbols;
|
|
295
305
|
}
|
|
296
306
|
lookup(name) {
|
|
297
|
-
const
|
|
298
|
-
const
|
|
299
|
-
if (
|
|
300
|
-
|
|
301
|
-
symbol: model
|
|
302
|
-
};
|
|
303
|
-
const compositeType = records.compositeTypes[name];
|
|
304
|
-
if (compositeType !== void 0) return {
|
|
305
|
-
kind: "compositeType",
|
|
306
|
-
symbol: compositeType
|
|
307
|
-
};
|
|
308
|
-
const namedType = records.namedTypes[name];
|
|
307
|
+
const { defaultNamespace, namedTypes, namespaces } = this.#symbols;
|
|
308
|
+
const member = namespaceMember(defaultNamespace, name);
|
|
309
|
+
if (member !== void 0) return member;
|
|
310
|
+
const namedType = namedTypes[name];
|
|
309
311
|
if (namedType !== void 0) return {
|
|
310
312
|
kind: "namedType",
|
|
311
313
|
symbol: namedType
|
|
312
314
|
};
|
|
313
|
-
const
|
|
314
|
-
if (block !== void 0) return {
|
|
315
|
-
kind: "block",
|
|
316
|
-
symbol: block
|
|
317
|
-
};
|
|
318
|
-
const mixin = records.mixins[name];
|
|
319
|
-
if (mixin !== void 0) return {
|
|
320
|
-
kind: "mixin",
|
|
321
|
-
symbol: mixin
|
|
322
|
-
};
|
|
323
|
-
const namespace = records.namespaces[name];
|
|
315
|
+
const namespace = namespaces[namespaceIdOfPslName(name)];
|
|
324
316
|
if (namespace !== void 0) return {
|
|
325
317
|
kind: "namespace",
|
|
326
318
|
symbol: namespace
|
|
327
319
|
};
|
|
328
320
|
return this.parent?.lookup(name);
|
|
329
321
|
}
|
|
330
|
-
ownNames() {
|
|
331
|
-
const
|
|
332
|
-
|
|
322
|
+
*ownNames() {
|
|
323
|
+
const { defaultNamespace, namedTypes, namespaces } = this.#symbols;
|
|
324
|
+
yield* recordNames(defaultNamespace.models, defaultNamespace.compositeTypes, namedTypes, defaultNamespace.blocks, defaultNamespace.mixins);
|
|
325
|
+
for (const namespace of Object.values(namespaces)) yield namespace.name;
|
|
333
326
|
}
|
|
334
327
|
};
|
|
335
328
|
var NamespaceScope = class extends Scope {
|
|
@@ -349,12 +342,12 @@ var NamespaceScope = class extends Scope {
|
|
|
349
342
|
function contributedScope(registry) {
|
|
350
343
|
return new ContributedScope(registry);
|
|
351
344
|
}
|
|
352
|
-
function documentScope(
|
|
353
|
-
return new DocumentScope(
|
|
345
|
+
function documentScope(symbols, parent) {
|
|
346
|
+
return new DocumentScope(symbols, parent);
|
|
354
347
|
}
|
|
355
|
-
function namedTypeBaseScope(
|
|
348
|
+
function namedTypeBaseScope(symbols, parent) {
|
|
356
349
|
return new DocumentScope({
|
|
357
|
-
...
|
|
350
|
+
...symbols,
|
|
358
351
|
namedTypes: {}
|
|
359
352
|
}, parent);
|
|
360
353
|
}
|
|
@@ -383,7 +376,7 @@ function lookupMember(qualifier, name) {
|
|
|
383
376
|
* should consume first-wins symbols rather than re-emitting duplicate diagnostics.
|
|
384
377
|
*/
|
|
385
378
|
function buildSymbolTable(options) {
|
|
386
|
-
const { documents, sources } = options;
|
|
379
|
+
const { documents, sources, defaultNamespaceId } = options;
|
|
387
380
|
const diagnostics = [];
|
|
388
381
|
const namespaces = Object.create(null);
|
|
389
382
|
const namedTypes = Object.create(null);
|
|
@@ -391,7 +384,18 @@ function buildSymbolTable(options) {
|
|
|
391
384
|
const models = Object.create(null);
|
|
392
385
|
const compositeTypes = Object.create(null);
|
|
393
386
|
const mixins = Object.create(null);
|
|
394
|
-
const topLevelNames =
|
|
387
|
+
const topLevelNames = new Set(pslNamesOfNamespaceId(defaultNamespaceId));
|
|
388
|
+
const defaultNamespace = {
|
|
389
|
+
kind: "namespace",
|
|
390
|
+
id: defaultNamespaceId,
|
|
391
|
+
name: pslNameOfNamespaceId(defaultNamespaceId),
|
|
392
|
+
declarations: [],
|
|
393
|
+
models,
|
|
394
|
+
compositeTypes,
|
|
395
|
+
blocks,
|
|
396
|
+
mixins
|
|
397
|
+
};
|
|
398
|
+
namespaces[defaultNamespaceId] = defaultNamespace;
|
|
395
399
|
for (const document of documents) {
|
|
396
400
|
const sourceFile = sources.sourceFileFor(document.syntax);
|
|
397
401
|
const claim = (taken, name) => {
|
|
@@ -425,13 +429,16 @@ function buildSymbolTable(options) {
|
|
|
425
429
|
} else if (declaration instanceof NamespaceDeclarationAst) {
|
|
426
430
|
const declaredName = declaration.name()?.name();
|
|
427
431
|
if (declaredName === void 0) continue;
|
|
428
|
-
|
|
432
|
+
const id = namespaceIdOfPslName(declaredName);
|
|
433
|
+
let namespace = namespaces[id];
|
|
429
434
|
if (namespace === void 0) {
|
|
430
|
-
const
|
|
431
|
-
if (name === void 0) continue;
|
|
435
|
+
const names = pslNamesOfNamespaceId(id);
|
|
436
|
+
if (claim(names.some((name) => topLevelNames.has(name)) ? new Set(names) : topLevelNames, declaration.name()) === void 0) continue;
|
|
437
|
+
for (const name of names) topLevelNames.add(name);
|
|
432
438
|
namespace = {
|
|
433
439
|
kind: "namespace",
|
|
434
|
-
|
|
440
|
+
id,
|
|
441
|
+
name: pslNameOfNamespaceId(id),
|
|
435
442
|
declarations: [{
|
|
436
443
|
node: declaration,
|
|
437
444
|
span: nodePslSpan(declaration.syntax, sources)
|
|
@@ -441,12 +448,12 @@ function buildSymbolTable(options) {
|
|
|
441
448
|
blocks: Object.create(null),
|
|
442
449
|
mixins: Object.create(null)
|
|
443
450
|
};
|
|
444
|
-
namespaces[
|
|
451
|
+
namespaces[id] = namespace;
|
|
445
452
|
} else namespace.declarations.push({
|
|
446
453
|
node: declaration,
|
|
447
454
|
span: nodePslSpan(declaration.syntax, sources)
|
|
448
455
|
});
|
|
449
|
-
extendNamespace(namespace, declaration, diagnostics, sources);
|
|
456
|
+
extendNamespace(namespace, declaration, diagnostics, sources, namespace === defaultNamespace ? topLevelNames : /* @__PURE__ */ new Set());
|
|
450
457
|
} else if (declaration instanceof TypesBlockAst) for (const binding of declaration.declarations()) {
|
|
451
458
|
const name = claim(topLevelNames, binding.name());
|
|
452
459
|
if (name === void 0) continue;
|
|
@@ -461,14 +468,11 @@ function buildSymbolTable(options) {
|
|
|
461
468
|
}
|
|
462
469
|
}
|
|
463
470
|
return {
|
|
464
|
-
symbolTable: {
|
|
471
|
+
symbolTable: {
|
|
472
|
+
defaultNamespace,
|
|
465
473
|
namespaces,
|
|
466
|
-
namedTypes
|
|
467
|
-
|
|
468
|
-
models,
|
|
469
|
-
compositeTypes,
|
|
470
|
-
mixins
|
|
471
|
-
} },
|
|
474
|
+
namedTypes
|
|
475
|
+
},
|
|
472
476
|
diagnostics
|
|
473
477
|
};
|
|
474
478
|
}
|
|
@@ -518,12 +522,12 @@ function buildMixin(name, node, sources, diagnostics) {
|
|
|
518
522
|
attributes: readResolvedAttributes(node.attributes(), sources)
|
|
519
523
|
};
|
|
520
524
|
}
|
|
521
|
-
function extendNamespace(namespace, node, diagnostics, sources) {
|
|
525
|
+
function extendNamespace(namespace, node, diagnostics, sources, documentNames) {
|
|
522
526
|
const { models, compositeTypes, blocks, mixins } = namespace;
|
|
523
527
|
for (const member of node.declarations()) {
|
|
524
528
|
const memberName = member.name()?.name();
|
|
525
529
|
if (memberName === void 0) continue;
|
|
526
|
-
if (Object.hasOwn(models, memberName) || Object.hasOwn(compositeTypes, memberName) || Object.hasOwn(blocks, memberName) || Object.hasOwn(mixins, memberName)) {
|
|
530
|
+
if (Object.hasOwn(models, memberName) || Object.hasOwn(compositeTypes, memberName) || Object.hasOwn(blocks, memberName) || Object.hasOwn(mixins, memberName) || documentNames.has(memberName)) {
|
|
527
531
|
const range = nameRange(member.name(), sources);
|
|
528
532
|
if (range) diagnostics.push({
|
|
529
533
|
code: "PSL_DUPLICATE_DECLARATION",
|
|
@@ -533,6 +537,7 @@ function extendNamespace(namespace, node, diagnostics, sources) {
|
|
|
533
537
|
});
|
|
534
538
|
continue;
|
|
535
539
|
}
|
|
540
|
+
documentNames.add(memberName);
|
|
536
541
|
if (member instanceof ModelDeclarationAst) models[memberName] = buildModel(memberName, member, sources, diagnostics);
|
|
537
542
|
else if (member instanceof CompositeTypeDeclarationAst) compositeTypes[memberName] = buildCompositeType(memberName, member, sources, diagnostics);
|
|
538
543
|
else if (member instanceof GenericBlockDeclarationAst) blocks[memberName] = buildBlock(memberName, member, sources);
|
|
@@ -540,9 +545,8 @@ function extendNamespace(namespace, node, diagnostics, sources) {
|
|
|
540
545
|
}
|
|
541
546
|
}
|
|
542
547
|
function placeMixinMembers(input) {
|
|
543
|
-
const { topLevel } = input.symbolTable;
|
|
544
548
|
const diagnostics = [];
|
|
545
|
-
for (const records of
|
|
549
|
+
for (const records of Object.values(input.symbolTable.namespaces)) {
|
|
546
550
|
for (const symbol of Object.values(records.models)) placeFields(symbol, input, diagnostics);
|
|
547
551
|
for (const symbol of Object.values(records.compositeTypes)) placeFields(symbol, input, diagnostics);
|
|
548
552
|
for (const symbol of Object.values(records.blocks)) placeEntries(symbol, input, diagnostics);
|
|
@@ -779,17 +783,16 @@ function hasFields(mixin) {
|
|
|
779
783
|
return FIELD_MIXIN_KEYWORDS.has(mixin.keyword);
|
|
780
784
|
}
|
|
781
785
|
function walkFieldOwners(symbolTable, stack, binder, visit) {
|
|
782
|
-
const { topLevel } = symbolTable;
|
|
783
786
|
const visitAll = (records, namespace) => {
|
|
784
787
|
for (const entity of Object.values(records.models)) visit(entity, namespace);
|
|
785
788
|
for (const entity of Object.values(records.compositeTypes)) visit(entity, namespace);
|
|
786
789
|
for (const mixin of Object.values(records.mixins)) if (hasFields(mixin)) visit(mixin, namespace);
|
|
787
790
|
};
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
stack.push(binder.scopeAt(
|
|
791
|
+
for (const namespace of Object.values(symbolTable.namespaces)) {
|
|
792
|
+
const [declaration] = namespace.declarations;
|
|
793
|
+
if (declaration !== void 0) stack.push(binder.scopeAt(declaration.node.syntax));
|
|
791
794
|
visitAll(namespace, namespace);
|
|
792
|
-
stack.pop();
|
|
795
|
+
if (declaration !== void 0) stack.pop();
|
|
793
796
|
}
|
|
794
797
|
}
|
|
795
798
|
function isWrittenIn(member, holder) {
|
|
@@ -805,11 +808,11 @@ function declarationResolution(entity, namespace) {
|
|
|
805
808
|
return entity.kind === "model" ? {
|
|
806
809
|
kind: "model",
|
|
807
810
|
symbol: entity,
|
|
808
|
-
|
|
811
|
+
namespace
|
|
809
812
|
} : {
|
|
810
813
|
kind: "compositeType",
|
|
811
814
|
symbol: entity,
|
|
812
|
-
|
|
815
|
+
namespace
|
|
813
816
|
};
|
|
814
817
|
}
|
|
815
818
|
function createBinder(input) {
|
|
@@ -833,15 +836,15 @@ function bind(options) {
|
|
|
833
836
|
const { sources, symbolTable, contributedTypes, attributeSpecs, defaultFunctionRegistry, dataTypes, describeUnsupportedAttribute, describeUnresolvedType } = options;
|
|
834
837
|
const pslBlockDescriptors = options.pslBlockDescriptors ?? {};
|
|
835
838
|
const contributed = contributedScope(contributedTypeScope(contributedTypes));
|
|
836
|
-
const document = documentScope(symbolTable
|
|
839
|
+
const document = documentScope(symbolTable, contributed);
|
|
837
840
|
const stack = new ScopeStack(document);
|
|
838
841
|
const scopes = /* @__PURE__ */ new WeakMap();
|
|
839
842
|
const declarations = /* @__PURE__ */ new WeakMap();
|
|
840
843
|
const references = /* @__PURE__ */ new WeakMap();
|
|
841
844
|
const diagnostics = [];
|
|
842
845
|
const binder = new PslBinder(declarations, references, document, scopes);
|
|
843
|
-
const baseScope = namedTypeBaseScope(symbolTable
|
|
844
|
-
for (const symbol of Object.values(symbolTable.
|
|
846
|
+
const baseScope = namedTypeBaseScope(symbolTable, contributed);
|
|
847
|
+
for (const symbol of Object.values(symbolTable.namedTypes)) {
|
|
845
848
|
declarations.set(symbol.node.syntax, symbol);
|
|
846
849
|
const declaredName = symbol.node.name()?.syntax;
|
|
847
850
|
if (declaredName !== void 0) references.set(declaredName, {
|
|
@@ -859,24 +862,8 @@ function bind(options) {
|
|
|
859
862
|
diagnostics
|
|
860
863
|
});
|
|
861
864
|
}
|
|
862
|
-
for (const
|
|
863
|
-
|
|
864
|
-
const declaredName = symbol.node.name()?.syntax;
|
|
865
|
-
if (declaredName !== void 0) references.set(declaredName, {
|
|
866
|
-
kind: "block",
|
|
867
|
-
symbol
|
|
868
|
-
});
|
|
869
|
-
}
|
|
870
|
-
for (const symbol of Object.values(symbolTable.topLevel.mixins)) {
|
|
871
|
-
declarations.set(symbol.node.syntax, symbol);
|
|
872
|
-
const declaredName = symbol.node.name()?.syntax;
|
|
873
|
-
if (declaredName !== void 0) references.set(declaredName, {
|
|
874
|
-
kind: "mixin",
|
|
875
|
-
symbol
|
|
876
|
-
});
|
|
877
|
-
}
|
|
878
|
-
for (const namespace of Object.values(symbolTable.topLevel.namespaces)) {
|
|
879
|
-
const scope = namespaceScope(namespace, document);
|
|
865
|
+
for (const namespace of Object.values(symbolTable.namespaces)) {
|
|
866
|
+
const scope = namespace === symbolTable.defaultNamespace ? document : namespaceScope(namespace, document);
|
|
880
867
|
for (const declaration of namespace.declarations) {
|
|
881
868
|
declarations.set(declaration.node.syntax, namespace);
|
|
882
869
|
scopes.set(declaration.node.syntax, scope);
|
|
@@ -912,8 +899,10 @@ function bind(options) {
|
|
|
912
899
|
diagnostics,
|
|
913
900
|
included
|
|
914
901
|
};
|
|
915
|
-
|
|
916
|
-
|
|
902
|
+
for (const namespace of Object.values(symbolTable.namespaces)) {
|
|
903
|
+
const [declaration] = namespace.declarations;
|
|
904
|
+
bindInclusions(namespace, declaration === void 0 ? document : binder.scopeAt(declaration.node.syntax), inclusionContext);
|
|
905
|
+
}
|
|
917
906
|
diagnostics.push(...placeMixinMembers({
|
|
918
907
|
symbolTable,
|
|
919
908
|
sources,
|
|
@@ -1014,11 +1003,11 @@ function bind(options) {
|
|
|
1014
1003
|
}, context);
|
|
1015
1004
|
for (const mixin of Object.values(records.mixins)) if (!hasFields(mixin)) bindBlock(mixin, context);
|
|
1016
1005
|
};
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
stack.push(binder.scopeAt(
|
|
1006
|
+
for (const namespace of Object.values(symbolTable.namespaces)) {
|
|
1007
|
+
const [declaration] = namespace.declarations;
|
|
1008
|
+
if (declaration !== void 0) stack.push(binder.scopeAt(declaration.node.syntax));
|
|
1020
1009
|
bindBlocks(namespace);
|
|
1021
|
-
stack.pop();
|
|
1010
|
+
if (declaration !== void 0) stack.pop();
|
|
1022
1011
|
}
|
|
1023
1012
|
return {
|
|
1024
1013
|
binder,
|
|
@@ -2394,8 +2383,7 @@ function interpretExtensionBlocks(input) {
|
|
|
2394
2383
|
const { symbolTable, sources, pslBlockDescriptors, binder, dataTypes } = input;
|
|
2395
2384
|
const parsedBlocks = /* @__PURE__ */ new Map();
|
|
2396
2385
|
const diagnostics = [];
|
|
2397
|
-
const
|
|
2398
|
-
for (const scope of scopes) for (const block of Object.values(scope.blocks)) {
|
|
2386
|
+
for (const namespace of Object.values(symbolTable.namespaces)) for (const block of Object.values(namespace.blocks)) {
|
|
2399
2387
|
const descriptor = findBlockDescriptor(pslBlockDescriptors, block.keyword);
|
|
2400
2388
|
if (descriptor === void 0) continue;
|
|
2401
2389
|
const parsed = interpretExtensionBlock({
|