TOML Decoders #
This module contains definitions to assist in decoding TOML data values into concrete user types.
@[reducible, inline]
Equations
Instances For
@[inline]
Run the decode action. If there were errors, throw. Otherwise, return the result.
Equations
Instances For
@[inline]
Run the decode action. If it fails, keep the errors but return default.
Equations
Instances For
@[inline]
Run the decode action. If it fails, keep the errors but return Inhabited.default.
Equations
Instances For
@[inline]
def
Lake.Toml.optDecode
{β : Type}
{α : Type u_1}
[Inhabited β]
(a? : Option α)
(f : α → EDecodeM β)
:
DecodeM β
If the value is not none, run the decode action.
If it fails, add the errors to the state and return Inhabited.default.
Equations
Instances For
@[inline]
Equations
Instances For
Decode an array of TOML values, merging any errors from the elements into a single array.
Equations
Instances For
@[inline]
Equations
Instances For
Equations
@[inline]
Equations
Instances For
Equations
Instances For
def
Lake.Toml.Table.decodeValue
(t : Table)
(k : Lean.Name)
(ref : Lean.Syntax := Lean.Syntax.missing)
:
Equations
Instances For
@[inline]
def
Lake.Toml.Table.decode
{α : Type}
[dec : DecodeToml α]
(t : Table)
(k : Lean.Name)
(ref : Lean.Syntax := Lean.Syntax.missing)
:
EDecodeM α
Equations
Instances For
@[inline]
Equations
Instances For
def
Lake.Toml.Table.decodeNameMap
{α : Type}
[dec : DecodeToml α]
(t : Table)
:
EDecodeM (Lean.NameMap α)
Equations
Instances For
Equations
@[inline]
def
Lake.Toml.Table.tryDecode
{α : Type}
[Inhabited α]
[dec : DecodeToml α]
(t : Table)
(k : Lean.Name)
(ref : Lean.Syntax := Lean.Syntax.missing)
:
DecodeM α
Equations
Instances For
@[inline]
Equations
Instances For
@[inline]
def
Lake.Toml.Table.tryDecodeD
{α : Type}
[dec : DecodeToml α]
(k : Lean.Name)
(default : α)
(t : Table)
:
DecodeM α