Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

relax swift-syntax version constraint to allow 603#714

Merged
kateinoigakukun merged 2 commits into
swiftwasm:mainswiftwasm/JavaScriptKit:mainfrom
untitled-in-brackets:chore/relax-swift-syntax-constraintuntitled-in-brackets/JavaScriptKit:chore/relax-swift-syntax-constraintCopy head branch name to clipboard
Apr 9, 2026
Merged

relax swift-syntax version constraint to allow 603#714
kateinoigakukun merged 2 commits into
swiftwasm:mainswiftwasm/JavaScriptKit:mainfrom
untitled-in-brackets:chore/relax-swift-syntax-constraintuntitled-in-brackets/JavaScriptKit:chore/relax-swift-syntax-constraintCopy head branch name to clipboard

Conversation

@diederich

Copy link
Copy Markdown
Contributor

Packages are updating to 603 and this can fail the dependency solver.

@kateinoigakukun kateinoigakukun enabled auto-merge (squash) April 9, 2026 09:14
auto-merge was automatically disabled April 9, 2026 09:27

Head branch was pushed to by a user without write access

@diederich

Copy link
Copy Markdown
Contributor Author

Thanks for the quick accept! 🙏
Just sneaked in another commit after I saw CI testing against the different swift-syntax versions.

@diederich

Copy link
Copy Markdown
Contributor Author

And... that failed :-D

Saw there's 2 formatting only diffs it seems?

  -    _swift_js_push_i32((__bjs_elem_ret as! _BridgedSwiftProtocolExportable).bridgeJSLowerAsProtocolReturn())}
  +    _swift_js_push_i32((__bjs_elem_ret as! _BridgedSwiftProtocolExportable).bridgeJSLowerAsProtocolReturn())
  +    }

(and one more)

@kateinoigakukun

Copy link
Copy Markdown
Member

@krodak Would you mind fixing the protocol array code gen to use the proper CodeBlockItemSyntax unit so that the formatter can format it correctly?

private func lowerProtocolArrayStatements(
accessor: String,
varPrefix: String
) -> [CodeBlockItemSyntax] {
var statements: [CodeBlockItemSyntax] = []
let elemVar = "__bjs_elem_\(varPrefix)"
statements.append("for \(raw: elemVar) in \(raw: accessor) {")
statements.append(
" _swift_js_push_i32((\(raw: elemVar) as! _BridgedSwiftProtocolExportable).bridgeJSLowerAsProtocolReturn())"
)
statements.append("}")
statements.append("_swift_js_push_i32(Int32(\(raw: accessor).count))")
return statements

@krodak

krodak commented Apr 9, 2026

Copy link
Copy Markdown
Member

@kateinoigakukun sure, I'll start right on it

@diederich

diederich commented Apr 9, 2026

Copy link
Copy Markdown
Contributor Author

Thank you! 🙏

I just found something else related while trying to get my dependencies back in order 😅
This repo seems to be using package swift versioning the "other way around". I think the idea is to keep Package.swift (plain) as the most recent, then Package@swift-x.x.swift as the older versions.

Should we flip them around? (alternatively I can bump swift-syntax in both Package.swift files, or only in the newer, 6.2 version)

Edit:

see:

Note
Support for having a versioned manifest file with a newer tools version was required when the feature was first introduced because prior versions of the package manager were not aware of the concept and only knew to look for the unversioned Package.swift. This is still supported, but there have been many Swift releases since the feature was introduced. It is a best practice to have Package.swift declare the newest-supported tools version and for versioned manifest files to only specify older versions.

(via https://docs.swift.org/swiftpm/documentation/packagemanagerdocs/swiftversionspecificpackaging/#Version-specific-Manifest-Selection)

@kateinoigakukun

Copy link
Copy Markdown
Member

Should we flip them around? (alternatively I can bump swift-syntax in both Package.swift files, or only in the newer, 6.2 version)

Oh, yes. Would be better to flip

@diederich

Copy link
Copy Markdown
Contributor Author

Should we flip them around? (alternatively I can bump swift-syntax in both Package.swift files, or only in the newer, 6.2 version)

Oh, yes. Would be better to flip

-> #715

@krodak

krodak commented Apr 9, 2026

Copy link
Copy Markdown
Member

Can't push to untitled-in-brackets/JavaScriptKit directly so opened PR with a fix: untitled-in-brackets#1

EDIT: Actually included fix in #716 , should work after this branch rebase on newest main

Packages are updating to 603 and this can fail the dependency solver.
@diederich diederich force-pushed the chore/relax-swift-syntax-constraint branch from 72a33d7 to 0a66372 Compare April 9, 2026 12:18
@diederich

Copy link
Copy Markdown
Contributor Author

Thanks @krodak ! 🙏
Rebased!

@diederich

Copy link
Copy Markdown
Contributor Author
Screenshot 2026-04-09 at 14 38 05 🤩 🙏

@kateinoigakukun kateinoigakukun merged commit 0d6544f into swiftwasm:main Apr 9, 2026
13 checks passed
@kateinoigakukun

Copy link
Copy Markdown
Member

Thanks!

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.

3 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.