mirror of
https://github.com/Sunscreen-tech/Sunscreen.git
synced 2026-01-13 15:47:59 -05:00
* Misc doc fixes
* Fix sunscreen zkp exports
* Fix broken api doc reference
* Add starter zkp example
* Use ZkpRuntime::new in sudoku example
* Use ? over unwrap in zkp examples
* Refactor pattern matching
No functionality changes
* Disallow `mut` args in fhe/zkp programs
* Play around with allowing cipher|plain values
* Allow user-declared plain|cipher values
NOTE: Not fully implemented. Will not work on Rational types until we
factor out literal->plaintext into a proper trait.
This allows, e.g.
```rust
fn simple_sum(a: Cipher<Signed>, b: Cipher<Signed>) -> Cipher<Signed> {
let mut sum = fhe_var(0);
sum = sum + a;
sum = sum + b;
fhe_out(sum)
}
````
* Refactor array::output()
* More targeted compiler error messages on invalid return values
* Add option for var.into() rather than fhe_out(var)
* Fix incorrect macro invocation
* Add trait for inserting const as plaintext
* Impl all arithmetic operations for indeterminate nodes
* Offer an `fhe_var!` macro
* Offer a zkp_var! macro
* Offer a (safe) debug impl for zkp program nodes
* Fix tests
* Add test for fhe_var!
* Simplify tf out of sudoku
* Simplify fhe input() codegen
* Marginally better compiler error messages on invalid fhe program arg types
* Fix error for fhe program argument attributes
* Throw appropriate compiler error on generics
* Silence clippy warnings in generated code
These I think are typically ignored by default when consuming proc macros but might as well be explicit
* Fixup quote_spanned invocations
Unsure how important this is, but see here: https://docs.rs/quote/latest/quote/macro.quote_spanned.html#syntax
* Automatically call `.into()` on fhe prog return values
* Factor fhe_program_impl
* Further factor fhe_program_impl
So that token generation happens in helper methods, and the ultimate output() func is readable
* Fix doctests
* Fix clippy warnings
* Remove TODOs
* Add missing example runs to CI
* Oops: fix 232 > 64
* Allow arbitrary expressions in fhe_var!
* Use custom "into" to support impls on []
* Support explicit #[private] params
* Remove `backend = "bulletproofs"` attribute
* Address PR reveiw