@@ -39,23 +39,20 @@ import Cardano.Ledger.Shelley.UTxO (UTxO (..))
39
39
import Cardano.Slotting.EpochInfo (fixedEpochInfo )
40
40
import Cardano.Slotting.Slot (EpochNo (.. ))
41
41
import qualified Data.Map.Strict as Map
42
- import Data.SOP.BasicFunctors
43
- import Data.SOP.Functors
44
42
import Data.SOP.InPairs (RequiringBoth (.. ), provideBoth )
45
43
import Ouroboros.Consensus.BlockchainTime.WallClock.Types
46
44
( slotLengthFromSec
47
45
)
48
46
import Ouroboros.Consensus.Byron.Ledger (ByronBlock , byronLedgerState )
49
47
import Ouroboros.Consensus.Cardano.Block (CardanoEras )
50
- import Ouroboros.Consensus.Cardano.CanHardFork
51
48
import Ouroboros.Consensus.Cardano.CanHardFork ()
52
49
import Ouroboros.Consensus.HardFork.Combinator
53
50
( InPairs (.. )
54
51
, hardForkEraTranslation
55
52
, translateLedgerState
56
53
)
57
54
import Ouroboros.Consensus.HardFork.Combinator.State.Types
58
- ( TranslateLedgerState (TranslateLedgerState , translateLedgerStateWith )
55
+ ( TranslateLedgerState (.. )
59
56
)
60
57
import Ouroboros.Consensus.Ledger.Basics
61
58
( LedgerCfg
@@ -65,7 +62,6 @@ import Ouroboros.Consensus.Ledger.Basics
65
62
import Ouroboros.Consensus.Ledger.Tables hiding (TxIn )
66
63
import Ouroboros.Consensus.Ledger.Tables.Diff (Diff )
67
64
import qualified Ouroboros.Consensus.Ledger.Tables.Diff as Diff
68
- import Ouroboros.Consensus.Ledger.Tables.Utils
69
65
import Ouroboros.Consensus.Protocol.Praos
70
66
import Ouroboros.Consensus.Protocol.TPraos (TPraos )
71
67
import Ouroboros.Consensus.Shelley.Eras
@@ -191,6 +187,12 @@ babbageToConwayLedgerStateTranslation ::
191
187
TranslateLedgerState
192
188
(ShelleyBlock (Praos Crypto ) BabbageEra )
193
189
(ShelleyBlock (Praos Crypto ) ConwayEra )
190
+ conwayToDijkstraLedgerStateTranslation ::
191
+ RequiringBoth
192
+ WrapLedgerConfig
193
+ TranslateLedgerState
194
+ (ShelleyBlock (Praos Crypto ) ConwayEra )
195
+ (ShelleyBlock (Praos Crypto ) DijkstraEra )
194
196
PCons
195
197
byronToShelleyLedgerStateTranslation
196
198
( PCons
@@ -204,7 +206,7 @@ PCons
204
206
( PCons
205
207
babbageToConwayLedgerStateTranslation
206
208
( PCons
207
- _
209
+ conwayToDijkstraLedgerStateTranslation
208
210
PNil
209
211
)
210
212
)
@@ -219,30 +221,6 @@ PCons
219
221
(CardanoEras Crypto )
220
222
tls = translateLedgerState hardForkEraTranslation
221
223
222
- conwayToDijkstraLedgerStateTranslation ::
223
- RequiringBoth
224
- WrapLedgerConfig
225
- TranslateLedgerState
226
- (ShelleyBlock (Praos Crypto ) ConwayEra )
227
- (ShelleyBlock (Praos Crypto ) DijkstraEra )
228
- conwayToDijkstraLedgerStateTranslation = translateLedgerStateConwayToDijkstraWrapper
229
-
230
- translateLedgerStateConwayToDijkstraWrapper ::
231
- RequiringBoth
232
- WrapLedgerConfig
233
- TranslateLedgerState
234
- (ShelleyBlock (Praos Crypto ) ConwayEra )
235
- (ShelleyBlock (Praos Crypto ) DijkstraEra )
236
- translateLedgerStateConwayToDijkstraWrapper =
237
- RequireBoth $ \ _ cfgDijkstra ->
238
- TranslateLedgerState $ \ _ ->
239
- noNewTickingDiffs
240
- . unFlip
241
- . unComp
242
- . Core. translateEra' (getDijkstraTranslationContext cfgDijkstra)
243
- . Comp
244
- . Flip
245
-
246
224
-- | Check that the tables are correctly translated from one era to the next.
247
225
testTablesTranslation ::
248
226
forall srcBlk dstBlk .
0 commit comments