Skip to content

[Self-Hosting Phase 1] Port Closure Environment Records and Uniform Calling Convention #680

Closed

Description

@godofecht

Scope

Replace static global variable capture hoisting in compiler/src/cgen.flow with proper closure environment records.

Deliverables

  • Free variable analysis for lambda expressions and nested functions.
  • Environment struct generation and capture-by-value packing in compiler/src/cgen.flow.
  • Uniform fat pointer / closure invoking calling convention for higher-order functions.
  • Validate with tests/lang/test_closures.flow.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1-highcompilerself-hosting

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions