Update syntax highlighting with all keywords from pytrilogy lark grammar#28
Merged
greenmtnboy merged 2 commits intomainfrom Jan 29, 2026
Merged
Conversation
Updated the VS Code extension's syntax highlighting to cover all grammatical keywords from the pytrilogy lark grammar file. Changes include: - Added all statement keywords: select, from, where, having, order, limit, etc. - Added multi-select keywords: merge, align, derive, rowset, with - Added persist/copy keywords: persist, append, overwrite, into, copy, csv, json, parquet - Added datasource keywords: datasource, grain, address, query, file, freshness, etc. - Added chart keywords: chart, line, bar, barh, point, area, headline, donut, etc. - Added CASE/WHEN conditional keywords - Added concept types: key, metric, property, parameter, param, const, constant, unique - Added all data types: string, number, numeric, int, bigint, date, datetime, timestamp, float, bool, any, struct, list, array, map, tuple - Added categorized builtin functions: math, string, array, map, aggregate, date, window - Added operators: <-, ->, ::, between, like, ilike - Added lambda transform syntax: @Identifier - Added hash types: md5, sha1, sha256, sha512 - Added date parts: DAY, WEEK, MONTH, QUARTER, YEAR, MINUTE, HOUR, SECOND, DAY_OF_WEEK - Added support for // comments in addition to # comments - Updated literals to use true, false, null (case-insensitive) - Made all keyword matching case-insensitive to match lark grammar https://claude.ai/code/session_01KJrcKzNukbgAV2RGQtWZxX
- Bump extension version from 0.1.26 to 0.1.27 - Add grammar tests for keywords, concepts, functions, types, operators, literals, comments - Fix sqrt being incorrectly included in chart keywords (it's a math function) - Fix || being incorrectly marked as invalid operator (it's string concatenation) - Add import keyword to statement-keyword patterns Test coverage includes: - Query keywords (select, from, where, having, order, limit, by) - Multi-select keywords (merge, align, derive, rowset, with) - Persist/copy keywords (persist, append, overwrite, into, copy, csv, json, parquet) - Datasource keywords (datasource, grain, address, query, file, etc.) - Chart keywords (chart, line, bar, point, area, etc.) - CASE/WHEN conditionals - Concept types (key, metric, property, parameter, const, unique) - Data types (string, number, int, bigint, float, struct, list, array, map) - Functions (math, string, array, map, aggregate, date, window, constants) - Operators (logical, assignment, arithmetic, comparison) - Literals (true/false/null, lambda transforms, hash types, date parts, numbers, strings) - Comments (# and //) https://claude.ai/code/session_01KJrcKzNukbgAV2RGQtWZxX
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Updated the VS Code extension's syntax highlighting to cover all grammatical
keywords from the pytrilogy lark grammar file. Changes include:
https://claude.ai/code/session_01KJrcKzNukbgAV2RGQtWZxX