Skip to content

[pull] main from swiftwasm:main#7

Open
pull[bot] wants to merge 1250 commits into
majacQ:mainfrom
swiftwasm:main
Open

[pull] main from swiftwasm:main#7
pull[bot] wants to merge 1250 commits into
majacQ:mainfrom
swiftwasm:main

Conversation

@pull

@pull pull Bot commented Jul 19, 2021

Copy link
Copy Markdown

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

@pull pull Bot added ⤵️ pull merge-conflict Resolve conflicts manually labels Jul 19, 2021
@atomist atomist Bot added auto-branch-delete:on-close Delete branch when pull request gets closed auto-merge-method:merge Auto-merge with merge commit auto-merge:on-bpr-success Auto-merge on passed branch protection rule labels Jul 19, 2021
@pull pull Bot removed auto-branch-delete:on-close Delete branch when pull request gets closed auto-merge-method:merge Auto-merge with merge commit auto-merge:on-bpr-success Auto-merge on passed branch protection rule labels Jul 19, 2021
kateinoigakukun and others added 22 commits February 9, 2026 12:26
So that we can use it for Swift code generation
[NFC] BridgeJS: Move CodeFragmentPrinter to BridgeJSCore
…er-return

BridgeJS: Fix optional Swift heap object handling for imported interface
Prepare to extend the context more
BridgeJS: Add `IntrinsicJSFragment.PrintCodeContext`
BridgeJS: Unify closure JS glue lift/lower
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 4 to 6.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](actions/setup-node@v4...v6)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
…ons/setup-node-6

Bump actions/setup-node from 4 to 6
BridgeJS: Fix incorrect TypeScript type names for `tsEnum`-style enums and struct associated values
- Rename `optionalRepresentation` to `asOptional`.
- Remove `undefinedValue` static property and use `.undefined` case directly.
BridgeJS: Update `JSUndefinedOr` APIs
to be consistent with other environment variables used by BridgeJS.
BridgeJS: Include source-context in diagnostic messages
krodak and others added 21 commits June 10, 2026 14:35
BridgeJS: Fix reject path of zero-parameter async throwing exports
* drop swift 6.1

* fix ci matrix

* Detach async JS bridge tasks

* Stabilize identity GC test

* Revert detached async bridge tasks

* Use Swift 6.2.4 in CI

* Use Swift 6.2.3 in CI

* Drop Swift 6.2 from CI

* Document minimum Swift version

* Add MSSV section to README

* Fix async closure test formatting

* Move tracing override to 24.04 matrix entry
* Use latest snapshot toolchain

* Use native build system for examples

* Use native build system in PackageToJS tests

* Fix build-examples CI hang

* Apply formatter output

* Match formatter whitespace
…paths (#764)

* BridgeJS: support associated-value enums in import and async paths

* Format Swift sources

* Match Swift 6.1 formatter output
BridgeJS: Support throws and async for closures
…tions

BridgeJS: Normalize wasm pointer offsets in JS
Bumps [actions/checkout](https://github.com/actions/checkout) from 6 to 7.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](actions/checkout@v6...v7)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
The `declare global { namespace ... }` class stub rendered every method
without `static` and filtered properties to instance-only, so a `@JS static
func` on a namespaced class was typed as an instance method and a `@JS
static var` was omitted from the generated `.d.ts`.

This was a type-only defect: the emitted JavaScript already exposes these
members statically (and the class's namespace export entry types them
correctly), so only TypeScript consumers were affected. Split static and
instance members in this path: emit static methods with `static` and
include static properties.

This has been incorrect since the global namespace class stub was
introduced, not a regression. The `Namespaces.Global` snapshot already
exercises a namespaced class with `static func`/`static var` but had
recorded the wrong output, so it is updated to the corrected declarations.
…members

BridgeJS: Emit static members in declare global class declarations
Propagate Swift `///` and `/** */` documentation on exported declarations
into the generated TypeScript declarations as JSDoc, so editors surface
hover docs for the bridged API.

The exporter now captures the leading doc comment for functions, classes,
methods, properties, constructors, structs, and enums into the skeleton,
and the linker renders it as a single JSDoc block. The Swift DocC field
list is mapped as the inverse of the TS2Swift importer: the leading
description becomes the JSDoc body, `- Parameters:`/`- Parameter x:` become
`@param`, `- Returns:` becomes `@returns`, and `- Throws:` becomes
`@throws`. Existing default-value annotations are merged into the same
block so a parameter never emits two comment blocks; declarations without
doc comments produce byte-identical output to before.
BridgeJS: Include Swift doc comments in generated d.ts
The `build-examples` job built all examples sequentially in a single job,
taking ~57 minutes - each example is its own SwiftPM package that recompiles
JavaScriptKit and swift-syntax from scratch, with no sharing between them.

Split the job by event:

- Pull requests fan out a matrix `build-examples` with one job per example,
  built in parallel. Wall-clock drops to that of the slowest single example
  (~10 min). Each example now reports as a separate `build-examples (<name>)`
  check, so the required status checks need updating (see PR description).
- `main` keeps the full release build of all examples plus the GitHub Pages
  deploy (`build-examples-deploy`), so published artifacts are unchanged.

Examples are built in release to match the deploy path, keeping the only
behavioral change the parallelism. Each matrix step runs `build.sh` from the
example directory (via `working-directory`), mirroring
Utilities/build-examples.sh.
Follow-up to the review on #750:

- ImportTS: give the unreachable `.alias` cases in loweringParameterInfo /
  liftingReturnInfo a message stating the `.unaliased` invariant, so a future
  change that breaks it fails loudly instead of trapping silently.
- JSGlueGen: in `optionalConvention` and `wasmParams`, delegate `.alias` to its
  underlying type rather than `preconditionFailure()`. These switch on `self`
  (not `.unaliased`), so this removes a latent crash for alias-wrapped values
  and matches how abiReturnType / mangleTypeName already handle `.alias`.
- SwiftToSkeleton: diagnose `@JS(as:)` combined with `namespace:` instead of
  silently dropping the namespace; an alias adopts its representation's
  placement. Adds a diagnostics test.
- BridgeJSSkeleton: note why alias mangling uses the (unique) swiftCallName only.
- Docs: add an "Exporting a Type With a Custom JS Representation" article and
  link it from the exporting topics.
BridgeJS: Export types using a separate JS representation
MaxDesiatov and others added 8 commits July 1, 2026 12:59
BridgeJS: Fix issues exporting nested types
…oding

BridgeJS: Unify optional stack encoding to presence-flag form
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 6 to 7.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](actions/setup-node@v6...v7)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

⤵️ pull merge-conflict Resolve conflicts manually

Projects

None yet

Development

Successfully merging this pull request may close these issues.