typelevel / paiges

an implementation of Wadler's a prettier printer
Apache License 2.0
186 stars 30 forks source link

Is the invariant on Line correct? #629

Open steinybot opened 1 month ago

steinybot commented 1 month ago

Line says:

Represents a single, literal newline. This is always nested inside the left of a FlatAlt. Exposing this at the top level breaks a number of invariants we have.

But it is exposed at the top level by hardLine.

Is the invariant wrong?