1
- import Core . Compiler : abstract_call_gf_by_type, abstract_call
2
- using Core . Compiler : Const, isconstType, argtypes_to_type, tuple_tfunc, Const,
3
- getfield_tfunc, _methods_by_ftype, VarTable, cache_lookup, nfields_tfunc,
1
+ import . CC : abstract_call_gf_by_type, abstract_call_opaque_closure
2
+ using . CC : Const, isconstType, argtypes_to_type, tuple_tfunc, Const,
3
+ getfield_tfunc, _methods_by_ftype, VarTable, nfields_tfunc,
4
4
ArgInfo, singleton_type, CallMeta, MethodMatchInfo, specialize_method,
5
5
PartialOpaque, UnionSplitApplyCallInfo, typeof_tfunc, apply_type_tfunc, instanceof_tfunc,
6
6
StmtInfo
7
7
using Core: PartialStruct
8
8
using Base. Meta
9
9
10
- function Core . Compiler . abstract_call_gf_by_type (interp:: ADInterpreter , @nospecialize (f),
10
+ function CC . abstract_call_gf_by_type (interp:: ADInterpreter , @nospecialize (f),
11
11
arginfo:: ArgInfo , si:: StmtInfo , @nospecialize (atype), sv:: InferenceState , max_methods:: Int )
12
12
(;argtypes) = arginfo
13
13
if interp. backward
@@ -25,7 +25,7 @@ function Core.Compiler.abstract_call_gf_by_type(interp::ADInterpreter, @nospecia
25
25
mi = specialize_method (call. info. results. matches[1 ], preexisting= true )
26
26
ci = get (rinterp. unopt[rinterp. current_level], mi, nothing )
27
27
clos = AbstractCompClosure (rinterp. current_level, 1 , call. info, ci. stmt_info)
28
- clos = Core . PartialOpaque (Core. OpaqueClosure{<: Tuple , <: Any }, nothing , sv. linfo, clos)
28
+ clos = PartialOpaque (Core. OpaqueClosure{<: Tuple , <: Any }, nothing , sv. linfo, clos)
29
29
elseif isa (call. info, RRuleInfo)
30
30
if rinterp. current_level == 1
31
31
clos = getfield_tfunc (call. info. rrule_rt, Const (2 ))
@@ -550,7 +550,7 @@ function infer_prim_closure(interp::ADInterpreter, pc::PrimClosure, @nospecializ
550
550
error ()
551
551
end
552
552
553
- function Core . Compiler . abstract_call_opaque_closure (interp:: ADInterpreter ,
553
+ function CC . abstract_call_opaque_closure (interp:: ADInterpreter ,
554
554
closure:: PartialOpaque , arginfo:: ArgInfo , sv:: InferenceState , check:: Bool = true )
555
555
556
556
if isa (closure. source, AbstractCompClosure)
@@ -565,8 +565,6 @@ function Core.Compiler.abstract_call_opaque_closure(interp::ADInterpreter,
565
565
return infer_prim_closure (interp, closure. source, argtypes[2 ], sv)
566
566
end
567
567
568
- rt = invoke (Core. Compiler. abstract_call_opaque_closure, Tuple{AbstractInterpreter, PartialOpaque, ArgInfo, InferenceState, Bool},
569
- interp, closure, arginfo, sv, check)
570
-
571
- return rt
568
+ return @invoke CC. abstract_call_opaque_closure (interp:: AbstractInterpreter ,
569
+ closure:: PartialOpaque , arginfo:: ArgInfo , sv:: InferenceState , check:: Bool )
572
570
end
0 commit comments