5

I'm using the NonEmptyString type from the refined library. When concatenating two strings, at least one of which is non-empty, the result is obviously another non-empty string. But is there a way to convince the Scala compiler of this fact without using unsafe methods such as NonEmptyString.unsafeFrom?

Matthias Berndt
  • 4,387
  • 1
  • 11
  • 25

0 Answers0