Implement Default for ShutdownRequest
@@ -28,8 +28,8 @@ pub struct ShutdownRequest {
prover_id: Arc<AtomicI32>,
}
-impl ShutdownRequest {
- pub fn new() -> Self {
+impl Default for ShutdownRequest {
+ fn default() -> Self {
let prover_id = Arc::new(AtomicI32::from(ABSENT_PROVER_ID));
Self {
@@ -37,6 +37,12 @@ impl ShutdownRequest {
prover_id,
}
}
+}
+
+impl ShutdownRequest {
+ pub fn new() -> Self {
+ Self::default()
+ }
pub fn set_prover_id(&self, id: i32) {
self.prover_id.store(id, Ordering::SeqCst);
