Skip to content

Commit

Permalink
ignoring bulletproof test, impoving comments
Browse files Browse the repository at this point in the history
  • Loading branch information
kushti committed Oct 18, 2024
1 parent 7b48ddd commit 09ec5f1
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
7 changes: 5 additions & 2 deletions core/shared/src/main/scala/sigma/ast/SType.scala
Original file line number Diff line number Diff line change
Expand Up @@ -102,14 +102,15 @@ object SType {
/** Immutable empty IndexedSeq, can be used to avoid repeated allocations. */
val EmptySeq: IndexedSeq[SType] = EmptyArray

// <= V5 types, see `allPredefTypes` scaladoc below
private val v5PredefTypes = Array[SType](
SBoolean, SByte, SShort, SInt, SLong, SBigInt, SContext,
SGlobal, SHeader, SPreHeader, SAvlTree, SGroupElement, SSigmaProp, SString, SBox,
SUnit, SAny)

// V6 types, see `allPredefTypes` scaladoc below
private val v6PredefTypes = v5PredefTypes ++ Array(SUnsignedBigInt)


/** All pre-defined types should be listed here. Note, NoType is not listed.
* Should be in sync with sigmastate.lang.Types.predefTypes. */
def allPredefTypes: Seq[SType] = {
Expand Down Expand Up @@ -147,6 +148,8 @@ object SType {
* (SByte, SShort, SInt, SLong, SBigInt) and the generic tNum type parameter is
* specialized accordingly.
*
* Also, SUnsignedBigInt type is added in v6.0.
*
* This difference in behaviour is tested by `property("MethodCall on numerics")`.
*
* The regression tests in `property("MethodCall Codes")` should pass.
Expand Down Expand Up @@ -487,7 +490,7 @@ case object SLong extends SPrimType with SEmbeddable with SNumericType with SMon
}
}

/** Type of 256-bit signed integer values. Implemented using [[java.math.BigInteger]]. */
/** Type of 256-bit signed integer values. Implemented using [[java.math.BigInteger]]. */
case object SBigInt extends SPrimType with SEmbeddable with SNumericType with SMonoType {
override type WrappedType = BigInt
override val typeCode: TypeCode = 6: Byte
Expand Down
1 change: 0 additions & 1 deletion core/shared/src/main/scala/sigma/util/Extensions.scala
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,6 @@ object Extensions {
}

@inline final def toUnsignedBigIntValueExact: BigInteger = {
// todo: make the check soft-forkable
if (x.compareTo(BigInteger.ZERO) >= 0 && x.bitLength() <= 256) {
x
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -463,7 +463,8 @@ class BasicOpsSpecification extends CompilerTestingCommons
}
}

property("Bulletproof verification for a range proof") {
// todo: finish the range proof verification script and test
ignore("Bulletproof verification for a range proof") {
/*
* Original range proof verifier code by Benedikt Bunz:
*
Expand Down

0 comments on commit 09ec5f1

Please sign in to comment.