Numbers.Protocols.Absolute protocol (numbers v5.2.5)

Copy Markdown

For supporting Numbers.abs/1.

Summary

Types

t()

All the types that implement this protocol.

Functions

The absolute value of a number.

Types

t()

@type t() :: term()

All the types that implement this protocol.

Functions

abs(num)

@spec abs(t()) :: t()

The absolute value of a number.