Skip to content

Commit bd88a0f

Browse files
Add an explicit type instantiation in NamedTuple.map
To avoid triggering a deep subtype comparison needed for the inference of the higher-kinded type parameter.
1 parent 6a971b1 commit bd88a0f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/src-bootstrapped/scala/NamedTuple.scala

+1-1
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ object NamedTupleDecomposition:
181181
* If `x = (n1 = v1, ..., ni = vi)` then `x.map(f) = `(n1 = f(v1), ..., ni = f(vi))`.
182182
*/
183183
inline def map[F[_]](f: [t] => t => F[t]): Map[NamedTuple[N, V], F] =
184-
x.toTuple.map(f)
184+
x.toTuple.map[F](f)
185185

186186
/** The named tuple consisting of all elements of this tuple in reverse */
187187
inline def reverse: Reverse[NamedTuple[N, V]] = x.toTuple.reverse

0 commit comments

Comments
 (0)