@@ -148,7 +148,7 @@ function code_typed_by_type(@nospecialize(tt::Type);
148
148
return frame. linfo, frame. src, valid_worlds
149
149
end
150
150
151
- function fsmi_generator (world:: UInt , source:: LineNumberNode , passtype, fsmitype:: Type{Type{T}} , fargtypes) where T
151
+ function fsmi_generator (world:: UInt , source, passtype, fsmitype:: Type{Type{T}} , fargtypes) where T
152
152
@nospecialize
153
153
# get typed code of the inference function evaluated in get_slots
154
154
# but this time with concrete argument types
@@ -179,20 +179,10 @@ function fsmi_generator(world::UInt, source::LineNumberNode, passtype, fsmitype:
179
179
# generate code to instantiate the concrete type
180
180
stub = Core. GeneratedFunctionStub (identity, Core. svec (:pass , :fsmi , :fargs ), Core. svec ())
181
181
if isempty (slots)
182
- exprs = stub (world, source, :(return $ T ()))
182
+ return stub (world, source, :(return $ T ()))
183
183
else
184
- exprs = stub (world, source, :(return $ T {$(slots...)} ()))
184
+ return stub (world, source, :(return $ T {$(slots...)} ()))
185
185
end
186
- # lower codeinfo to pass world age and invalidation edges
187
- ci = ccall (:jl_expand_and_resolve , Any, (Any, Any, Any), exprs, passtype. name. module, Core. svec ())
188
- ci. min_world = min_world
189
- ci. max_world = max_world
190
- ci. edges = Core. MethodInstance[mi]
191
- if isdefined (Base, :__has_internal_change ) && Base. __has_internal_change (v " 1.12-alpha" , :codeinfonargs ) # due to julia#54341
192
- ci. nargs = 3
193
- ci. isva = true
194
- end
195
- return ci
196
186
end
197
187
198
188
# JuliaLang/julia#48611: world age is exposed to generated functions, and should be used
0 commit comments