o1-labs / o1js

TypeScript framework for zk-SNARKs and zkApps
https://docs.minaprotocol.com/en/zkapps/how-to-write-a-zkapp
Apache License 2.0
500 stars 110 forks source link

Proper handling of `Struct.empty()` when one of the base types doesn't have `empty()` #1656

Closed mitschabaude closed 4 months ago

mitschabaude commented 4 months ago

Issue reported in discord: https://discord.com/channels/484437221055922177/915745847692636181/1240099940718477412

There are two issues: Group.empty() was missing, and (even worse) it being missing didn't cause an error but rather a garbage Struct.empty() result