From a03b981be0f0bcb75100eb3501d6efe897a852a0 Mon Sep 17 00:00:00 2001 From: Alexander Chepurnoy Date: Mon, 13 May 2024 23:26:33 +0300 Subject: [PATCH] method desc --- data/shared/src/main/scala/sigma/ast/methods.scala | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/data/shared/src/main/scala/sigma/ast/methods.scala b/data/shared/src/main/scala/sigma/ast/methods.scala index e4cf0007e0..4c6c2d3ef0 100644 --- a/data/shared/src/main/scala/sigma/ast/methods.scala +++ b/data/shared/src/main/scala/sigma/ast/methods.scala @@ -1203,6 +1203,10 @@ case object SAvlTreeMethods extends MonoTypeMethods { | """.stripMargin) + lazy val toBytesMethod = SMethod(this, "toBytes", SFunc(SAvlTree, SByteArray), 1, FixedCost(JitCost(50))) + .withIRInfo(MethodCallIrBuilder) + + /** The proof may contain keys, labels and values, we don't know for sure how many, * but we assume the cost is O(proof.length). * So the following is an approximation of the proof parsing cost.