iden3 / circuits

Circom circuits used by the iden3 core protocol.
GNU General Public License v3.0
81 stars 14 forks source link

Enhancement: support >= and <= operators #94

Closed nedgar closed 4 months ago

nedgar commented 1 year ago

For some scenarios, a GTE (>=) operator would be clearer than using GT. e.g. testing minimum asset value of $100,000 must currently be expressed as operator = GT with value = [99999], but GTE 100000 would be simpler and more in line with the intent.

It appears this could be implemented easily as an OR of the outputs for EQ and GT.

Similarly for LTE (<=).

OBrezhniev commented 6 months ago

Done in Circuits V3 beta (available in the app already). GTE, LTE & BETWEEN.

nedgar commented 6 months ago

Nice, thanks @OBrezhniev!