com.phasmidsoftware.gryphon.util.HasZero
See theHasZero companion object
Trait to define a type class which supports the zero (identity) method.
It's rather disappointing that Scala doesn't define this. I suppose we could get it from Cats but that seems like overkill.
Type parameters
- T
-
the type of this trait.
Attributes
- Companion
- object
- Graph
-
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
trait HasZeroBooleanobject HasZeroBooleantrait HasZeroDoubleobject HasZeroDoubletrait HasZeroIntobject HasZeroInttrait HasZeroUnitobject HasZeroUnit
Members list
In this article