mirror of
https://github.com/logos-storage/plonky2.git
synced 2026-01-13 11:13:07 +00:00
23 lines
443 B
Rust
23 lines
443 B
Rust
use crate::target::Target;
|
|
|
|
/// A named copy constraint.
|
|
pub struct CopyConstraint {
|
|
pub pair: (Target, Target),
|
|
pub name: String,
|
|
}
|
|
|
|
impl From<(Target, Target)> for CopyConstraint {
|
|
fn from(pair: (Target, Target)) -> Self {
|
|
Self {
|
|
pair,
|
|
name: String::new(),
|
|
}
|
|
}
|
|
}
|
|
|
|
impl CopyConstraint {
|
|
pub fn new(pair: (Target, Target), name: String) -> Self {
|
|
Self { pair, name }
|
|
}
|
|
}
|