Skip to content

feat(all): Quotations: DerivedPatterns, and captured locals as Value nodes - #4919

Merged
ncave merged 2 commits into
fable-compiler:mainfrom
Thorium:feat/quotation-derived-patterns
Sep 1, 2026
Merged

feat(all): Quotations: DerivedPatterns, and captured locals as Value nodes#4919
ncave merged 2 commits into
fable-compiler:mainfrom
Thorium:feat/quotation-derived-patterns

Conversation

@Thorium

@Thorium Thorium commented Aug 28, 2026

Copy link
Copy Markdown
Contributor
  • AndAlso, OrElse and SpecificCall are mapped, with an implementation in each
    runtime that has a quotation module. They were the last patterns still
    reporting "not supported by Fable", and && and || desugar into IfThenElse, so
    without them a consumer has to re-derive that shape by hand
  • a local captured by a quotation is now spliced in as a Value holding its
    value, the way .NET does, instead of a Var carrying only a name. That needed
    three changes together: the emitter tracks which names the quotation binds,
    getSubExpressions lets analysis see into a Quote, and canInlineArg stops
    removing a binding whose only reference lives inside one

…nodes

- AndAlso, OrElse and SpecificCall are mapped, with an implementation in each
  runtime that has a quotation module. They were the last patterns still
  reporting "not supported by Fable", and && and || desugar into IfThenElse, so
  without them a consumer has to re-derive that shape by hand
- a local captured by a quotation is now spliced in as a Value holding its
  value, the way .NET does, instead of a Var carrying only a name. That needed
  three changes together: the emitter tracks which names the quotation binds,
  getSubExpressions lets analysis see into a Quote, and canInlineArg stops
  removing a binding whose only reference lives inside one
@ncave
ncave self-requested a review September 1, 2026 13:15
@ncave

ncave commented Sep 1, 2026

Copy link
Copy Markdown
Collaborator

LGTM

@ncave
ncave merged commit a496573 into fable-compiler:main Sep 1, 2026
43 checks passed
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.

2 participants