Domo v1.0.1 Domo.TypeContract View Source
A module to validate a type contract
Link to this section Summary
Functions
Validates if the value matches the @type contract.
Link to this section Functions
Specs
valid?(any(), Macro.t(), Macro.Env.t()) :: boolean()
Validates if the value matches the @type contract.
- contract is a type spec in Elixir quoted form.
- environment is a module's environment to resolve aliases for remote types.
Usually, it should be a caller environment that
the
Kernel.SpecialForms.__ENV__/0
macro returns.