Closed VictorCMiraldo closed 2 years ago
@florentc , I updated this issue with some comments and more pointers
Another important aspect to this issue is the "as much of PlutusIR
as possible"... The set of primitives is too large to be handled on a single go. I'd suggest we gather two client contracts of your choosing, produce their respective flat files and save them as golden tests. As long as we can handle those we're fine. We should slowly increase the set of our golden tests.
FWIW, Plutus primitives are here: https://github.com/input-output-hk/plutus/blob/master/plutus-core/plutus-core/src/PlutusCore/Default/Builtins.hs
With the merging of #113, I'll consider this closed. We will certainly be finding more examples that won't work and will require the addition of some builtin, but that's an issue for the future.
Currently, we can only run pirouette over its
Pirouette.Language.Example
, we should go ahead and implement all the necessary classes forPlutusIR
; these are:LanguageBuiltinTypes
: https://github.com/tweag/pirouette/blob/9b83f80f0281bf08df94bedb3122c8348e84938a/src/Language/Pirouette/Example/Syntax.hs#L120LanguageSMT
: https://github.com/tweag/pirouette/blob/9b83f80f0281bf08df94bedb3122c8348e84938a/src/Language/Pirouette/Example/Syntax.hs#L145LaguageSMTBranches
: https://github.com/tweag/pirouette/blob/9b83f80f0281bf08df94bedb3122c8348e84938a/src/Language/Pirouette/Example/Syntax.hs#L193Additionally, we should also have a quasi-quoter for writing the proof obligations in
PlutusIR
; this can probably be reasonably easily done through some surgery on our example language syntax module; I reckon we can parameterize that AST and parser by a choice (and parser) for builtins and use that to quasi-quotePlutusIR
terms.