Skip to content

Commit 99122c4

Browse files
authored
Add fixme issues (#7381)
1 parent f19be20 commit 99122c4

File tree

5 files changed

+16
-10
lines changed

5 files changed

+16
-10
lines changed

plutus-core/plutus-ir/src/PlutusIR/Compiler/Datatype.hs

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,8 @@ For a (self-)recursive datatype we have to change three things:
323323
mkScottTy :: MonadQuote m => ann -> Datatype TyName Name uni ann -> m (Type TyName uni ann)
324324
mkScottTy ann d@(Datatype _ _ _ _ constrs) = do
325325
res <- resultTypeName d
326-
-- FIXME: normalize datacons' types also here
326+
-- FIXME (https://github.com/IntersectMBO/plutus-private/issues/1875):
327+
-- normalize datacons' types also here
327328
let caseTys = fmap (constructorCaseType ann (TyVar ann res)) constrs
328329
pure $
329330
-- forall res.
@@ -389,7 +390,7 @@ mkConstructorType :: Datatype TyName Name uni (Provenance a) -> VarDecl TyName N
389390
-- this type appears *inside* the scope of the abstraction for the datatype so we can just reference the name and
390391
-- we don't need to do anything to the declared type
391392
-- see Note [Abstract data types]
392-
-- FIXME: normalize constructors also here
393+
-- FIXME (https://github.com/IntersectMBO/plutus-private/issues/1875): normalize constructors also here
393394
mkConstructorType (Datatype _ _ tvs _ _) constr = PIR.mkIterTyForall tvs $ _varDeclType constr
394395

395396
-- See Note [Encoding of datatypes]
@@ -421,7 +422,7 @@ mkConstructor opts dty d@(Datatype ann _ tvs _ constrs) index = do
421422
argsAndTypes <- do
422423
-- these types appear *outside* the scope of the abstraction for the datatype, so we need to use the concrete datatype here
423424
-- see Note [Abstract data types]
424-
-- FIXME: normalize datacons' types also here
425+
-- FIXME (https://github.com/IntersectMBO/plutus-private/issues/1875): normalize datacons' types also here
425426
let argTypes = unveilDatatype (getType dty) d <$> constructorArgTypes thisConstr
426427
-- we don't have any names for these things, we just had the type, so we call them "arg_i
427428
argNames <- for [0..(length argTypes -1)] (\i -> safeFreshName $ "arg_" <> showText i)
@@ -445,7 +446,7 @@ mkConstructor opts dty d@(Datatype ann _ tvs _ constrs) index = do
445446
casesAndTypes <- do
446447
-- these types appear *outside* the scope of the abstraction for the datatype, so we need to use the concrete datatype here
447448
-- see Note [Abstract data types]
448-
-- FIXME: normalize datacons' types also here
449+
-- FIXME (https://github.com/IntersectMBO/plutus-private/issues/1875): normalize datacons' types also here
449450
let caseTypes = unveilDatatype (getType dty) d <$> fmap (constructorCaseType ann (TyVar ann resultType)) constrs
450451
caseArgNames <- for constrs (\c -> safeFreshName $ "case_" <> T.pack (varDeclNameString c))
451452
pure $ zipWith (VarDecl ann) caseArgNames caseTypes
@@ -506,7 +507,7 @@ mkDestructor opts dty d@(Datatype ann _ tvs _ constrs) = do
506507
caseVars <- for constrs $ \c -> do
507508
-- these types appear *outside* the scope of the abstraction for the datatype, so we need to use the concrete datatype here
508509
-- see Note [Abstract data types]
509-
-- FIXME: normalize datacons' types also here
510+
-- FIXME (https://github.com/IntersectMBO/plutus-private/issues/1875): normalize datacons' types also here
510511
let caseType = constructorCaseType ann (TyVar ann resultType) c
511512
unveiledCaseType = unveilDatatype (getType dty) d caseType
512513
caseArgName <- safeFreshName $ "case_" <> T.pack (varDeclNameString c)

plutus-core/plutus-ir/test/PlutusIR/Compiler/Let/Tests.hs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@ test_lets =
2727
, goldenPlcFromPir pTermAsProg "letDep"
2828
]
2929

30-
-- FIXME: this fails because some of the let passes expect certain things to be
30+
-- FIXME (https://github.com/IntersectMBO/plutus-private/issues/1876):
31+
-- this fails because some of the let passes expect certain things to be
3132
-- gone, e.g. non-strict bindings. We should a) add pre-/post-conditions for these,
3233
-- and b) set up the tests to establish what is needed
3334
test_propLets :: TestTree

plutus-core/plutus-ir/test/PlutusIR/Transform/DeadCode/Tests.hs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,8 @@ test_deadCode =
3838
, "pruneDatatype"
3939
]
4040

41-
-- FIXME this test sometimes fails so ignoring it to make CI pass.
41+
-- FIXME (https://github.com/IntersectMBO/plutus-private/issues/1877):
42+
-- this test sometimes fails so ignoring it to make CI pass.
4243
typecheckRemoveDeadBindingsProp :: BuiltinSemanticsVariant DefaultFun -> Property
4344
typecheckRemoveDeadBindingsProp biVariant =
4445
withMaxSuccess (3 * numTestsForPassProp) $

plutus-core/untyped-plutus-core/src/UntypedPlutusCore/Evaluation/Machine/Cek/Internal.hs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -857,7 +857,8 @@ enterComputeCek = computeCek
857857
returnCek (FrameAwaitFunTerm argVarEnv arg ctx) fun =
858858
computeCek (FrameAwaitArg fun ctx) argVarEnv arg
859859
-- s , [(lam x (M,ρ)) _] ◅ V ↦ s ; ρ [ x ↦ V ] ▻ M
860-
-- FIXME: add rule for VBuiltin once it's in the specification.
860+
-- FIXME (https://github.com/IntersectMBO/plutus-private/issues/1878):
861+
-- add rule for VBuiltin once it's in the specification.
861862
returnCek (FrameAwaitArg fun ctx) arg =
862863
applyEvaluate ctx fun arg
863864
-- s , [_ V] ◅ lam x (M,ρ) ↦ s ; ρ [ x ↦ V ] ▻ M

plutus-core/untyped-plutus-core/src/UntypedPlutusCore/Evaluation/Machine/SteppableCek/Internal.hs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,8 @@ returnCek (FrameAwaitFunTerm _funAnn argVarEnv arg ctx) fun =
175175
-- MAYBE: perhaps it is worth here to merge the _funAnn with argAnn
176176
pure $ Computing (FrameAwaitArg (termAnn arg) fun ctx) argVarEnv arg
177177
-- s , [(lam x (M,ρ)) _] ◅ V ↦ s ; ρ [ x ↦ V ] ▻ M
178-
-- FIXME: add rule for VBuiltin once it's in the specification.
178+
-- FIXME (https://github.com/IntersectMBO/plutus-private/issues/1878):
179+
-- add rule for VBuiltin once it's in the specification.
179180
returnCek (FrameAwaitArg _ fun ctx) arg =
180181
applyEvaluate ctx fun arg
181182
-- s , [_ V1 .. Vn] ◅ lam x (M,ρ) ↦ s , [_ V2 .. Vn]; ρ [ x ↦ V1 ] ▻ M
@@ -411,7 +412,8 @@ lenContext = go 0
411412

412413

413414
-- * Duplicated functions from Cek.Internal module
414-
-- FIXME: share these functions with Cek.Internal
415+
-- FIXME (https://github.com/IntersectMBO/plutus-private/issues/1879):
416+
-- share these functions with Cek.Internal
415417
-- preliminary testing shows that sharing slows down original cek
416418

417419
cekStepCost :: CekMachineCosts -> StepKind -> ExBudget

0 commit comments

Comments
 (0)