mirror of
https://github.com/sigp/lighthouse.git
synced 2026-04-20 14:28:37 +00:00
Use spec constants for PTC thresholds in fork choice (#9088)
Co-Authored-By: dapplion <35266934+dapplion@users.noreply.github.com>
This commit is contained in:
@@ -448,6 +448,11 @@ pub trait EthSpec: 'static + Default + Sync + Send + Clone + Debug + PartialEq +
|
||||
fn payload_timely_threshold() -> usize {
|
||||
Self::PTCSize::to_usize() / 2
|
||||
}
|
||||
|
||||
/// Returns the `DATA_AVAILABILITY_TIMELY_THRESHOLD` constant (PTC_SIZE / 2).
|
||||
fn data_availability_timely_threshold() -> usize {
|
||||
Self::PTCSize::to_usize() / 2
|
||||
}
|
||||
}
|
||||
|
||||
/// Macro to inherit some type values from another EthSpec.
|
||||
|
||||
Reference in New Issue
Block a user