Skip to content

Commit 34d8433

Browse files
dlfivefiftyclaude
andauthored
Avoid overwriting DomainSets' UnionDomain plot recipe (#985)
DomainSets v0.8.3 added DomainSetsRecipesBaseExt, which defines a plot recipe for UnionDomain. ApproxFun's identical recipe overwrote it, which is not permitted during precompilation and broke the Aqua tests. Only define ApproxFun's recipe when the extension is not available. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 1d2e264 commit 34d8433

1 file changed

Lines changed: 9 additions & 6 deletions

File tree

‎src/Plot/Plot.jl‎

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -121,12 +121,15 @@ end
121121
[real(a),real(b)], [imag(a),imag(b)]
122122
end
123123

124-
@recipe function f(dd::UnionDomain)
125-
@series component(dd,1)
126-
for k=2:ncomponents(dd)
127-
@series begin
128-
primary := false
129-
component(dd,k)
124+
# DomainSets v0.8.3 and later provide this recipe in DomainSetsRecipesBaseExt
125+
if Base.get_extension(DomainSets, :DomainSetsRecipesBaseExt) === nothing
126+
@recipe function f(dd::UnionDomain)
127+
@series component(dd,1)
128+
for k=2:ncomponents(dd)
129+
@series begin
130+
primary := false
131+
component(dd,k)
132+
end
130133
end
131134
end
132135
end

0 commit comments

Comments
 (0)