Basic HasQuery Capability #
This is the lightweight dependency boundary for the query capability.
It defines HasQuery spec m, exports the bare identifier query, and provides
only the foundational instances for primitive query syntax and monad lifts.
Core syntax modules, especially VCVio.OracleComp.OracleComp, should import
this file when they need the class or the bare query export.
Do not add QueryImpl, ProbComp, or monad-morphism APIs here; those live in
downstream modules with explicit imports.
@[implicit_reducible]
instance
HasQuery.instOracleQuery
{ι : Type u}
{spec : OracleSpec ι}
:
HasQuery spec (OracleQuery spec)
The primitive single-query syntax OracleQuery spec has the obvious query capability.
@[simp]
@[implicit_reducible, instance 100]
instance
HasQuery.instOfMonadLift
{ι : Type u}
{spec : OracleSpec ι}
{m : Type v → Type w}
[MonadLiftT (OracleQuery spec) m]
:
HasQuery spec m
Any lawful lift of OracleQuery spec into m gives query capability in m. This is the
main bridge that makes HasQuery compose with SubSpec lifts and standard transformer lifts.
@[simp]
theorem
HasQuery.instOfMonadLift_query
{ι : Type u}
{spec : OracleSpec ι}
{m : Type v → Type w}
[MonadLiftT (OracleQuery spec) m]
(t : spec.Domain)
: