@@ -63,17 +63,30 @@ instance
6363
6464## Miscellaneous Type Aliases
6565
66-
6766``` agda
68- CCHotKeys DReps PoolEnv Pools Retiring Rewards Stake StakeDelegs : Type
69- CCHotKeys = Credential ⇀ Maybe Credential
70- DReps = Credential ⇀ Epoch
71- PoolEnv = PParams
72- Pools = KeyHash ⇀ StakePoolParams
73- Retiring = KeyHash ⇀ Epoch
74- Rewards = Credential ⇀ Coin
75- Stake = Credential ⇀ Coin
76- StakeDelegs = Credential ⇀ KeyHash
67+ CCHotKeys : Type
68+ CCHotKeys = Credential ⇀ Maybe Credential
69+
70+ DReps : Type
71+ DReps = Credential ⇀ Epoch
72+
73+ PoolEnv : Type
74+ PoolEnv = PParams
75+
76+ Pools : Type
77+ Pools = KeyHash ⇀ StakePoolParams
78+
79+ Retiring : Type
80+ Retiring = KeyHash ⇀ Epoch
81+
82+ Rewards : Type
83+ Rewards = Credential ⇀ Coin
84+
85+ Stake : Type
86+ Stake = Credential ⇀ Coin
87+
88+ StakeDelegs : Type
89+ StakeDelegs = Credential ⇀ KeyHash
7790```
7891
7992<!--
@@ -356,10 +369,10 @@ private variable
356369
357370### Delegation
358371
359- Registered credentials can now delegate to a DRep as well as to a stake
360- pool. This is achieved by giving the
372+ Registered credentials can now delegate to a ` DRep ` {.AgdaInductiveConstructor}
373+ as well as to a stake pool. This is achieved by giving the
361374` delegate ` {.AgdaInductiveConstructor} certificate two optional fields,
362- corresponding to a DRep and stake pool.
375+ corresponding to a ` DRep ` {.AgdaInductiveConstructor} and stake pool.
363376
364377Stake can be delegated for voting and block production simultaneously,
365378since these are two separate features. In fact, preventing this could
@@ -405,13 +418,15 @@ Sections [Auxiliary `DELEG`{.AgdaDatatype} Transition System](#auxiliary-deleg-t
405418[ Auxiliary ` GOVCERT ` {.AgdaDatatype} transition system] ( #auxiliary-govcert-transition-system ) .
406419
407420` GOVCERT ` {.AgdaDatatype} deals with the new certificates relating to
408- DReps and the constitutional committee.
421+ ` DRep ` {.AgdaInductiveConstructor}s and the constitutional committee.
409422
410423+ ` GOVCERT-regdrep ` {.AgdaInductiveConstructor} registers (or
411- re-registers) a DRep. In case of registration, a deposit needs to be
412- paid. Either way, the activity period of the DRep is reset.
424+ re-registers) a ` DRep ` {.AgdaInductiveConstructor}. In case of registration,
425+ a deposit needs to be paid. Either way, the activity period of the
426+ ` DRep ` {.AgdaInductiveConstructor} is reset.
413427
414- + ` GOVCERT-deregdrep ` {.AgdaInductiveConstructor} deregisters a DRep.
428+ + ` GOVCERT-deregdrep ` {.AgdaInductiveConstructor} deregisters a
429+ ` DRep ` {.AgdaInductiveConstructor}.
415430
416431+ ` GOVCERT-ccreghot ` {.AgdaInductiveConstructor} registers a "hot"
417432 credential for constitutional committee members.[ ^ 1 ] We check that the
@@ -522,13 +537,13 @@ data _⊢_⇀⦇_,CERT⦈_ : CertEnv → CertState → DCert → CertState →
522537Here we define the ` CERTBASE ` {.AgdaFunction} function which handles the following
523538important housekeeping tasks:
524539
525- - check the correctness of withdrawals and ensure that withdrawals only
526- happen from credentials that have delegated their voting power;
540+ + check the correctness of withdrawals and ensure that withdrawals only
541+ happen from credentials that have delegated their voting power;
527542
528- - set the rewards of the credentials that withdrew funds to zero;
543+ + set the rewards of the credentials that withdrew funds to zero;
529544
530- - and set the activity timer of all DReps that voted to ` drepActivity ` {.AgdaField}
531- epochs in the future.
545+ + and set the activity timer of all ` DRep ` {.AgdaInductiveConstructor}s that voted
546+ to ` drepActivity ` {.AgdaField} epochs in the future.
532547
533548<!--
534549```agda
@@ -539,7 +554,7 @@ open GovVote using (voter)
539554``` agda
540555data _⊢_⇀⦇_,PRE-CERT⦈_ : CertEnv → CertState → ⊤ → CertState → Type where
541556
542- CERT-init :
557+ CERT-pre :
543558 let refresh = mapPartial (isGovVoterDRep ∘ voter) (fromList vs)
544559 refreshedDReps = mapValueRestricted (const (e + pp .drepActivity)) dReps refresh
545560 wdrlCreds = mapˢ stake (dom wdrls)
@@ -553,7 +568,7 @@ data _⊢_⇀⦇_,PRE-CERT⦈_ : CertEnv → CertState → ⊤ → CertState →
553568
554569data _⊢_⇀⦇_,POST-CERT⦈_ : CertEnv → CertState → ⊤ → CertState → Type where
555570
556- CERT-last :
571+ CERT-post :
557572 ⟦ e , pp , vs , wdrls , cc ⟧
558573 ⊢ ⟦ ⟦ voteDelegs , stakeDelegs , rewards ⟧ , stᵖ , stᵍ ⟧
559574 ⇀⦇ _ ,POST-CERT⦈
0 commit comments