Skip to content

Commit 6f94465

Browse files
committed
Parameterize conwayGovCertTransition by rule
1 parent 7025c85 commit 6f94465

File tree

2 files changed

+9
-9
lines changed
  • eras
    • conway/impl/src/Cardano/Ledger/Conway/Rules
    • dijkstra/impl/src/Cardano/Ledger/Dijkstra/Rules

2 files changed

+9
-9
lines changed

eras/conway/impl/src/Cardano/Ledger/Conway/Rules/GovCert.hs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -168,18 +168,18 @@ instance
168168
type PredicateFailure (ConwayGOVCERT era) = ConwayGovCertPredFailure era
169169
type Event (ConwayGOVCERT era) = Void
170170

171-
transitionRules = [conwayGovCertTransition @era]
171+
transitionRules = [conwayGovCertTransition]
172172

173173
conwayGovCertTransition ::
174-
forall era.
174+
forall rule era.
175175
( ConwayEraPParams era
176176
, ConwayEraCertState era
177-
, InjectRuleFailure "GOVCERT" ConwayGovCertPredFailure era
178-
, State (EraRule "GOVCERT" era) ~ CertState era
179-
, Signal (EraRule "GOVCERT" era) ~ ConwayGovCert
180-
, Environment (EraRule "GOVCERT" era) ~ ConwayGovCertEnv era
177+
, InjectRuleFailure rule ConwayGovCertPredFailure era
178+
, State (EraRule rule era) ~ CertState era
179+
, Signal (EraRule rule era) ~ ConwayGovCert
180+
, Environment (EraRule rule era) ~ ConwayGovCertEnv era
181181
) =>
182-
TransitionRule (EraRule "GOVCERT" era)
182+
TransitionRule (EraRule rule era)
183183
conwayGovCertTransition = do
184184
TRC
185185
( ConwayGovCertEnv {cgcePParams, cgceCurrentEpoch, cgceCurrentCommittee, cgceCommitteeProposals}

eras/dijkstra/impl/src/Cardano/Ledger/Dijkstra/Rules/GovCert.hs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,14 +99,14 @@ instance Typeable era => DecCBOR (DijkstraGovCertPredFailure era) where
9999

100100
instance
101101
( ConwayEraPParams era
102+
, ConwayEraCertState era
102103
, State (EraRule "GOVCERT" era) ~ CertState era
103104
, Signal (EraRule "GOVCERT" era) ~ ConwayGovCert
104105
, Environment (EraRule "GOVCERT" era) ~ ConwayGovCertEnv era
105106
, InjectRuleFailure "GOVCERT" ConwayGovCertPredFailure era
106107
, EraRule "GOVCERT" era ~ DijkstraGOVCERT era
107108
, Eq (PredicateFailure (EraRule "GOVCERT" era))
108109
, Show (PredicateFailure (EraRule "GOVCERT" era))
109-
, ConwayEraCertState era
110110
) =>
111111
STS (DijkstraGOVCERT era)
112112
where
@@ -117,7 +117,7 @@ instance
117117
type PredicateFailure (DijkstraGOVCERT era) = DijkstraGovCertPredFailure era
118118
type Event (DijkstraGOVCERT era) = Void
119119

120-
transitionRules = [Conway.conwayGovCertTransition @era]
120+
transitionRules = [Conway.conwayGovCertTransition]
121121

122122
conwayToDijkstraGovCertPredFailure ::
123123
forall era. ConwayGovCertPredFailure era -> DijkstraGovCertPredFailure era

0 commit comments

Comments
 (0)