@@ -563,18 +563,18 @@ CC.bail_out_toplevel_call(::REPLInterpreter, ::CC.InferenceLoopState, ::CC.Infer
563
563
# be employed, for instance, by `typeinf_ext_toplevel`.
564
564
is_repl_frame (sv:: CC.InferenceState ) = sv. linfo. def isa Module && sv. cache_mode === CC. CACHE_MODE_NULL
565
565
566
- function is_call_graph_uncached (sv:: CC.InferenceState )
566
+ function is_call_stack_uncached (sv:: CC.InferenceState )
567
567
CC. is_cached (sv) && return false
568
568
parent = CC. frame_parent (sv)
569
569
parent === nothing && return true
570
- return is_call_graph_uncached (parent:: CC.InferenceState )
570
+ return is_call_stack_uncached (parent:: CC.InferenceState )
571
571
end
572
572
573
573
# aggressive global binding resolution within `repl_frame`
574
574
function CC. abstract_eval_globalref (interp:: REPLInterpreter , g:: GlobalRef , bailed:: Bool ,
575
575
sv:: CC.InferenceState )
576
576
# Ignore saw_latestworld
577
- if (interp. limit_aggressive_inference ? is_repl_frame (sv) : is_call_graph_uncached (sv))
577
+ if (interp. limit_aggressive_inference ? is_repl_frame (sv) : is_call_stack_uncached (sv))
578
578
partition = CC. abstract_eval_binding_partition! (interp, g, sv)
579
579
if CC. is_defined_const_binding (CC. binding_kind (partition))
580
580
return CC. RTEffects (Const (CC. partition_restriction (partition)), Union{}, CC. EFFECTS_TOTAL)
@@ -598,33 +598,11 @@ function is_repl_frame_getproperty(sv::CC.InferenceState)
598
598
return is_repl_frame (CC. frame_parent (sv))
599
599
end
600
600
601
- # aggressive global binding resolution for `getproperty(::Module, ::Symbol)` calls within `repl_frame`
602
- function CC. builtin_tfunction (interp:: REPLInterpreter , @nospecialize (f),
603
- argtypes:: Vector{Any} , sv:: CC.InferenceState )
604
- if f === Core. getglobal && (interp. limit_aggressive_inference ? is_repl_frame_getproperty (sv) : is_call_graph_uncached (sv))
605
- if length (argtypes) == 2
606
- a1, a2 = argtypes
607
- if isa (a1, Const) && isa (a2, Const)
608
- a1val, a2val = a1. val, a2. val
609
- if isa (a1val, Module) && isa (a2val, Symbol)
610
- g = GlobalRef (a1val, a2val)
611
- if isdefined_globalref (g)
612
- return Const (ccall (:jl_get_globalref_value , Any, (Any,), g))
613
- end
614
- return Union{}
615
- end
616
- end
617
- end
618
- end
619
- return @invoke CC. builtin_tfunction (interp:: CC.AbstractInterpreter , f:: Any ,
620
- argtypes:: Vector{Any} , sv:: CC.InferenceState )
621
- end
622
-
623
601
# aggressive concrete evaluation for `:inconsistent` frames within `repl_frame`
624
602
function CC. concrete_eval_eligible (interp:: REPLInterpreter , @nospecialize (f),
625
603
result:: CC.MethodCallResult , arginfo:: CC.ArgInfo ,
626
604
sv:: CC.InferenceState )
627
- if (interp. limit_aggressive_inference ? is_repl_frame (sv) : is_call_graph_uncached (sv))
605
+ if (interp. limit_aggressive_inference ? is_repl_frame (sv) : is_call_stack_uncached (sv))
628
606
neweffects = CC. Effects (result. effects; consistent= CC. ALWAYS_TRUE)
629
607
result = CC. MethodCallResult (result. rt, result. exct, neweffects, result. edge,
630
608
result. edgecycle, result. edgelimited, result. volatile_inf_result)
0 commit comments