Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lift the Default bound for the Circuit trait #716

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Changed

- Lift `Default` bound on the `Circuit` trait [#715]

## [0.13.1] - 2022-10-26

### Fixed
Expand Down Expand Up @@ -444,6 +448,7 @@ is necessary since `rkyv/validation` was required as a bound.
- Proof system module.

<!-- ISSUES -->
[#715]: https://github.com/dusk-network/plonk/issues/715
[#709]: https://github.com/dusk-network/plonk/issues/709
[#697]: https://github.com/dusk-network/plonk/issues/697
[#688]: https://github.com/dusk-network/plonk/issues/688
Expand Down
2 changes: 1 addition & 1 deletion src/composer/circuit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ use super::Composer;
/// Circuit implementation that can be proved by a Composer
///
/// The default implementation will be used to generate the proving arguments.
pub trait Circuit: Default {
pub trait Circuit {
/// Circuit definition
fn circuit<C>(&self, composer: &mut C) -> Result<(), Error>
where
Expand Down
2 changes: 1 addition & 1 deletion src/composer/compiler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ impl Compiler {
label: &[u8],
) -> Result<(Prover<C>, Verifier<C>), Error>
where
C: Circuit,
C: Default + Circuit,
{
Self::compile_with_circuit(pp, label, &Default::default())
}
Expand Down