Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: swiftwasm/JavaScriptKit
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main
Choose a base ref
...
head repository: swiftwasm/JavaScriptKit
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: yt/doc-bridgejs
Choose a head ref
  • 8 commits
  • 56 files changed
  • 1 contributor

Commits on Aug 23, 2025

  1. BridgeJS: Standardize lift/lower pattern across Swift and JavaScript

    Replace global intrinsic functions with consistent extension-based system.
    Each bridged type now defines standardized lift/lower operations:
    
    Swift side (type extensions):
    - bridgeJSLowerParameter/Return: Swift -> Wasm core types
    - bridgeJSLiftParameter/Return: Wasm core types -> Swift
    
    JavaScript side (JSGlueGen):
    - Corresponding lift/lower functions for JS <-> Wasm interop
    
    Adds CodeFragmentPrinter for improved code organization.
    Reduces generated code complexity across both Swift and JS.
    kateinoigakukun committed Aug 23, 2025
    Configuration menu
    Copy the full SHA
    2699257 View commit details
    Browse the repository at this point in the history
  2. ExportSwift: Remove unused className variable

    Clean up variable declaration in VariableDeclSyntax visitor.
    kateinoigakukun committed Aug 23, 2025
    Configuration menu
    Copy the full SHA
    0df766e View commit details
    Browse the repository at this point in the history
  3. BridgeJS: Add protocol-based intrinsic system

    Introduce _BridgedSwiftTypeLoweredIntoSingleWasmCoreType protocol
    to formalize lift/lower operations. All basic types (Bool, Int,
    Float, Double) now conform to this protocol with standardized
    bridgeJS* methods.
    
    Add _BridgedSwiftHeapObject and _BridgedSwiftEnumNoPayload protocols
    for heap objects and enums respectively.
    
    Update generated code and test snapshots to use new protocol-based
    intrinsic functions.
    kateinoigakukun committed Aug 23, 2025
    Configuration menu
    Copy the full SHA
    e546582 View commit details
    Browse the repository at this point in the history
  4. BridgeJS: Complete protocol-based lift/lower for ImportTS and _JSBrid…

    …gedClass
    
    Add _JSBridgedClass protocol with lift/lower operations for JavaScript
    objects imported into Swift. Update ImportTS code generation to use
    new protocol-based bridgeJS* methods.
    
    Update all generated ImportTS Swift files and test snapshots to use
    the new bridgeJS* method calls instead of legacy functions.
    kateinoigakukun committed Aug 23, 2025
    Configuration menu
    Copy the full SHA
    177be43 View commit details
    Browse the repository at this point in the history
  5. BridgeJS: Provide default implementation for BridgeJS functions

    This is a workaround for the issue that reference to imported bjs
    wasm functions can't be eliminated in debug builds, even if they
    are not reachable at runtime without explicit BridgeJS usage.
    kateinoigakukun committed Aug 23, 2025
    Configuration menu
    Copy the full SHA
    9aad68d View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    7a31c5e View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    5f65738 View commit details
    Browse the repository at this point in the history

Commits on Aug 24, 2025

  1. BridgeJS: Clean up protocol definitions and documentation

    Remove unused _BridgedSwiftTypeLoweredIntoWasmCoreType protocol
    and fix incomplete documentation comment for the remaining protocol.
    kateinoigakukun committed Aug 24, 2025
    Configuration menu
    Copy the full SHA
    07c1ef7 View commit details
    Browse the repository at this point in the history
Loading