cove v0.0.0 - Coalgebraic context layer for kont suspensions in Go #1
hayabusa-cloud
announced in
Announcements
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Introduction
covecarries ambient context acrosskontsuspension boundaries as explicit, typed data. It is designed for runtimes that step one suspension at a time while still needing budget, capability, phase, or buffer-state information at each boundary. Instead of side maps or hidden globals,covekeeps that context attached to values and suspensions throughViewandSuspensionView.covealso introduces two forms of context requirements: closure-basedReqfor direct use and data-basedReqExprfor composable boolean structure. On top of those requirements, the package provides named rules, diagnostics, and guarded values that can be checked before a step proceeds. The stepping helpers remain policy-free: they preserve and evolve context, but they do not schedule, retry, or dispatch. That keeps ownership clean across the wider stack while making contextual stepping easy to reason about and test.Usage
Highlights
covelaunches with a contextual stepping surface forkont, including typed carriers for ambient context, guarded values, and suspension-aware resume helpers. The release also ships both closure and expression forms of the requirement algebra so callers can choose between direct predicates and data-first composition.Features
View[C, A]andSuspensionView[C, A]to pair values and suspensions with ambient context.Req[C]andReqExpr[C]withAll,Any,Not,True,False, and pullback helpers for context predicates.Rule[C],RuleExpr[C],Report, and rule-checking helpers for named diagnostics.Checked,Guarded,CheckedExpr, andGuardedExprfor requirement-gated values.StepWith,StepExprWith,CheckSuspension,CheckSuspensionExpr, and resume helpers for contextual stepping.Reify,Reflect,ReifyReq, andReflectReqbridges between closure and expression worlds.Compatibility
1.26+This discussion was created from the release cove v0.0.0 - Coalgebraic context layer for kont suspensions in Go.
All reactions