File tree Expand file tree Collapse file tree 4 files changed +33
-4
lines changed Expand file tree Collapse file tree 4 files changed +33
-4
lines changed Original file line number Diff line number Diff line change @@ -173,6 +173,15 @@ impl Property for Correctness {
173
173
}
174
174
}
175
175
176
+ fn from_multi_a ( _: usize , _: usize ) -> Self {
177
+ Correctness {
178
+ base : Base :: B ,
179
+ input : Input :: Any ,
180
+ dissatisfiable : true ,
181
+ unit : true ,
182
+ }
183
+ }
184
+
176
185
fn from_hash ( ) -> Self {
177
186
Correctness {
178
187
base : Base :: B ,
Original file line number Diff line number Diff line change @@ -122,6 +122,14 @@ impl Property for Malleability {
122
122
}
123
123
}
124
124
125
+ fn from_multi_a ( _: usize , _: usize ) -> Self {
126
+ Malleability {
127
+ dissat : Dissat :: Unique ,
128
+ safe : true ,
129
+ non_malleable : true ,
130
+ }
131
+ }
132
+
125
133
fn from_hash ( ) -> Self {
126
134
Malleability {
127
135
dissat : Dissat :: Unknown ,
Original file line number Diff line number Diff line change @@ -270,10 +270,7 @@ pub trait Property: Sized {
270
270
fn from_multi ( k : usize , n : usize ) -> Self ;
271
271
272
272
/// Type property of a `MultiA` fragment
273
- fn from_multi_a ( k : usize , n : usize ) -> Self {
274
- // default impl same as multi
275
- Self :: from_multi ( k, n)
276
- }
273
+ fn from_multi_a ( k : usize , n : usize ) -> Self ;
277
274
278
275
/// Type property of a hash fragment
279
276
fn from_hash ( ) -> Self ;
@@ -584,6 +581,13 @@ impl Property for Type {
584
581
}
585
582
}
586
583
584
+ fn from_multi_a ( k : usize , n : usize ) -> Self {
585
+ Type {
586
+ corr : Property :: from_multi_a ( k, n) ,
587
+ mall : Property :: from_multi_a ( k, n) ,
588
+ }
589
+ }
590
+
587
591
fn from_hash ( ) -> Self {
588
592
Type {
589
593
corr : Property :: from_hash ( ) ,
Original file line number Diff line number Diff line change @@ -191,6 +191,14 @@ impl Property for CompilerExtData {
191
191
}
192
192
}
193
193
194
+ fn from_multi_a ( k : usize , n : usize ) -> Self {
195
+ CompilerExtData {
196
+ branch_prob : None ,
197
+ sat_cost : 66.0 * k as f64 + ( n - k) as f64 ,
198
+ dissat_cost : Some ( n as f64 ) , /* <w_n> ... <w_1> := 0x00 ... 0x00 (n times) */
199
+ }
200
+ }
201
+
194
202
fn from_hash ( ) -> Self {
195
203
CompilerExtData {
196
204
branch_prob : None ,
You can’t perform that action at this time.
0 commit comments