diff --git a/interpreter/shared/src/main/scala/sigma/ast/CostKind.scala b/interpreter/shared/src/main/scala/sigma/ast/CostKind.scala index 55df3321cb..b1a91a8999 100644 --- a/interpreter/shared/src/main/scala/sigma/ast/CostKind.scala +++ b/interpreter/shared/src/main/scala/sigma/ast/CostKind.scala @@ -1,7 +1,5 @@ package sigma.ast -import sigmastate.{EQ, NEQ} - import scala.runtime.Statics /** Cost descriptor of a single operation, usually associated with diff --git a/interpreter/shared/src/main/scala/sigmastate/trees.scala b/interpreter/shared/src/main/scala/sigma/ast/trees.scala similarity index 99% rename from interpreter/shared/src/main/scala/sigmastate/trees.scala rename to interpreter/shared/src/main/scala/sigma/ast/trees.scala index 40e4b454ea..4761b061e3 100644 --- a/interpreter/shared/src/main/scala/sigmastate/trees.scala +++ b/interpreter/shared/src/main/scala/sigma/ast/trees.scala @@ -1,21 +1,20 @@ -package sigmastate +package sigma.ast import debox.{cfor, Map => DMap} +import scorex.crypto.hash.{Blake2b256, CryptographicHash32, Sha256} +import sigma.ast.ArithOp.OperationImpl +import sigma.ast.Operations._ +import sigma.ast.SCollection.{SByteArray, SIntArray} +import sigma.ast.SOption.SIntOption +import sigma.ast.global._ import sigma.data.ExactIntegral._ import sigma.data.ExactOrdering._ import sigma.data.OverloadHack.Overloaded1 import sigma.data.{CAND, COR, CTHRESHOLD, ExactIntegral, ExactOrdering, SigmaBoolean, SigmaConstants} -import scorex.crypto.hash.{Blake2b256, CryptographicHash32, Sha256} -import sigma.ast.SCollection -import sigma.ast.SCollection.{SByteArray, SIntArray} -import sigma.ast.SOption.SIntOption -import sigma.{Coll, Colls, GroupElement, SigmaProp, VersionContext} -import sigmastate.ArithOp.OperationImpl -import sigma.ast.Operations._ -import sigma.ast._ import sigma.serialization.CoreByteWriter.ArgInfo import sigma.validation.SigmaValidationSettings -import sigma.ast.global._ +import sigma.{Coll, Colls, GroupElement, SigmaProp, VersionContext} +import sigmastate.DataValueComparer import sigmastate.eval.Extensions.EvalCollOps import sigmastate.eval.NumericOps.{BigIntIsExactIntegral, BigIntIsExactOrdering} import sigmastate.eval.SigmaDsl @@ -676,7 +675,7 @@ object SubstConstants extends ValueCompanion { /** Transforms serialized bytes of ErgoTree with segregated constants by * replacing constants at given positions with new values. This operation * allow to use serialized scripts as pre-defined templates. - * See [[sigmastate.SubstConstants]] for details. + * See [[SubstConstants]] for details. * * @param scriptBytes serialized ErgoTree with ConstantSegregationFlag set to 1. * @param positions zero based indexes in ErgoTree.constants array which @@ -865,7 +864,7 @@ object ArithOp { } } - private[sigmastate] val operations: DMap[Byte, ArithOpCompanion] = + private[sigma] val operations: DMap[Byte, ArithOpCompanion] = DMap.fromIterable(Seq(Plus, Minus, Multiply, Division, Modulo, Min, Max).map(o => (o.opCode, o))) /** Represents implementation of numeric Arith operations for the given type argTpe. */ @@ -874,7 +873,7 @@ object ArithOp { val o = _o.asInstanceOf[ExactOrdering[Any]] } - private[sigmastate] val impls: DMap[SType.TypeCode, OperationImpl] = + private[sigma] val impls: DMap[SType.TypeCode, OperationImpl] = DMap.fromIterable(Seq( SByte -> new OperationImpl(ByteIsExactIntegral, ByteIsExactOrdering, SByte), SShort -> new OperationImpl(ShortIsExactIntegral, ShortIsExactOrdering, SShort), diff --git a/interpreter/shared/src/main/scala/sigmastate/eval/CContext.scala b/interpreter/shared/src/main/scala/sigmastate/eval/CContext.scala index 0556a29591..e5263e85cf 100644 --- a/interpreter/shared/src/main/scala/sigmastate/eval/CContext.scala +++ b/interpreter/shared/src/main/scala/sigmastate/eval/CContext.scala @@ -6,6 +6,7 @@ import org.ergoplatform.validation.ValidationRules import scorex.crypto.hash.{Blake2b256, Sha256} import scorex.utils.Longs import sigma.Extensions.ArrayOps +import sigma.ast.{AtLeast, SubstConstants} import sigma.crypto.{EcPointType, Ecp} import sigma.data._ import sigma.serialization.GroupElementSerializer diff --git a/interpreter/shared/src/main/scala/sigmastate/interpreter/CostItem.scala b/interpreter/shared/src/main/scala/sigmastate/interpreter/CostItem.scala index a6a5c52854..2c9c4ec49e 100644 --- a/interpreter/shared/src/main/scala/sigmastate/interpreter/CostItem.scala +++ b/interpreter/shared/src/main/scala/sigmastate/interpreter/CostItem.scala @@ -1,7 +1,6 @@ package sigmastate.interpreter -import sigma.ast.{FixedCost, JitCost, PerItemCost, SMethod, SType, TypeBasedCost} -import sigma.ast.{FixedCostValueCompanion, PerItemCostValueCompanion, ValueCompanion} +import sigma.ast.{FixedCost, FixedCostValueCompanion, GT, JitCost, LE, PerItemCost, PerItemCostValueCompanion, SMethod, SType, TypeBasedCost, ValueCompanion} import sigmastate.lang.Terms.MethodCall /** An item in the cost accumulation trace of a [[sigma.ast.ErgoTree]] evaluation. */ @@ -35,7 +34,7 @@ object FixedCostItem { * @param opDesc descriptor of the ErgoTree operation * @param costKind type based cost descriptor added to accumulator * @param tpe concrete type on this the operation is executed - * @see [[sigmastate.LE]], [[sigmastate.GT]] + * @see [[LE]], [[GT]] */ case class TypeBasedCostItem( opDesc: OperationDesc, diff --git a/interpreter/shared/src/main/scala/sigmastate/interpreter/ErgoTreeEvaluator.scala b/interpreter/shared/src/main/scala/sigmastate/interpreter/ErgoTreeEvaluator.scala index f134b1ae6b..1790c5b9d2 100644 --- a/interpreter/shared/src/main/scala/sigmastate/interpreter/ErgoTreeEvaluator.scala +++ b/interpreter/shared/src/main/scala/sigmastate/interpreter/ErgoTreeEvaluator.scala @@ -365,7 +365,7 @@ object ErgoTreeEvaluator { type DataEnv = Map[Int, Any] /** Size of data block in bytes. Used in JIT cost calculations. - * @see [[sigmastate.NEQ]], + * @see [[NEQ]], */ val DataBlockSize: Int = 512 diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/BoolToSigmaPropSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/BoolToSigmaPropSerializer.scala index 757ca1b52c..c3dcb18a7b 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/BoolToSigmaPropSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/BoolToSigmaPropSerializer.scala @@ -1,9 +1,8 @@ package sigmastate.serialization -import sigma.ast._ +import sigma.ast.{BoolToSigmaProp, _} import sigma.ast.global._ import sigma.serialization.CoreByteWriter.DataInfo -import sigmastate.BoolToSigmaProp import sigmastate.lang.Terms._ import sigmastate.utils.SigmaByteWriter._ import sigmastate.utils.{SigmaByteReader, SigmaByteWriter} diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/CreateProveDlogSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/CreateProveDlogSerializer.scala index ad99cb76fe..2553d2ec92 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/CreateProveDlogSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/CreateProveDlogSerializer.scala @@ -1,8 +1,7 @@ package sigmastate.serialization -import sigma.ast.SGroupElement +import sigma.ast.{CreateProveDlog, SGroupElement} import sigma.serialization.CoreByteWriter._ -import sigmastate.CreateProveDlog import sigma.ast.Value import sigma.ast.global._ import sigmastate.lang.Terms.ValueOps diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/ErgoTreeSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/ErgoTreeSerializer.scala index 96a920afc7..216a86e1e7 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/ErgoTreeSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/ErgoTreeSerializer.scala @@ -1,7 +1,7 @@ package sigmastate.serialization import org.ergoplatform.validation.ValidationRules.{CheckDeserializedScriptIsSigmaProp, CheckHeaderSizeBit} -import sigma.ast.Constant +import sigma.ast.{Constant, SType, SubstConstants} import sigmastate.lang.DeserializationSigmaBuilder import sigmastate.lang.Terms.ValueOps import sigmastate.utils.{SigmaByteReader, SigmaByteWriter} @@ -10,7 +10,6 @@ import sigma.util.safeNewArray import sigmastate.utxo.ComplexityTable import debox.cfor import sigma.VersionContext -import sigma.ast.SType import sigma.serialization.{ReaderPositionLimitExceeded, SerializerException} import sigma.validation.{SigmaValidationSettings, ValidationException} import sigma.validation.ValidationRules.CheckPositionLimit @@ -291,7 +290,7 @@ class ErgoTreeSerializer { /** Transforms serialized bytes of ErgoTree with segregated constants by * replacing constants at given positions with new values. This operation * allow to use serialized scripts as pre-defined templates. - * See [[sigmastate.SubstConstants]] for details. + * See [[SubstConstants]] for details. * * @param scriptBytes serialized ErgoTree with ConstantSegregationFlag set to 1. * @param positions zero based indexes in ErgoTree.constants array which diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/LogicalNotSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/LogicalNotSerializer.scala index d37b776c9f..b83defcaf1 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/LogicalNotSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/LogicalNotSerializer.scala @@ -1,7 +1,7 @@ package sigmastate.serialization +import sigma.ast.LogicalNot import sigma.serialization.CoreByteWriter.DataInfo -import sigmastate.LogicalNot import sigma.ast.Operations.LogicalNotInfo.inputArg import sigma.ast.global._ import sigmastate.lang.Terms._ diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/ModQArithOpSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/ModQArithOpSerializer.scala index 96a6d56e95..1ed0334e7c 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/ModQArithOpSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/ModQArithOpSerializer.scala @@ -1,13 +1,12 @@ package sigmastate.serialization -import sigma.ast.SType +import sigma.ast.{ModQArithOp, ModQArithOpCompanion, SType} import sigma.ast.global.{BigIntValue, SValue} import sigma.serialization.CoreByteWriter.DataInfo import sigma.ast.Value import sigmastate.lang.Terms._ import sigmastate.utils.SigmaByteWriter._ import sigmastate.utils.{SigmaByteReader, SigmaByteWriter} -import sigmastate.{ModQArithOp, ModQArithOpCompanion} // TODO v6.0: make sure it is covered with tests (see https://github.com/ScorexFoundation/sigmastate-interpreter/issues/327) case class ModQArithOpSerializer(override val opDesc: ModQArithOpCompanion, cons: (BigIntValue, BigIntValue) => BigIntValue) diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/ModQSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/ModQSerializer.scala index b8eb0d58ed..08fa78d3ab 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/ModQSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/ModQSerializer.scala @@ -1,7 +1,6 @@ package sigmastate.serialization -import sigma.ast.SType -import sigmastate.ModQ +import sigma.ast.{ModQ, SType} import sigma.ast.Value import sigmastate.lang.Terms._ import sigmastate.utils.SigmaByteWriter._ diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/OneArgumentOperationSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/OneArgumentOperationSerializer.scala index 2c82709509..b5d0ece2e4 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/OneArgumentOperationSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/OneArgumentOperationSerializer.scala @@ -1,13 +1,12 @@ package sigmastate.serialization -import sigma.ast.SType +import sigma.ast.{OneArgumentOperation, OneArgumentOperationCompanion, SType} import sigma.serialization.CoreByteWriter.DataInfo import sigma.ast.Value import sigma.ast.global.SValue import sigmastate.lang.Terms._ import sigmastate.utils.SigmaByteWriter._ import sigmastate.utils.{SigmaByteReader, SigmaByteWriter} -import sigmastate.{OneArgumentOperation, OneArgumentOperationCompanion} case class OneArgumentOperationSerializer[T <: SType](opDesc: OneArgumentOperationCompanion, cons: Value[T] => SValue) extends ValueSerializer[OneArgumentOperation[T, SType]] { diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/SubstConstantsSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/SubstConstantsSerializer.scala index 9304a09e3b..8ceffa5f24 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/SubstConstantsSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/SubstConstantsSerializer.scala @@ -2,13 +2,12 @@ package sigmastate.serialization import sigma.ast.SCollection.{SByteArray, SIntArray} import sigma.ast.global.SValue -import sigma.ast.Value +import sigma.ast.{SubstConstants, Value} import sigmastate.lang.Terms._ import sigmastate.utils.SigmaByteWriter._ import sigmastate.utils.{SigmaByteReader, SigmaByteWriter} import sigma.ast.{SCollection, SType} import sigma.serialization.CoreByteWriter.DataInfo -import sigmastate.SubstConstants object SubstConstantsSerializer extends ValueSerializer[SubstConstants[SType]] { import sigma.ast.Operations.SubstConstantsInfo._ diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/TwoArgumentsSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/TwoArgumentsSerializer.scala index b60facccec..c1b2f5079f 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/TwoArgumentsSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/TwoArgumentsSerializer.scala @@ -1,13 +1,12 @@ package sigmastate.serialization -import sigma.ast.SType +import sigma.ast.{SType, TwoArgumentOperationCompanion, TwoArgumentsOperation} import sigma.ast.global.SValue import sigma.serialization.CoreByteWriter.DataInfo import sigma.ast.Value import sigmastate.lang.Terms._ import sigmastate.utils.SigmaByteWriter._ import sigmastate.utils.{SigmaByteReader, SigmaByteWriter} -import sigmastate.{TwoArgumentOperationCompanion, TwoArgumentsOperation} case class TwoArgumentsSerializer[LIV <: SType, RIV <: SType, OV <: Value[SType]] (override val opDesc: TwoArgumentOperationCompanion, constructor: (Value[LIV], Value[RIV]) => Value[SType]) diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/AtLeastSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/AtLeastSerializer.scala index 590c418e44..e31098cccf 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/AtLeastSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/AtLeastSerializer.scala @@ -1,9 +1,8 @@ package sigmastate.serialization.transformers import sigma.ast.global.SigmaPropValue -import sigma.ast.{SCollection, SInt, SSigmaProp} +import sigma.ast.{AtLeast, SCollection, SInt, SSigmaProp, Value} import sigma.ast.Operations.AtLeastInfo -import sigma.ast.Value import sigmastate.lang.Terms._ import sigmastate._ import sigmastate.serialization.ValueSerializer diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/CreateProveDHTupleSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/CreateProveDHTupleSerializer.scala index abe146a2ae..a8c79680e7 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/CreateProveDHTupleSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/CreateProveDHTupleSerializer.scala @@ -1,8 +1,7 @@ package sigmastate.serialization.transformers -import sigma.ast.SGroupElement +import sigma.ast.{CreateProveDHTuple, SGroupElement} import sigma.ast.global.SigmaPropValue -import sigmastate.CreateProveDHTuple import sigma.ast.Value import sigmastate.lang.Terms._ import sigmastate.serialization._ diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/LogicalTransformerSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/LogicalTransformerSerializer.scala index 2dfaa17364..2ef5733748 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/LogicalTransformerSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/LogicalTransformerSerializer.scala @@ -1,7 +1,7 @@ package sigmastate.serialization.transformers import sigma.ast.global.SValue -import sigma.ast.{SBoolean, SCollection} +import sigma.ast.{LogicalTransformerCompanion, SBoolean, SCollection} import sigma.serialization.CoreByteWriter.DataInfo import sigma.ast.Value import sigmastate.lang.Terms._ @@ -9,7 +9,6 @@ import sigmastate.serialization.ValueSerializer import sigmastate.utils.SigmaByteWriter._ import sigmastate.utils.{SigmaByteReader, SigmaByteWriter} import sigmastate.utxo.Transformer -import sigmastate.LogicalTransformerCompanion case class LogicalTransformerSerializer[I <: SCollection[SBoolean.type], O <: SBoolean.type] (opDesc: LogicalTransformerCompanion, diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/NumericCastSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/NumericCastSerializer.scala index 4e65352040..a2ded56b46 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/NumericCastSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/NumericCastSerializer.scala @@ -1,7 +1,7 @@ package sigmastate.serialization.transformers import sigma.ast.global.SValue -import sigma.ast.{SNumericType, SType, Value} +import sigma.ast.{NumericCastCompanion, SNumericType, SType, Value} import sigma.serialization.CoreByteWriter.{ArgInfo, DataInfo} import sigmastate._ import sigmastate.lang.Terms._ diff --git a/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/SigmaTransformerSerializer.scala b/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/SigmaTransformerSerializer.scala index 29542992a3..473e975cff 100644 --- a/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/SigmaTransformerSerializer.scala +++ b/interpreter/shared/src/main/scala/sigmastate/serialization/transformers/SigmaTransformerSerializer.scala @@ -1,12 +1,12 @@ package sigmastate.serialization.transformers -import sigmastate.{SigmaTransformer, SigmaTransformerCompanion} import sigma.ast.global.{SValue, SigmaPropValue} import sigmastate.serialization.ValueSerializer import sigma.util.safeNewArray import sigmastate.utils.SigmaByteWriter._ import sigmastate.utils.{SigmaByteReader, SigmaByteWriter} import debox.cfor +import sigma.ast.{SigmaTransformer, SigmaTransformerCompanion} import sigma.serialization.CoreByteWriter.DataInfo case class SigmaTransformerSerializer[I <: SigmaPropValue, O <: SigmaPropValue] diff --git a/interpreter/shared/src/test/scala/sigmastate/CalcSha256Specification.scala b/interpreter/shared/src/test/scala/sigmastate/CalcSha256Specification.scala index 8b5685eea1..1564e1ac6e 100644 --- a/interpreter/shared/src/test/scala/sigmastate/CalcSha256Specification.scala +++ b/interpreter/shared/src/test/scala/sigmastate/CalcSha256Specification.scala @@ -2,7 +2,7 @@ package sigmastate import org.scalatest.prop.TableFor2 import scorex.util.encode.Base16 -import sigma.ast.{ByteArrayConstant, SByte} +import sigma.ast.{ByteArrayConstant, CalcSha256, EQ, SByte} import sigma.ast.global.CollectionConstant import sigma.data.TrivialProp import sigmastate.helpers.{ContextEnrichingTestProvingInterpreter, ErgoLikeContextTesting, TestingCommons} diff --git a/interpreter/shared/src/test/scala/sigmastate/crypto/SigningSpecification.scala b/interpreter/shared/src/test/scala/sigmastate/crypto/SigningSpecification.scala index 204147006b..8110e16f83 100644 --- a/interpreter/shared/src/test/scala/sigmastate/crypto/SigningSpecification.scala +++ b/interpreter/shared/src/test/scala/sigmastate/crypto/SigningSpecification.scala @@ -2,9 +2,10 @@ package sigmastate.crypto import org.scalacheck.Gen import scorex.util.encode.Base16 +import sigma.ast.AtLeast import sigma.data.{CAND, COR, ProveDHTuple, SigmaBoolean} import sigma.serialization.ProveDHTupleSerializer -import sigmastate.{AtLeast, ErgoTree} +import sigmastate.{ErgoTree} import sigmastate.crypto.DLogProtocol.DLogProverInput import sigmastate.helpers.{ErgoLikeTestInterpreter, ErgoLikeTestProvingInterpreter, TestingCommons} import sigmastate.interpreter.{ContextExtension, HintsBag, ProverResult} diff --git a/interpreter/shared/src/test/scala/sigmastate/serialization/AndSerializerSpecification.scala b/interpreter/shared/src/test/scala/sigmastate/serialization/AndSerializerSpecification.scala index f74f464e43..a616529a06 100644 --- a/interpreter/shared/src/test/scala/sigmastate/serialization/AndSerializerSpecification.scala +++ b/interpreter/shared/src/test/scala/sigmastate/serialization/AndSerializerSpecification.scala @@ -1,12 +1,11 @@ package sigmastate.serialization -import sigma.ast.{BooleanConstant, Constant, IntConstant} +import sigma.ast.{AND, BooleanConstant, Constant, EQ, IntConstant, SBoolean, SCollection, SCollectionType, SInt} import sigmastate._ import sigmastate.serialization.OpCodes._ import scorex.util.encode.ZigZagEncoder.encodeZigZagInt import sigma.Extensions.ArrayOps import sigma.ast.global.BooleanConstant -import sigma.ast.{SBoolean, SCollection, SCollectionType, SInt} class AndSerializerSpecification extends TableSerializationSpecification { diff --git a/interpreter/shared/src/test/scala/sigmastate/serialization/ModQSerializerSpecification.scala b/interpreter/shared/src/test/scala/sigmastate/serialization/ModQSerializerSpecification.scala index cdeb499236..f8643d622f 100644 --- a/interpreter/shared/src/test/scala/sigmastate/serialization/ModQSerializerSpecification.scala +++ b/interpreter/shared/src/test/scala/sigmastate/serialization/ModQSerializerSpecification.scala @@ -1,5 +1,6 @@ package sigmastate.serialization +import sigma.ast.ModQ import sigma.ast.global.BigIntConstant import sigmastate._ diff --git a/interpreter/shared/src/test/scala/sigmastate/serialization/OrSerializerSpecification.scala b/interpreter/shared/src/test/scala/sigmastate/serialization/OrSerializerSpecification.scala index 22dec50809..8c0b615c54 100644 --- a/interpreter/shared/src/test/scala/sigmastate/serialization/OrSerializerSpecification.scala +++ b/interpreter/shared/src/test/scala/sigmastate/serialization/OrSerializerSpecification.scala @@ -1,12 +1,11 @@ package sigmastate.serialization -import sigma.ast.{BooleanConstant, Constant, IntConstant} +import sigma.ast.{BooleanConstant, Constant, EQ, IntConstant, OR, SBoolean, SCollection, SCollectionType, SInt} import sigmastate._ import sigmastate.serialization.OpCodes._ import scorex.util.encode.ZigZagEncoder.encodeZigZagInt import sigma.Extensions.ArrayOps import sigma.ast.global.BooleanConstant -import sigma.ast.{SBoolean, SCollection, SCollectionType, SInt} class OrSerializerSpecification extends TableSerializationSpecification { diff --git a/interpreter/shared/src/test/scala/sigmastate/serialization/SubstConstantsSerializerSpecification.scala b/interpreter/shared/src/test/scala/sigmastate/serialization/SubstConstantsSerializerSpecification.scala index b6984c4b8d..7951c0ea74 100644 --- a/interpreter/shared/src/test/scala/sigmastate/serialization/SubstConstantsSerializerSpecification.scala +++ b/interpreter/shared/src/test/scala/sigmastate/serialization/SubstConstantsSerializerSpecification.scala @@ -1,10 +1,10 @@ package sigmastate.serialization -import sigma.ast.SInt +import sigma.ast.{EQ, SInt, SubstConstants} import sigma.ast.global.IntValue import sigma.ast.{ConcreteCollection, IntArrayConstant, IntConstant} import sigmastate.serialization.ErgoTreeSerializer.DefaultSerializer -import sigmastate.{CrossVersionProps, EQ, SubstConstants} +import sigmastate.CrossVersionProps class SubstConstantsSerializerSpecification extends SerializationSpecification with CrossVersionProps { diff --git a/interpreter/shared/src/test/scala/sigmastate/serialization/TransformersSerializationSpec.scala b/interpreter/shared/src/test/scala/sigmastate/serialization/TransformersSerializationSpec.scala index 96738e78ac..5069033c13 100644 --- a/interpreter/shared/src/test/scala/sigmastate/serialization/TransformersSerializationSpec.scala +++ b/interpreter/shared/src/test/scala/sigmastate/serialization/TransformersSerializationSpec.scala @@ -1,6 +1,6 @@ package sigmastate.serialization -import sigma.ast.{SBoolean, SInt} +import sigma.ast.{AtLeast, ByteArrayToBigInt, CalcBlake2b256, CalcSha256, LongToByteArray, SBoolean, SInt, XorOf} import sigmastate._ import sigmastate.utxo._ diff --git a/interpreter/shared/src/test/scala/sigmastate/serialization/TwoArgumentSerializerSpecification.scala b/interpreter/shared/src/test/scala/sigmastate/serialization/TwoArgumentSerializerSpecification.scala index 3700e42631..ccfcab93c0 100644 --- a/interpreter/shared/src/test/scala/sigmastate/serialization/TwoArgumentSerializerSpecification.scala +++ b/interpreter/shared/src/test/scala/sigmastate/serialization/TwoArgumentSerializerSpecification.scala @@ -3,7 +3,7 @@ package sigmastate.serialization import scorex.util.encode.ZigZagEncoder.encodeZigZagLong import sigma.ast.ByteArrayConstant.ByteArrayTypeCode import sigma.ast.global.{BigIntConstant, GroupElementConstant, LongConstant} -import sigma.ast.{ByteArrayConstant, LongConstant, SLong} +import sigma.ast.{ArithOp, ByteArrayConstant, Exponentiate, LongConstant, MultiplyGroup, SLong, Xor} import sigmastate._ import sigmastate.serialization.OpCodes._ import sigmastate.serialization.ValueCodes.OpCode diff --git a/interpreter/shared/src/test/scala/sigmastate/serialization/UpcastOnDeserializationSpecification.scala b/interpreter/shared/src/test/scala/sigmastate/serialization/UpcastOnDeserializationSpecification.scala index 6e369d8801..d58d6d722e 100644 --- a/interpreter/shared/src/test/scala/sigmastate/serialization/UpcastOnDeserializationSpecification.scala +++ b/interpreter/shared/src/test/scala/sigmastate/serialization/UpcastOnDeserializationSpecification.scala @@ -1,11 +1,10 @@ package sigmastate.serialization import org.ergoplatform.Outputs -import sigma.ast.{SInt, SLong} +import sigma.ast.{SInt, SLong, Upcast} import sigma.ast.{ByteConstant, IntConstant, LongConstant} import sigmastate.lang.CheckingSigmaBuilder import sigmastate.utxo.ByIndex -import sigmastate.Upcast class UpcastOnDeserializationSpecification extends SerializationSpecification { import CheckingSigmaBuilder._ diff --git a/interpreter/shared/src/test/scala/sigmastate/serialization/generators/RelationGenerators.scala b/interpreter/shared/src/test/scala/sigmastate/serialization/generators/RelationGenerators.scala index 4477646062..bed1d2031a 100644 --- a/interpreter/shared/src/test/scala/sigmastate/serialization/generators/RelationGenerators.scala +++ b/interpreter/shared/src/test/scala/sigmastate/serialization/generators/RelationGenerators.scala @@ -1,9 +1,8 @@ package sigmastate.serialization.generators import org.scalacheck.{Arbitrary, Gen} -import sigma.ast.SInt +import sigma.ast.{If, SInt, TreeLookup} import sigma.ast.{FalseLeaf, TrueLeaf} -import sigmastate.{If, TreeLookup} trait RelationGenerators { this: ObjectGenerators with ConcreteCollectionGenerators => diff --git a/sc/jvm/src/test/scala/sigmastate/ErgoTreeBenchmarks.scala b/sc/jvm/src/test/scala/sigmastate/ErgoTreeBenchmarks.scala index 4b51d5795a..05b2fc4990 100644 --- a/sc/jvm/src/test/scala/sigmastate/ErgoTreeBenchmarks.scala +++ b/sc/jvm/src/test/scala/sigmastate/ErgoTreeBenchmarks.scala @@ -3,7 +3,7 @@ package sigmastate import debox.cfor import org.scalameter.api.Bench import sigma.BenchmarkGens -import sigma.ast.{IntConstant, SType} +import sigma.ast.{ArithOp, EQ, IntConstant, SType} import sigma.ast.global.SValue import sigmastate.serialization.OpCodes.PlusCode diff --git a/sc/shared/src/main/scala/sigmastate/eval/GraphBuilding.scala b/sc/shared/src/main/scala/sigmastate/eval/GraphBuilding.scala index cdc4833f23..1e3712e0cc 100644 --- a/sc/shared/src/main/scala/sigmastate/eval/GraphBuilding.scala +++ b/sc/shared/src/main/scala/sigmastate/eval/GraphBuilding.scala @@ -2,7 +2,7 @@ package sigmastate.eval import org.ergoplatform._ import scalan.MutableLazy -import sigma.SigmaException +import sigma.{SigmaException, ast} import sigma.ast.TypeCodes.LastConstantCode import sigma.ast.Value.Typed import sigma.ast._ @@ -496,10 +496,10 @@ trait GraphBuilding extends SigmaLibrary { IR: IRContext => case Ident(n, _) => env.getOrElse(n, !!!(s"Variable $n not found in environment $env")) - case sigmastate.Upcast(Constant(value, _), toTpe: SNumericType) => + case ast.Upcast(Constant(value, _), toTpe: SNumericType) => eval(mkConstant(toTpe.upcast(value.asInstanceOf[AnyVal]), toTpe)) - case sigmastate.Downcast(Constant(value, _), toTpe: SNumericType) => + case ast.Downcast(Constant(value, _), toTpe: SNumericType) => eval(mkConstant(toTpe.downcast(value.asInstanceOf[AnyVal]), toTpe)) // Rule: col.size --> SizeOf(col) @@ -591,12 +591,12 @@ trait GraphBuilding extends SigmaLibrary { IR: IRContext => val vv = asRep[GroupElement](_vv) sigmaDslBuilder.proveDHTuple(gv, hv, uv, vv) - case sigmastate.Exponentiate(In(l), In(r)) => + case Exponentiate(In(l), In(r)) => val lV = asRep[GroupElement](l) val rV = asRep[BigInt](r) lV.exp(rV) - case sigmastate.MultiplyGroup(In(_l), In(_r)) => + case MultiplyGroup(In(_l), In(_r)) => val l = asRep[GroupElement](_l) val r = asRep[GroupElement](_r) l.multiply(r) @@ -604,11 +604,11 @@ trait GraphBuilding extends SigmaLibrary { IR: IRContext => case GroupGenerator => sigmaDslBuilder.groupGenerator - case sigmastate.ByteArrayToBigInt(In(arr)) => + case ByteArrayToBigInt(In(arr)) => val arrV = asRep[Coll[Byte]](arr) sigmaDslBuilder.byteArrayToBigInt(arrV) - case sigmastate.LongToByteArray(In(x)) => + case LongToByteArray(In(x)) => val xV = asRep[Long](x) sigmaDslBuilder.longToByteArray(xV) @@ -914,11 +914,11 @@ trait GraphBuilding extends SigmaLibrary { IR: IRContext => val values = colBuilder.fromItems(vs: _*)(eAny) values - case sigmastate.Upcast(In(input), tpe) => + case ast.Upcast(In(input), tpe) => val elem = stypeToElem(tpe.asNumType) upcast(input)(elem) - case sigmastate.Downcast(In(input), tpe) => + case ast.Downcast(In(input), tpe) => val elem = stypeToElem(tpe.asNumType) downcast(input)(elem) diff --git a/sc/shared/src/main/scala/sigmastate/lang/SigmaCompiler.scala b/sc/shared/src/main/scala/sigmastate/lang/SigmaCompiler.scala index 76e701c94a..6590712ba0 100644 --- a/sc/shared/src/main/scala/sigmastate/lang/SigmaCompiler.scala +++ b/sc/shared/src/main/scala/sigmastate/lang/SigmaCompiler.scala @@ -6,7 +6,7 @@ import sigma.kiama.rewriting.Rewriter.{everywherebu, rewrite, rule} import org.ergoplatform.ErgoAddressEncoder.NetworkPrefix import org.ergoplatform.Global import scalan.GraphIRReflection -import sigma.ast.{SCollectionMethods, SGlobalMethods, SGroupElementMethods, Value} +import sigma.ast.{Exponentiate, MultiplyGroup, SCollectionMethods, SGlobalMethods, SGroupElementMethods, Value, Xor} import sigmastate.eval.IRContext import sigmastate.interpreter.Interpreter.ScriptEnv import sigmastate.lang.SigmaPredef.PredefinedFuncRegistry @@ -16,8 +16,7 @@ import sigmastate.utxo._ import sigma.ast._ import sigma.ast.global.SValue import SCollectionMethods.{ExistsMethod, ForallMethod, MapMethod} -import sigma.ast -import sigmastate.{Exponentiate, InterpreterReflection, MultiplyGroup, Xor} +import sigmastate.InterpreterReflection /** * @param networkPrefix network prefix to decode an ergo address from string (PK op) diff --git a/sc/shared/src/test/scala/org/ergoplatform/ErgoAddressSpecification.scala b/sc/shared/src/test/scala/org/ergoplatform/ErgoAddressSpecification.scala index 301f5ab317..0feab145de 100644 --- a/sc/shared/src/test/scala/org/ergoplatform/ErgoAddressSpecification.scala +++ b/sc/shared/src/test/scala/org/ergoplatform/ErgoAddressSpecification.scala @@ -4,7 +4,7 @@ import org.ergoplatform.ErgoAddressEncoder.{MainnetNetworkPrefix, TestnetNetwork import org.scalatest.{Assertion, TryValues} import scorex.crypto.hash.Blake2b256 import scorex.util.encode.Base58 -import sigma.ast.{ByteArrayConstant, Constant, IntConstant} +import sigma.ast.{ByteArrayConstant, Constant, IntConstant, SigmaAnd} import sigmastate.crypto.DLogProtocol.DLogProverInput import sigmastate.eval.InvalidType import sigmastate.helpers.TestingHelpers._ @@ -18,7 +18,7 @@ import sigmastate.lang.Terms.ValueOps import sigmastate.serialization.ErgoTreeSerializer.DefaultSerializer import sigmastate.serialization.ValueSerializer import sigmastate.utils.Helpers._ -import sigmastate.{CompilerCrossVersionProps, ErgoTree, SigmaAnd, UnparsedErgoTree} +import sigmastate.{CompilerCrossVersionProps, ErgoTree, UnparsedErgoTree} import sigma.SigmaDslTesting import sigmastate.ErgoTree.{ZeroHeader, setConstantSegregation} diff --git a/sc/shared/src/test/scala/org/ergoplatform/ErgoTreePredefSpec.scala b/sc/shared/src/test/scala/org/ergoplatform/ErgoTreePredefSpec.scala index 79dc77d4a3..245e71b903 100644 --- a/sc/shared/src/test/scala/org/ergoplatform/ErgoTreePredefSpec.scala +++ b/sc/shared/src/test/scala/org/ergoplatform/ErgoTreePredefSpec.scala @@ -8,11 +8,10 @@ import org.scalacheck.Gen import scorex.crypto.hash.Blake2b256 import scorex.util.Random import sigma.Colls -import sigma.ast.SByte +import sigma.ast.{AtLeast, ByteArrayConstant, CollectionConstant, EQ, IntConstant, SByte, SigmaPropConstant} import sigma.ast.global.CollectionConstant import sigma.data.{AvlTreeData, Digest32Coll, ProveDlog, TrivialProp} import sigma.util.BenchmarkUtil.measure -import sigma.ast.{ByteArrayConstant, CollectionConstant, IntConstant, SigmaPropConstant} import sigmastate._ import sigmastate.crypto.DLogProtocol.DLogProverInput import sigmastate.helpers.{CompilerTestingCommons, ContextEnrichingTestProvingInterpreter, ErgoLikeContextTesting, ErgoLikeTestInterpreter} diff --git a/sc/shared/src/test/scala/sigma/SigmaDslTesting.scala b/sc/shared/src/test/scala/sigma/SigmaDslTesting.scala index 267c9f17a3..a29c431f24 100644 --- a/sc/shared/src/test/scala/sigma/SigmaDslTesting.scala +++ b/sc/shared/src/test/scala/sigma/SigmaDslTesting.scala @@ -21,7 +21,7 @@ import sigma.util.StringUtil.StringUtilExtensions import sigmastate.ErgoTree.ZeroHeader import sigma.ast.SType.AnyOps import sigma.ast.global.SValue -import sigma.ast.{ByteArrayConstant, Constant, ConstantNode, IntConstant} +import sigma.ast.{AtLeast, ByteArrayConstant, Constant, ConstantNode, IntConstant, SOption, SSigmaProp, SType, SigmaOr} import sigmastate.crypto.DLogProtocol.DLogProverInput import sigmastate.crypto.SigmaProtocolPrivateInput import sigmastate.eval.Extensions.SigmaBooleanOps @@ -35,7 +35,6 @@ import sigmastate.serialization.ValueSerializer import sigmastate.serialization.generators.ObjectGenerators import sigmastate.utils.Helpers._ import sigmastate.utxo.{DeserializeContext, DeserializeRegister, GetVar, OptionGet} -import sigma.ast.{SOption, SSigmaProp, SType} import sigma.validation.ValidationRules.CheckSerializableTypeCode import sigma.validation.{SigmaValidationSettings, ValidationException} import sigmastate.{ErgoTree, eval} @@ -324,14 +323,14 @@ class SigmaDslTesting extends AnyPropSpec val prop = compile(env, code)(IR).asSigmaProp // Add additional oparations which are not yet implemented in ErgoScript compiler - val multisig = sigmastate.AtLeast( + val multisig = AtLeast( IntConstant(2), Array( pkAlice, DeserializeRegister(ErgoBox.R5, SSigmaProp), // deserialize pkBob DeserializeContext(2, SSigmaProp))) // deserialize pkCarol val header = ErgoTree.headerWithVersion(ZeroHeader, ergoTreeVersionInTests) - ErgoTree.withSegregation(header, sigmastate.SigmaOr(prop, multisig)) + ErgoTree.withSegregation(header, SigmaOr(prop, multisig)) } def ergoCtx(prover: FeatureProvingInterpreter, compiledTree: ErgoTree, expectedValue: B) = { diff --git a/sc/shared/src/test/scala/sigmastate/SoftForkabilitySpecification.scala b/sc/shared/src/test/scala/sigmastate/SoftForkabilitySpecification.scala index 8e79922091..4218a2b447 100644 --- a/sc/shared/src/test/scala/sigmastate/SoftForkabilitySpecification.scala +++ b/sc/shared/src/test/scala/sigmastate/SoftForkabilitySpecification.scala @@ -4,7 +4,7 @@ import org.ergoplatform._ import org.ergoplatform.validation.ValidationRules._ import org.scalatest.BeforeAndAfterAll import sigma.{Colls, SigmaTestingData} -import sigma.ast.{SBoolean, SCollection, SContext, SFunc, SGlobal, SInt} +import sigma.ast._ import sigma.ast.SPrimType.MaxPrimTypeCode import sigma.ast.TypeCodes.LastConstantCode import sigma.data.AvlTreeData @@ -12,7 +12,6 @@ import sigma.serialization.SerializerException import sigma.validation.ValidationRules.{CheckPrimitiveTypeCode, CheckSerializableTypeCode, CheckTypeCode, CheckTypeWithMethods, trySoftForkable} import sigma.validation.{ChangedRule, ReplacedRule, SigmaValidationSettings, ValidationException, ValidationRule} import sigmastate.ErgoTree.{EmptyConstants, HeaderType, ZeroHeader, setSizeBit} -import sigma.ast.{ByteArrayConstant, IntConstant, NotReadyValueInt, ValueCompanion} import sigmastate.exceptions.InterpreterException import sigmastate.helpers.TestingHelpers._ import sigmastate.helpers.{CompilerTestingCommons, ErgoLikeContextTesting, ErgoLikeTestInterpreter, ErgoLikeTestProvingInterpreter} diff --git a/sc/shared/src/test/scala/sigmastate/eval/ErgoTreeBuildingTest.scala b/sc/shared/src/test/scala/sigmastate/eval/ErgoTreeBuildingTest.scala index 0dea4ade85..600c280787 100644 --- a/sc/shared/src/test/scala/sigmastate/eval/ErgoTreeBuildingTest.scala +++ b/sc/shared/src/test/scala/sigmastate/eval/ErgoTreeBuildingTest.scala @@ -2,11 +2,10 @@ package sigmastate.eval import org.ergoplatform.{Height, Inputs, Outputs, Self} import sigmastate._ -import sigma.ast.{BlockValue, FuncValue, IntConstant, LongConstant, SigmaPropConstant, ValDef, ValUse} +import sigma.ast.{AND, BinAnd, BinOr, BinXor, BlockValue, BoolToSigmaProp, EQ, FuncValue, GE, GT, IntConstant, LE, LT, LongConstant, NEQ, SBox, SFunc, SInt, SLong, SSigmaProp, SType, SigmaAnd, SigmaOr, SigmaPropConstant, Upcast, ValDef, ValUse} import sigmastate.helpers.ContextEnrichingTestProvingInterpreter import sigmastate.interpreter.Interpreter._ import scalan.BaseCtxTests -import sigma.ast.{SBox, SFunc, SInt, SLong, SSigmaProp, SType} import sigmastate.lang.LangTests import sigmastate.lang.Terms.{Apply, ValueOps} import sigmastate.utxo._ diff --git a/sc/shared/src/test/scala/sigmastate/eval/EvaluationTest.scala b/sc/shared/src/test/scala/sigmastate/eval/EvaluationTest.scala index a75903c73c..f4137261b8 100644 --- a/sc/shared/src/test/scala/sigmastate/eval/EvaluationTest.scala +++ b/sc/shared/src/test/scala/sigmastate/eval/EvaluationTest.scala @@ -1,12 +1,11 @@ package sigmastate.eval import org.ergoplatform.ErgoBox -import sigma.ast.{ConcreteCollection, IntArrayConstant, IntConstant, SigmaPropConstant} +import sigma.ast.{AND, ConcreteCollection, CreateProveDlog, DecodePoint, EQ, IntArrayConstant, IntConstant, SSigmaProp, SigmaPropConstant, SubstConstants} import sigmastate.helpers.ContextEnrichingTestProvingInterpreter import sigmastate.helpers.TestingHelpers._ import sigmastate.interpreter.Interpreter._ import scalan.BaseCtxTests -import sigma.ast.SSigmaProp import sigma.ast.global.{SigmaPropValue, SigmaPropValueOps} import sigma.data.ProveDlog import sigmastate.lang.LangTests diff --git a/sc/shared/src/test/scala/sigmastate/serialization/ErgoTreeSerializerSpecification.scala b/sc/shared/src/test/scala/sigmastate/serialization/ErgoTreeSerializerSpecification.scala index 886e66a1c1..77819d0bea 100644 --- a/sc/shared/src/test/scala/sigmastate/serialization/ErgoTreeSerializerSpecification.scala +++ b/sc/shared/src/test/scala/sigmastate/serialization/ErgoTreeSerializerSpecification.scala @@ -3,14 +3,13 @@ package sigmastate.serialization import org.ergoplatform.ErgoBox import org.ergoplatform.validation.ValidationRules.CheckDeserializedScriptIsSigmaProp import sigma.SigmaProp -import sigma.ast.SInt +import sigma.ast.{BigIntConstant, BoolToSigmaProp, ByteConstant, ConstantPlaceholder, EQ, IntConstant, SInt, ShortConstant} import sigma.ast.global.SigmaPropValue import sigma.data.CBigInt import sigma.serialization.{ReaderPositionLimitExceeded, SerializerException} import sigma.util.Extensions.SigmaPropOps import sigma.validation.ValidationException import sigmastate.ErgoTree.EmptyConstants -import sigma.ast.{BigIntConstant, ByteConstant, ConstantPlaceholder, IntConstant, ShortConstant} import sigmastate.ErgoTree.HeaderType import sigmastate._ import sigmastate.eval.Extensions.SigmaBooleanOps diff --git a/sc/shared/src/test/scala/sigmastate/utxo/ComplexSigSpecification.scala b/sc/shared/src/test/scala/sigmastate/utxo/ComplexSigSpecification.scala index 694d64ca40..3d92cb2d72 100644 --- a/sc/shared/src/test/scala/sigmastate/utxo/ComplexSigSpecification.scala +++ b/sc/shared/src/test/scala/sigmastate/utxo/ComplexSigSpecification.scala @@ -3,7 +3,7 @@ package sigmastate.utxo import org.ergoplatform.Height import org.scalacheck.Gen import sigma.data.{AvlTreeData, CAND, COR, CTHRESHOLD} -import sigma.ast.IntConstant +import sigma.ast.{GT, IntConstant, SigmaAnd, SigmaOr} import sigmastate._ import sigmastate.helpers._ import sigmastate.lang.Terms._ diff --git a/sc/shared/src/test/scala/sigmastate/utxo/SigmaCompilerSpecification.scala b/sc/shared/src/test/scala/sigmastate/utxo/SigmaCompilerSpecification.scala index 648515e03f..2fdebcedd7 100644 --- a/sc/shared/src/test/scala/sigmastate/utxo/SigmaCompilerSpecification.scala +++ b/sc/shared/src/test/scala/sigmastate/utxo/SigmaCompilerSpecification.scala @@ -1,13 +1,12 @@ package sigmastate.utxo -import sigma.ast.SType +import sigma.ast.{GE, ModQ, SType} import sigma.data.CAnyValue import sigma.ast._ import sigma.ast.global.{GetVarInt, OptionValueOps} import sigmastate.helpers.CompilerTestingCommons import sigmastate.interpreter.Interpreter.ScriptEnv import sigmastate.lang.Terms._ -import sigmastate.{GE, ModQ} /** * Specification for compile function diff --git a/sc/shared/src/test/scala/sigmastate/utxo/examples/CoinEmissionSpecification.scala b/sc/shared/src/test/scala/sigmastate/utxo/examples/CoinEmissionSpecification.scala index 1acbdda0a4..3d0e42ce7e 100644 --- a/sc/shared/src/test/scala/sigmastate/utxo/examples/CoinEmissionSpecification.scala +++ b/sc/shared/src/test/scala/sigmastate/utxo/examples/CoinEmissionSpecification.scala @@ -4,8 +4,7 @@ import org.ergoplatform._ import org.ergoplatform.settings.ErgoAlgos import sigma.Colls import sigma.ast.global.OptionValueOps -import sigma.ast.{SBoolean, SBox, SInt, SLong, SOption} -import sigma.ast.{BlockValue, IntConstant, LongConstant, ValDef, ValUse} +import sigma.ast.{AND, BinAnd, BinOr, BlockValue, BoolToSigmaProp, EQ, GT, If, IntConstant, LE, LT, LongConstant, SBoolean, SBox, SInt, SLong, SOption, Upcast, ValDef, ValUse} import sigmastate._ import sigmastate.helpers.TestingHelpers._ import sigmastate.helpers.{CompilerTestingCommons, ContextEnrichingTestProvingInterpreter, ErgoLikeContextTesting}