Skip to content

Fix Scala 3 compile error in GenIso after IsoFields return type change#1600

Merged
julien-truffaut merged 1 commit into
masterfrom
fix-geniso-isofields-compile
Jul 13, 2026
Merged

Fix Scala 3 compile error in GenIso after IsoFields return type change#1600
julien-truffaut merged 1 commit into
masterfrom
fix-geniso-isofields-compile

Conversation

@julien-truffaut

Copy link
Copy Markdown
Member

PR #1574 changed IsoFields.apply to return
PIso[S, S, ? <: Tuple, ? <: Tuple] but GenIso._fields still fed the result into whitebox, which expects Expr[Iso[S, A]]. The wildcard type no longer unifies with Iso[S, A], breaking macrosJVM compilation on every Scala 3 JVM job (the CI page only showed temurin@25 red because fail-fast cancelled the others).

Cast the IsoFields result directly to Expr[Iso[S, Any]] in the fallback branch, matching the erased cast whitebox already performs.

PR #1574 changed IsoFields.apply to return
PIso[S, S, ? <: Tuple, ? <: Tuple] but GenIso._fields still fed the
result into `whitebox`, which expects Expr[Iso[S, A]]. The wildcard type
no longer unifies with Iso[S, A], breaking macrosJVM compilation on every
Scala 3 JVM job (the CI page only showed temurin@25 red because fail-fast
cancelled the others).

Cast the IsoFields result directly to Expr[Iso[S, Any]] in the fallback
branch, matching the erased cast `whitebox` already performs.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@julien-truffaut julien-truffaut merged commit bfafa4f into master Jul 13, 2026
21 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.

1 participant