microsoft / microsoft/vscode-powerquery
field access generalized identifiers highlight as seperate tokens
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 108
- Forks
- 25
- Avg merge
- 8d 22h
- Merged PRs (30d)
- 2
Description
Summary
This is minor: field access without quoted-identifiers highlight as separate tokens.
ex: The textmate scope of in in [Records in Range] is a language keyword

I wasn't sure whether this is at the extension level or microsoft/powerquery-parser I put it here because even though textmate's scope is a keyword -- the parser seems to format correctly. I tried using a strange generalized-identifier to see if I could break the formatting, but it did not.

Power BI's editor has the same behaviour

Test Query
let
Source = ...,
#"Total Records1" = Table.AddColumn(
Source, "Count 1",
each Table.RowCount( [#"Records in Range"] ),
type number
),
#"Total Records2" = Table.AddColumn(
Source, "Count 2",
each Table.RowCount( [Records in Range] ),
type number
)
in
#"Total Records2"
I think this is the grammar involved (Expand)
.

Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the extension's syntax-highlighting grammar, especially the Expand grammar noted in the issue, and compare its scopes for the quoted and unquoted field-access forms in the Test Query. Check whether the behavior belongs in vscode-powerquery or microsoft/powerquery-parser. Done means generalized identifiers such as [Records in Range] no longer highlight words like “in” as standalone language keywords.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript, vscode
- Domain
- devtools
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100