Skip to content

Fix HKT, Tuple and infix rendering in TypePrinter - #117

Merged
rochala merged 2 commits into
VirtusLab:mainfrom
matejcerny:rendering-hkt-tuple-infix
Jul 28, 2026
Merged

Fix HKT, Tuple and infix rendering in TypePrinter#117
rochala merged 2 commits into
VirtusLab:mainfrom
matejcerny:rendering-hkt-tuple-infix

Conversation

@matejcerny

Copy link
Copy Markdown
Contributor

follow up on #102

HKT

  • previously def compose[G >: TypeLambda <: TypeLambda](evidence$1: Applicative[G]): Applicative[TypeLambda]
  • now def compose[G[_]](implicit evidence$1: Applicative[G]): Applicative[[α] =>> F[G[α]]]

Functions

  • previously p: Function1[A, Boolean]
  • now p: A => Boolean

Tuples

  • previously Tuple2[F[Boolean], F[A]]
  • now (F[Boolean], F[A])

Infix notation

  • previously def mapK[G[_]](f: ~>[F, G])(implicit G: MonadCancel[G, ? >: Nothing <: Any]): Semaphore[G]
  • now def mapK[G[_]](f: F ~> G)(implicit G: MonadCancel[G, ?]): Semaphore[G]

@Fristi

Fristi commented Jul 24, 2026

Copy link
Copy Markdown

Would be great to get this in!

@rochala

rochala commented Jul 26, 2026

Copy link
Copy Markdown
Contributor

Tomorrow, I promise. Sorry for the delay I'm just extra busy this time

@rochala
rochala merged commit 5aef481 into VirtusLab:main Jul 28, 2026
2 checks passed
@rochala

rochala commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

If we want to align Scala AST pretty print with what the actual source code looks like we should basically port TypePrinter from Scala3 / Scala2 itself. Just an idea dropped here

@matejcerny

Copy link
Copy Markdown
Contributor Author

If we want to align Scala AST pretty print with what the actual source code looks like we should basically port TypePrinter from Scala3 / Scala2 itself. Just an idea dropped here

Good idea, thank you!

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.

3 participants