@@ -528,10 +528,10 @@ impl Task {
528
528
Self {
529
529
id,
530
530
ty,
531
- state : RwLock :: new ( TaskMetaState :: Full ( box TaskState :: new (
531
+ state : RwLock :: new ( TaskMetaState :: Full ( Box :: new ( TaskState :: new (
532
532
description,
533
533
stats_type,
534
- ) ) ) ,
534
+ ) ) ) ) ,
535
535
}
536
536
}
537
537
@@ -546,10 +546,8 @@ impl Task {
546
546
Self {
547
547
id,
548
548
ty,
549
- state : RwLock :: new ( TaskMetaState :: Full ( box TaskState :: new_scheduled_in_scope (
550
- description,
551
- scope,
552
- stats_type,
549
+ state : RwLock :: new ( TaskMetaState :: Full ( Box :: new (
550
+ TaskState :: new_scheduled_in_scope ( description, scope, stats_type) ,
553
551
) ) ) ,
554
552
}
555
553
}
@@ -565,10 +563,8 @@ impl Task {
565
563
Self {
566
564
id,
567
565
ty,
568
- state : RwLock :: new ( TaskMetaState :: Full ( box TaskState :: new_scheduled_in_scope (
569
- description,
570
- scope,
571
- stats_type,
566
+ state : RwLock :: new ( TaskMetaState :: Full ( Box :: new (
567
+ TaskState :: new_scheduled_in_scope ( description, scope, stats_type) ,
572
568
) ) ) ,
573
569
}
574
570
}
@@ -579,18 +575,18 @@ impl Task {
579
575
trait_type_id : TraitTypeId ,
580
576
stats_type : StatsType ,
581
577
) -> Self {
582
- let ty = TaskType :: ReadScopeCollectibles ( box ReadScopeCollectiblesTaskType {
578
+ let ty = TaskType :: ReadScopeCollectibles ( Box :: new ( ReadScopeCollectiblesTaskType {
583
579
scope : target_scope,
584
580
trait_type : trait_type_id,
585
- } ) ;
581
+ } ) ) ;
586
582
let description = Self :: get_event_description_static ( id, & ty) ;
587
583
Self {
588
584
id,
589
585
ty,
590
- state : RwLock :: new ( TaskMetaState :: Full ( box TaskState :: new (
586
+ state : RwLock :: new ( TaskMetaState :: Full ( Box :: new ( TaskState :: new (
591
587
description,
592
588
stats_type,
593
- ) ) ) ,
589
+ ) ) ) ) ,
594
590
}
595
591
}
596
592
@@ -601,19 +597,19 @@ impl Task {
601
597
trait_type_id : TraitTypeId ,
602
598
stats_type : StatsType ,
603
599
) -> Self {
604
- let ty = TaskType :: ReadTaskCollectibles ( box ReadTaskCollectiblesTaskType {
600
+ let ty = TaskType :: ReadTaskCollectibles ( Box :: new ( ReadTaskCollectiblesTaskType {
605
601
task : target_task,
606
602
trait_type : trait_type_id,
607
- } ) ;
603
+ } ) ) ;
608
604
let description = Self :: get_event_description_static ( id, & ty) ;
609
605
Self {
610
606
id,
611
607
ty,
612
- state : RwLock :: new ( TaskMetaState :: Full ( box TaskState :: new_root_scoped (
608
+ state : RwLock :: new ( TaskMetaState :: Full ( Box :: new ( TaskState :: new_root_scoped (
613
609
description,
614
610
scope,
615
611
stats_type,
616
- ) ) ) ,
612
+ ) ) ) ) ,
617
613
}
618
614
}
619
615
@@ -2787,7 +2783,7 @@ impl Task {
2787
2783
if unset {
2788
2784
* state = TaskMetaState :: Unloaded ( UnloadedTaskState { stats_type } ) ;
2789
2785
} else {
2790
- * state = TaskMetaState :: Partial ( box PartialTaskState { scopes, stats_type } ) ;
2786
+ * state = TaskMetaState :: Partial ( Box :: new ( PartialTaskState { scopes, stats_type } ) ) ;
2791
2787
}
2792
2788
drop ( state) ;
2793
2789
0 commit comments