jpsim / jpsim/SourceKitten

Request.syntaxTree not found "key.serialized_syntax_tree" in Apple Silicon M2 Xcode14.3

Open
#768 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Swift
Stars
2.4k
Forks
237
PR merge metrics
No merged PRs in 30d

Description

let file = File(contents: "class A {}")
let result = try SourceKittenFramework.Request.syntaxTree(file: file, byteTree: false).send()
print(result)

apple silicon M2 xcode14.3, "key.serialized_syntax_tree" is not found in result

["key.diagnostic_stage": "source.diagnostic.stage.swift.parse"]

intel xcode14.1,is ok

["key.diagnostic_stage": "source.diagnostic.stage.swift.parse", "key.serialized_syntax_tree": "{"kind":"SourceFile","layout":[{"kind":"CodeBlockItemList","layout":[{"kind":"CodeBlockItem","layout":[{"kind":"ClassDecl","layout":[null,null,{"tokenKind":{"kind":"kw_class"},"leadingTrivia":"","trailingTrivia":" ","presence":"Present"},{"tokenKind":{"kind":"identifier","text":"A"},"leadingTrivia":"","trailingTrivia":" ","presence":"Present"},null,null,null,{"kind":"MemberDeclBlock","layout":[{"tokenKind":{"kind":"l_brace"},"leadingTrivia":"","trailingTrivia":"","presence":"Present"},{"kind":"MemberDeclList","layout":[],"presence":"Present"},{"tokenKind":{"kind":"r_brace"},"leadingTrivia":"","trailingTrivia":"","presence":"Present"}],"presence":"Present"}],"presence":"Present"},null,null],"presence":"Present"}],"presence":"Present"},{"tokenKind":{"kind":"eof","text":""},"leadingTrivia":"","trailingTrivia":"","presence":"Present"}],"presence":"Present"}"]

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the reported snippet through Request.syntaxTree with File(contents: "class A {}") on Apple Silicon with Xcode 14.3, then compare its result with the Intel/Xcode 14.1 output shown here. Done means determining why key.serialized_syntax_tree is absent and restoring or documenting consistent syntax-tree output for the affected environment.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.