Skip to content

Commit efa4faf

Browse files
committed
Also disable word splitting when the matches are not fully covered (regardless of number of methods) [Using Claude]
1 parent 1450d94 commit efa4faf

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Compiler/src/abstractinterpretation.jl

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,12 @@ function abstract_call_gf_by_type(interp::AbstractInterpreter, @nospecialize(fun
123123
return Future(CallMeta(Any, Any, Effects(), NoCallInfo()))
124124
end
125125

126+
# Disable inference when not fully covered (similar to union split limit)
127+
if !fully_covering(matches)
128+
add_remark!(interp, sv, "Inference disabled for method without full coverage")
129+
return Future(CallMeta(Any, Any, Effects(), NoCallInfo()))
130+
end
131+
126132
(; valid_worlds, applicable) = matches
127133
update_valid_age!(sv, valid_worlds) # need to record the negative world now, since even if we don't generate any useful information, inlining might want to add an invoke edge and it won't have this information anymore
128134
if bail_out_toplevel_call(interp, sv)

0 commit comments

Comments
 (0)