Skip to content

Fix syntax error for URIQualifiedName followed by a colon#2701

Merged
ChristianGruen merged 1 commit into
BaseXdb:mainfrom
GuntherRademacher:#2701
Jun 27, 2026
Merged

Fix syntax error for URIQualifiedName followed by a colon#2701
ChristianGruen merged 1 commit into
BaseXdb:mainfrom
GuntherRademacher:#2701

Conversation

@GuntherRademacher

Copy link
Copy Markdown
Member

As reported by Andrew Sales on basex-talk, a URIQualifiedName without the optional prefix raised a syntax error when immediately followed by a colon (e.g. the := operator) with no intervening whitespace, as in:

let $Q{}foo:=1 return $Q{}foo

When parsing an EQName, QueryParser.eQName speculatively consumes a : to check for the optional-prefix form Q{uri}prefix:local (qtspecs#2227). When no valid local name follows, the colon was not given back, so the surrounding := could no longer be recognized. The parser now restores its position in that case.

@ChristianGruen ChristianGruen merged commit 34faca0 into BaseXdb:main Jun 27, 2026
1 check passed
@ChristianGruen ChristianGruen deleted the #2701 branch June 27, 2026 18:59
@ChristianGruen

Copy link
Copy Markdown
Member

A literal hotfix… and a new snapshot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants