@@ -87,8 +87,11 @@ pub trait Delegate: Sized {
87
87
input : <Self :: Cx as Cx >:: Input ,
88
88
) -> <Self :: Cx as Cx >:: Result ;
89
89
fn is_initial_provisional_result ( result : <Self :: Cx as Cx >:: Result ) -> Option < PathKind > ;
90
- fn on_stack_overflow ( cx : Self :: Cx , input : <Self :: Cx as Cx >:: Input ) -> <Self :: Cx as Cx >:: Result ;
91
- fn on_fixpoint_overflow (
90
+ fn stack_overflow_result (
91
+ cx : Self :: Cx ,
92
+ input : <Self :: Cx as Cx >:: Input ,
93
+ ) -> <Self :: Cx as Cx >:: Result ;
94
+ fn fixpoint_overflow_result (
92
95
cx : Self :: Cx ,
93
96
input : <Self :: Cx as Cx >:: Input ,
94
97
) -> <Self :: Cx as Cx >:: Result ;
@@ -885,7 +888,7 @@ impl<D: Delegate<Cx = X>, X: Cx> SearchGraph<D> {
885
888
}
886
889
887
890
debug ! ( "encountered stack overflow" ) ;
888
- D :: on_stack_overflow ( cx, input)
891
+ D :: stack_overflow_result ( cx, input)
889
892
}
890
893
891
894
/// When reevaluating a goal with a changed provisional result, all provisional cache entry
@@ -1033,7 +1036,7 @@ impl<D: Delegate<Cx = X>, X: Cx> SearchGraph<D, X> {
1033
1036
RebaseReason :: Ambiguity => {
1034
1037
* result = D :: propagate_ambiguity ( cx, input, * result) ;
1035
1038
}
1036
- RebaseReason :: Overflow => * result = D :: on_fixpoint_overflow ( cx, input) ,
1039
+ RebaseReason :: Overflow => * result = D :: fixpoint_overflow_result ( cx, input) ,
1037
1040
RebaseReason :: ReachedFixpoint ( None ) => { }
1038
1041
RebaseReason :: ReachedFixpoint ( Some ( path_kind) ) => {
1039
1042
if !popped_head. usages . is_single ( path_kind) {
@@ -1362,7 +1365,7 @@ impl<D: Delegate<Cx = X>, X: Cx> SearchGraph<D, X> {
1362
1365
i += 1 ;
1363
1366
if i >= D :: FIXPOINT_STEP_LIMIT {
1364
1367
debug ! ( "canonical cycle overflow" ) ;
1365
- let result = D :: on_fixpoint_overflow ( cx, input) ;
1368
+ let result = D :: fixpoint_overflow_result ( cx, input) ;
1366
1369
self . rebase_provisional_cache_entries ( cx, & stack_entry, RebaseReason :: Overflow ) ;
1367
1370
return EvaluationResult :: finalize ( stack_entry, encountered_overflow, result) ;
1368
1371
}
0 commit comments