Skip to content

Commit 31ff073

Browse files
committed
work around type inference
1 parent 11a641b commit 31ff073

File tree

3 files changed

+11
-11
lines changed

3 files changed

+11
-11
lines changed

src/Operators/banded/Conversion.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ rangespace(C::ConcreteConversion)=C.rangespace
2626

2727

2828

29-
function defaultConversion(a::Space,b::Space)
29+
function defaultConversion(a::Space,b::Space)::Any
3030
if a==b
3131
Conversion(a)
3232
elseif conversion_type(a,b)==NoSpace()

src/Operators/spacepromotion.jl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ rangespace(S::SpaceOperator) = S.rangespace
4747

4848

4949
##TODO: Do we need both max and min?
50-
function findmindomainspace(ops::AbstractVector)
50+
function findmindomainspace(ops::AbstractVector)::Any
5151
sp = UnsetSpace()
5252

5353
for op in ops
@@ -57,7 +57,7 @@ function findmindomainspace(ops::AbstractVector)
5757
sp
5858
end
5959

60-
function findmaxrangespace(ops::AbstractVector)
60+
function findmaxrangespace(ops::AbstractVector)::Any
6161
sp = UnsetSpace()
6262

6363
for op in ops
@@ -80,9 +80,9 @@ promoterangespace(P::Operator,sp::Space) = promoterangespace(P,sp,rangespace(P))
8080
promotedomainspace(P::Operator,sp::Space) = promotedomainspace(P,sp,domainspace(P))
8181

8282

83-
promoterangespace(P::Operator,sp::Space,cursp::Space) =
83+
promoterangespace(P::Operator,sp::Space,cursp::Space)::Any =
8484
(sp==cursp) ? P : Conversion(cursp,sp)*P
85-
promotedomainspace(P::Operator,sp::Space,cursp::Space) =
85+
promotedomainspace(P::Operator,sp::Space,cursp::Space)::Any =
8686
(sp==cursp) ? P : P*Conversion(sp,cursp)
8787

8888

@@ -134,7 +134,7 @@ choosedomainspace(A::Operator,_) = choosedomainspace(A)
134134

135135
choosedomainspace(A) = choosedomainspace(A,UnsetSpace())
136136

137-
function choosedomainspace(ops::AbstractVector,spin)
137+
function choosedomainspace(ops::AbstractVector,spin)::Any
138138
sp = UnsetSpace()
139139

140140
for op in ops

src/Space.jl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ mappoint(a::Domain,b::Space,x)=mappoint(a,domain(b),x)
146146

147147
for FUNC in (:conversion_rule,:maxspace_rule,:union_rule)
148148
@eval begin
149-
function $FUNC(a,b)
149+
function $FUNC(a,b)::Any
150150
if spacescompatible(a,b)
151151
a
152152
else
@@ -168,7 +168,7 @@ end
168168

169169

170170
# gives a space c that has a banded conversion operator TO a and b
171-
function conversion_type(a,b)
171+
function conversion_type(a,b)::Any
172172
if spacescompatible(a,b)
173173
a
174174
elseif !domainscompatible(a,b)
@@ -187,7 +187,7 @@ end
187187

188188
# gives a space c that has a banded conversion operator FROM a and b
189189
maxspace(a,b) = NoSpace() # TODO: this fixes weird bug with Nothing
190-
function maxspace(a::Space,b::Space)
190+
function maxspace(a::Space, b::Space)::Any
191191
if spacescompatible(a,b)
192192
return a
193193
elseif !domainscompatible(a,b)
@@ -247,7 +247,7 @@ union(a::AmbiguousSpace, b::Space) = b
247247
union(a::Space, b::AmbiguousSpace) = a
248248

249249

250-
function union_by_union_rule(a::Space,b::Space)
250+
function union_by_union_rule(a::Space,b::Space)::Any
251251
if spacescompatible(a,b)
252252
if isambiguous(domain(a))
253253
return b
@@ -262,7 +262,7 @@ function union_by_union_rule(a::Space,b::Space)
262262
union_rule(b,a)
263263
end
264264

265-
function union(a::Space, b::Space)
265+
function union(a::Space, b::Space)::Any
266266
cr = union_by_union_rule(a,b)
267267
cr isa NoSpace || return cr
268268

0 commit comments

Comments
 (0)