Skip to content

experiment: implicit-derivation-rep example of type reps failing inference - #6054

Draft
crusso wants to merge 9 commits into
masterfrom
claudio/implicit-derivation-pt1
Draft

experiment: implicit-derivation-rep example of type reps failing inference#6054
crusso wants to merge 9 commits into
masterfrom
claudio/implicit-derivation-pt1

Conversation

@crusso

@crusso crusso commented Apr 24, 2026

Copy link
Copy Markdown
Contributor

Part of reviewing #5966.

I thought this example (inferring a derived dictionary of functions( would work, but perhaps it's expected not to.

I guess we only apply inference if the hole has a function type - it can't be a record of methods. But is that restriction necessary?

I updated the review with some comments/questions

Kamirus and others added 9 commits April 1, 2026 11:33
Allow the compiler to derive implicit arguments from functions that
themselves have implicit parameters (e.g. `compare` for `[Nat]` from
`Array.compare<Nat>` + `Nat.compare`).

Works transitively and is depth-limited via `--implicit-derivation-depth`.

Structural derivation (`__record`/`__tuple` combiners) will follow in a
separate PR.

Made-with: Cursor
a
Made-with: Cursor
@github-actions

Copy link
Copy Markdown
Contributor

Comparing from 9b961a3 to 1afa652:
The produced WebAssembly code seems to be completely unchanged.
In terms of gas, no changes are observed in 5 tests.
In terms of size, no changes are observed in 5 tests.

@crusso crusso changed the title implicit-derivation-rep example of type reps failing inference experimemt: implicit-derivation-rep example of type reps failing inference Apr 24, 2026
@ggreif ggreif changed the title experimemt: implicit-derivation-rep example of type reps failing inference experiment: implicit-derivation-rep example of type reps failing inference Apr 25, 2026
@Kamirus

Kamirus commented Apr 27, 2026

Copy link
Copy Markdown
Contributor

Answered here #5966 (comment)

Base automatically changed from kamil/implicit-derivation-pt1 to master April 29, 2026 13:24
@caffeine-ci-bot

Copy link
Copy Markdown
Contributor

This draft pull request has had no activity for 60 days and has been marked as stale. It will not be closed automatically. Please close it if you can.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants