Branch: refs/heads/main
Home:
https://github.com/krishnprakash/codeql
Commit: f668b99d6df0d7ba7a334aa4c98469fd002c7788
https://github.com/krishnprakash/codeql/commit/f668b99d6df0d7ba7a334aa4c98469fd002c7788
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M unified/AGENTS.md
M unified/extractor/src/extractor.rs
A unified/extractor/src/languages/mod.rs
M unified/extractor/src/main.rs
A unified/extractor/tests/corpus/swift/desugar.txt
A unified/extractor/tests/corpus_tests.rs
A unified/scripts/update-corpus.sh
Log Message:
-----------
Unified: Add support for tree-sitter-style corpus tests
This adds tests consisting of source code and a printout of its rewritten AST.
Commit: 49f19092fb985c955913b2e6ea7565c4a45bbc98
https://github.com/krishnprakash/codeql/commit/49f19092fb985c955913b2e6ea7565c4a45bbc98
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M shared/yeast/src/lib.rs
M shared/yeast/tests/test.rs
Log Message:
-----------
Yeast: add reachable_node_ids()
Commit: a049850c51b54d4a65278a50ebbe13560ef155d9
https://github.com/krishnprakash/codeql/commit/a049850c51b54d4a65278a50ebbe13560ef155d9
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M shared/yeast/src/dump.rs
M shared/yeast/src/node_types_yaml.rs
M shared/yeast/src/schema.rs
M shared/yeast/tests/test.rs
Log Message:
-----------
Yeast: add type-checking errors in AST dump
Commit: c3a9218dcffd337d5580d98d6d8bd2ee714cc109
https://github.com/krishnprakash/codeql/commit/c3a9218dcffd337d5580d98d6d8bd2ee714cc109
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M shared/yeast/doc/yeast.md
M shared/yeast/src/captures.rs
M shared/yeast/src/lib.rs
M shared/yeast/tests/test.rs
Log Message:
-----------
Yeast: Add one-shot phase kind
Commit: bb9e996cb6f2d37def2113059ccd8a2f25fd4467
https://github.com/krishnprakash/codeql/commit/bb9e996cb6f2d37def2113059ccd8a2f25fd4467
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M shared/tree-sitter-extractor/src/generator/mod.rs
Log Message:
-----------
Shared: Do not emit ReservedWord class when there are no unnamed tokens
Commit: 5d0cb9e8052d35d0098753f32a6e420795e0651f
https://github.com/krishnprakash/codeql/commit/5d0cb9e8052d35d0098753f32a6e420795e0651f
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M shared/yeast/src/lib.rs
M unified/extractor/src/languages/swift/swift.rs
Log Message:
-----------
YEAST: fix one-shot rules for unnamed nodes and self-captures
One-shot desugaring rules now skip unnamed nodes (punctuation, keywords,
etc.) since rules are intended to target named nodes only.
Also prevent infinite recursion when a capture refers to the root node of
the matched tree (e.g. an @_ capture on the pattern root).
Additionally fix the swift.rs add_phase call to match the updated 3-arg
signature introduced by the one-shot phase kind commit.
Co-authored-by: Copilot <
22355621...@users.noreply.github.com>
Commit: 8a2a48d2dd46576e1273245de361d8aac74b961c
https://github.com/krishnprakash/codeql/commit/8a2a48d2dd46576e1273245de361d8aac74b961c
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
A unified/extractor/ast_types.yml
M unified/extractor/src/extractor.rs
M unified/extractor/src/generator.rs
M unified/extractor/src/languages/mod.rs
M unified/extractor/src/languages/swift/swift.rs
M unified/extractor/tests/corpus_tests.rs
M unified/ql/lib/codeql/unified/Ast.qll
M unified/ql/lib/unified.dbscheme
M unified/ql/test/library-tests/BasicTest/test.expected
M unified/ql/test/library-tests/BasicTest/test.ql
Log Message:
-----------
Unified extractor: add AST schema, swift translation rules, and corpus framework
Add ast_types.yml defining the unified output AST schema with supertypes
(expr, stmt, condition, pattern) and named nodes (top_level, binary_expr,
name_expr, etc.).
Rewrite swift translation rules to map from tree-sitter Swift grammar to
the unified AST, using one-shot phase rules.
Update the generator to use the output AST schema for dbscheme/QL
generation, and normalize the extraction table prefix to 'unified'.
Improve the corpus test framework to include raw tree-sitter parse output,
type-error checking against the output schema, and better failure
reporting.
Regenerate Ast.qll, unified.dbscheme, and update BasicTest accordingly.
Co-authored-by: Copilot <
22355621...@users.noreply.github.com>
Commit: 72b683d63c610b1540e9440926c8a1e480760460
https://github.com/krishnprakash/codeql/commit/72b683d63c610b1540e9440926c8a1e480760460
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
A unified/extractor/tests/corpus/swift/closures.txt
A unified/extractor/tests/corpus/swift/collections.txt
A unified/extractor/tests/corpus/swift/control-flow.txt
M unified/extractor/tests/corpus/swift/desugar.txt
A unified/extractor/tests/corpus/swift/functions.txt
A unified/extractor/tests/corpus/swift/literals.txt
A unified/extractor/tests/corpus/swift/loops.txt
A unified/extractor/tests/corpus/swift/operators.txt
A unified/extractor/tests/corpus/swift/optionals-and-errors.txt
A unified/extractor/tests/corpus/swift/types.txt
A unified/extractor/tests/corpus/swift/variables.txt
Log Message:
-----------
Unified: Add Swift corpus tests
Add corpus test cases for Swift covering closures, collections, control
flow, functions, literals, loops, operators, optionals/errors, types,
and variables. Update existing desugar.txt with raw parse sections.
Note: operator nodes currently render their node ID instead of the actual
operator text (e.g. operator "3" instead of operator "+"). This will be
fixed in the next commit.
Co-authored-by: Copilot <
22355621...@users.noreply.github.com>
Commit: 5772ee4d9b5f313e74e83412261911834f077151
https://github.com/krishnprakash/codeql/commit/5772ee4d9b5f313e74e83412261911834f077151
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M shared/tree-sitter-extractor/src/extractor/mod.rs
M shared/yeast-macros/src/parse.rs
M shared/yeast/src/lib.rs
M shared/yeast/src/visitor.rs
M shared/yeast/tests/test.rs
M unified/extractor/tests/corpus/swift/desugar.txt
M unified/extractor/tests/corpus/swift/operators.txt
Log Message:
-----------
YEAST: add NodeRef type, YeastDisplay trait, and source text storage
Introduce NodeRef as a typed wrapper around node arena IDs. Captures in
desugaring rules are now bound as NodeRef instead of raw usize, which
prevents accidental misuse and enables source-text-aware rendering.
Add the YeastDisplay trait as an alternative to Display: its
yeast_to_string method receives the Ast, allowing NodeRef to resolve to
the captured node's source text instead of printing a numeric ID.
Store the original source bytes in the Ast so that NodeContent::Range
values (from synthesized literal nodes) can be resolved back to text.
Update yeast-macros to emit NodeRef-typed capture bindings and use
Into::<usize>::into where raw IDs are needed. The #{expr} template
syntax now uses YeastDisplay instead of Display.
The effect is visible in the corpus tests: operator nodes now correctly
render as e.g. operator "+" instead of operator "3".
Co-authored-by: Copilot <
22355621...@users.noreply.github.com>
Commit: 92838011dda962714311a9d2c19e2f2f7693f900
https://github.com/krishnprakash/codeql/commit/92838011dda962714311a9d2c19e2f2f7693f900
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M unified/extractor/ast_types.yml
M unified/extractor/src/languages/swift/swift.rs
M unified/extractor/tests/corpus/swift/closures.txt
M unified/extractor/tests/corpus/swift/collections.txt
M unified/extractor/tests/corpus/swift/control-flow.txt
M unified/extractor/tests/corpus/swift/desugar.txt
M unified/extractor/tests/corpus/swift/literals.txt
M unified/extractor/tests/corpus/swift/operators.txt
M unified/extractor/tests/corpus/swift/optionals-and-errors.txt
M unified/extractor/tests/corpus/swift/variables.txt
Log Message:
-----------
Unified: Add some more AST nodes and rules
Commit: 2307839050174554ab82e811ba000e659d54dfa7
https://github.com/krishnprakash/codeql/commit/2307839050174554ab82e811ba000e659d54dfa7
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M shared/yeast-macros/src/parse.rs
M unified/extractor/tests/corpus/swift/operators.txt
Log Message:
-----------
Yeast: Change how patterns with repetition are parsed
Commit: 6b58482dfb508723389a87d11bbadfbb882be86f
https://github.com/krishnprakash/codeql/commit/6b58482dfb508723389a87d11bbadfbb882be86f
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M shared/yeast/src/lib.rs
M unified/extractor/tests/corpus/swift/operators.txt
Log Message:
-----------
Yeast: Fix text associated with synthesized nodes
Commit: a966dff76e1e755028549731de25a8e7fc220fc9
https://github.com/krishnprakash/codeql/commit/a966dff76e1e755028549731de25a8e7fc220fc9
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M unified/extractor/ast_types.yml
M unified/extractor/src/languages/swift/swift.rs
M unified/extractor/tests/corpus/swift/closures.txt
M unified/extractor/tests/corpus/swift/control-flow.txt
M unified/extractor/tests/corpus/swift/variables.txt
Log Message:
-----------
Unified: Add more patterns and some fixes to the AST
Commit: ccc1dd5d3e5d91d1bdb9b258d4b45aa8c8613378
https://github.com/krishnprakash/codeql/commit/ccc1dd5d3e5d91d1bdb9b258d4b45aa8c8613378
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M unified/extractor/ast_types.yml
M unified/extractor/src/languages/swift/swift.rs
M unified/extractor/tests/corpus/swift/variables.txt
Log Message:
-----------
Unified: Add tuple_pattern
Commit: 3b7a53f678af1487746289e20eeae1a7d309dddd
https://github.com/krishnprakash/codeql/commit/3b7a53f678af1487746289e20eeae1a7d309dddd
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M shared/yeast-macros/src/parse.rs
Log Message:
-----------
yeast-macros: merge repeated field declarations and support repetition in field patterns
Two changes to parse_query_fields:
- Allow `field: (kind)* @cap` (repetition + optional capture) in field
position, mirroring how it works for bare children.
- When the same field name is declared multiple times in a query (e.g.
`condition: (foo) condition: (bar)`), merge them into a single
ordered list of children rather than emitting duplicate field
entries (which at runtime restart the iterator for the field and
cause the second declaration to re-match from the first child).
Commit: cbe4c81ca665617342fd209bdecdea41e7008bb5
https://github.com/krishnprakash/codeql/commit/cbe4c81ca665617342fd209bdecdea41e7008bb5
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M unified/extractor/ast_types.yml
M unified/extractor/src/languages/swift/swift.rs
Log Message:
-----------
Unified: add tuple_pattern and sequence_condition; refine if-let/guard mapping
ast_types.yml additions:
- tuple_pattern { element*: pattern } in the pattern supertype.
- sequence_condition { stmt*: stmt, condition: condition } in the
condition supertype.
swift.rs:
- Map Swift tuple destructuring (e.g. `let (a, b) = pair`) to the new
tuple_pattern instead of synthesizing an apply_pattern.
- if-let / guard-let: explicitly match the value_binding_pattern
(the `let` keyword) and bind the source expression as the next
condition child, so `let` no longer leaks into the output.
Commit: 55194dd757bda4a849eb72ba207332db96e1d5b7
https://github.com/krishnprakash/codeql/commit/55194dd757bda4a849eb72ba207332db96e1d5b7
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M unified/extractor/ast_types.yml
M unified/extractor/src/languages/swift/swift.rs
M unified/extractor/tests/corpus/swift/closures.txt
M unified/extractor/tests/corpus/swift/collections.txt
M unified/extractor/tests/corpus/swift/control-flow.txt
M unified/extractor/tests/corpus/swift/functions.txt
M unified/extractor/tests/corpus/swift/optionals-and-errors.txt
Log Message:
-----------
Unified: Support for calls and member access
Commit: 600a4969c95204e99684721b757442b396f1475b
https://github.com/krishnprakash/codeql/commit/600a4969c95204e99684721b757442b396f1475b
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M unified/extractor/src/languages/swift/swift.rs
Log Message:
-----------
Unified: Simplify concatenation of arguments
Commit: 7fa6c4e4a30d29ff1ec456f571702b8b4824780d
https://github.com/krishnprakash/codeql/commit/7fa6c4e4a30d29ff1ec456f571702b8b4824780d
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M unified/extractor/tests/corpus/swift/closures.txt
M unified/extractor/tests/corpus/swift/collections.txt
M unified/extractor/tests/corpus/swift/control-flow.txt
M unified/extractor/tests/corpus/swift/functions.txt
M unified/extractor/tests/corpus/swift/loops.txt
M unified/extractor/tests/corpus/swift/optionals-and-errors.txt
M unified/extractor/tests/corpus/swift/types.txt
M unified/extractor/tests/corpus/swift/variables.txt
Log Message:
-----------
Unified: Update test output after rebasing on grammar changes
The branch was rebased on the grammar changes, but rewriting the history was too difficult, so I'm just updating the test output here.
Commit: b031e5b1f89ec165035d7a3cc2e31650462f67c9
https://github.com/krishnprakash/codeql/commit/b031e5b1f89ec165035d7a3cc2e31650462f67c9
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M unified/ql/lib/codeql/unified/Ast.qll
M unified/ql/lib/unified.dbscheme
A unified/ql/test/library-tests/BasicTest/name_expr.swift
M unified/ql/test/library-tests/BasicTest/test.expected
M unified/ql/test/library-tests/BasicTest/test.ql
Log Message:
-----------
Unified: regenerate QL and make tests not crash
The output is not so interesting as the mapping removes most nodes from the current test file.
I added a name_expr.swift test so at least one NameExpr makes it through.
Commit: 554bdf14b2305ea9b1fdbc6d14221ef15ba6c50d
https://github.com/krishnprakash/codeql/commit/554bdf14b2305ea9b1fdbc6d14221ef15ba6c50d
Author: Asger F <
asg...@github.com>
Date: 2026-05-13 (Wed, 13 May 2026)
Changed paths:
M shared/yeast-macros/src/parse.rs
Log Message:
-----------
Yeast: fix warning about unnecessary mutability
Commit: f18cdcfec663a47550bf22fbf13f8efb9c6a45cc
https://github.com/krishnprakash/codeql/commit/f18cdcfec663a47550bf22fbf13f8efb9c6a45cc
Author: Asger F <
asg...@github.com>
Date: 2026-05-26 (Tue, 26 May 2026)
Changed paths:
M shared/tree-sitter-extractor/src/extractor/mod.rs
M shared/tree-sitter-extractor/src/generator/mod.rs
M shared/yeast-macros/src/parse.rs
M shared/yeast/doc/yeast.md
M shared/yeast/src/captures.rs
M shared/yeast/src/dump.rs
M shared/yeast/src/lib.rs
M shared/yeast/src/node_types_yaml.rs
M shared/yeast/src/schema.rs
M shared/yeast/src/visitor.rs
M shared/yeast/tests/test.rs
M unified/AGENTS.md
A unified/extractor/ast_types.yml
M unified/extractor/src/extractor.rs
M unified/extractor/src/generator.rs
A unified/extractor/src/languages/mod.rs
M unified/extractor/src/languages/swift/swift.rs
M unified/extractor/src/main.rs
A unified/extractor/tests/corpus/swift/closures.txt
A unified/extractor/tests/corpus/swift/collections.txt
A unified/extractor/tests/corpus/swift/control-flow.txt
A unified/extractor/tests/corpus/swift/desugar.txt
A unified/extractor/tests/corpus/swift/functions.txt
A unified/extractor/tests/corpus/swift/literals.txt
A unified/extractor/tests/corpus/swift/loops.txt
A unified/extractor/tests/corpus/swift/operators.txt
A unified/extractor/tests/corpus/swift/optionals-and-errors.txt
A unified/extractor/tests/corpus/swift/types.txt
A unified/extractor/tests/corpus/swift/variables.txt
A unified/extractor/tests/corpus_tests.rs
M unified/ql/lib/codeql/unified/Ast.qll
M unified/ql/lib/unified.dbscheme
A unified/ql/test/library-tests/BasicTest/name_expr.swift
M unified/ql/test/library-tests/BasicTest/test.expected
M unified/ql/test/library-tests/BasicTest/test.ql
A unified/scripts/update-corpus.sh
Log Message:
-----------
Merge pull request #21848 from asgerf/asgerf/swift-yeast
Unified: Add schema checking and corpus-style tests
Commit: ea5a181d67a47852465d26b4ad2d181613b37109
https://github.com/krishnprakash/codeql/commit/ea5a181d67a47852465d26b4ad2d181613b37109
Author: Phileco <
132178579+k...@users.noreply.github.com>
Date: 2026-05-27 (Wed, 27 May 2026)
Changed paths:
M shared/tree-sitter-extractor/src/extractor/mod.rs
M shared/tree-sitter-extractor/src/generator/mod.rs
M shared/yeast-macros/src/parse.rs
M shared/yeast/doc/yeast.md
M shared/yeast/src/captures.rs
M shared/yeast/src/dump.rs
M shared/yeast/src/lib.rs
M shared/yeast/src/node_types_yaml.rs
M shared/yeast/src/schema.rs
M shared/yeast/src/visitor.rs
M shared/yeast/tests/test.rs
M unified/AGENTS.md
A unified/extractor/ast_types.yml
M unified/extractor/src/extractor.rs
M unified/extractor/src/generator.rs
A unified/extractor/src/languages/mod.rs
M unified/extractor/src/languages/swift/swift.rs
M unified/extractor/src/main.rs
A unified/extractor/tests/corpus/swift/closures.txt
A unified/extractor/tests/corpus/swift/collections.txt
A unified/extractor/tests/corpus/swift/control-flow.txt
A unified/extractor/tests/corpus/swift/desugar.txt
A unified/extractor/tests/corpus/swift/functions.txt
A unified/extractor/tests/corpus/swift/literals.txt
A unified/extractor/tests/corpus/swift/loops.txt
A unified/extractor/tests/corpus/swift/operators.txt
A unified/extractor/tests/corpus/swift/optionals-and-errors.txt
A unified/extractor/tests/corpus/swift/types.txt
A unified/extractor/tests/corpus/swift/variables.txt
A unified/extractor/tests/corpus_tests.rs
M unified/ql/lib/codeql/unified/Ast.qll
M unified/ql/lib/unified.dbscheme
A unified/ql/test/library-tests/BasicTest/name_expr.swift
M unified/ql/test/library-tests/BasicTest/test.expected
M unified/ql/test/library-tests/BasicTest/test.ql
A unified/scripts/update-corpus.sh
Log Message:
-----------
Merge branch 'github:main' into main
Compare:
https://github.com/krishnprakash/codeql/compare/bfdfe761c99c...ea5a181d67a4
To unsubscribe from these emails, change your notification settings at
https://github.com/krishnprakash/codeql/settings/notifications