Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove Logic Proof #65

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion Anoma.juvix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import Anoma.Resource open public;
import Anoma.Transaction open public;
import Anoma.Identity open public;
import Anoma.Builtin.ByteArray open public;
import Anoma.Generic.ProofRecord open public;
-- import Anoma.Compliance as Compliance public;
import Anoma.Logic as Logic public;
import Anoma.Delta as Delta public;
Expand Down
13 changes: 0 additions & 13 deletions Anoma/Generic/ProofRecord.juvix

This file was deleted.

7 changes: 0 additions & 7 deletions Anoma/Logic/Types.juvix
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,3 @@ type ProvingKey :=
mkProvingKey@{
unProvingKey : Resource;
};

type ProofRecord :=
mkProofRecord@{
proof : Proof;
verifyingKeyUNUSED : Unit;
instance : Instance;
};
20 changes: 4 additions & 16 deletions Applib/Helpers.juvix
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ module ProvingHelpers;
(tag : Tag)
(publicInputs : Logic.Instance)
(privateInputs : Logic.Witness)
: ProofRecord :=
: BaseLayer.Proof :=
let
proof : Logic.Proof :=
Logic.prove@{
Expand All @@ -166,9 +166,7 @@ module ProvingHelpers;
publicInputs;
privateInputs;
};
verifyingKey := unit;
proofRecord := Logic.mkProofRecord proof verifyingKey publicInputs;
in LogicProofRecord proofRecord;
in proof;
end;

open ProvingHelpers;
Expand Down Expand Up @@ -198,7 +196,7 @@ mkActionHelper
commitments := map Commitment.unCommitment commitments';

-- Compute proofs
logicProofs : List ProofRecord :=
logicProofs : List BaseLayer.Proof :=
map (tag in tags) {
createLogicProofRecord@{
tag;
Expand All @@ -217,23 +215,13 @@ mkActionHelper
};
}
};

complianceProofs : List ProofRecord := [];
in mkAction@{
commitments;
nullifiers;
proofs := map proofRecordToProof (logicProofs ++ complianceProofs);
proofs := logicProofs;
appData := appData;
};

logicProofRecordToProof (p : Logic.ProofRecord) : Logic.Proof :=
Logic.ProofRecord.proof p;

proofRecordToProof : ProofRecord -> Logic.Proof
| (LogicProofRecord logProof) := logicProofRecordToProof logProof
| ComplianceProofRecord := failwith "proofRecordToProof"
| DeltaProofRecord := failwith "proofRecordToProof";

mkTransactionHelper
{roots : List CommitmentTree.Root := []}
(actions : List Action)
Expand Down
Loading