Skip to content

Commit f2c056d

Browse files
martinholtersararslan
authored andcommitted
Fix exports of functions removed from Base in 0.7.0-DEV.602 (#175)
1 parent 99d06fe commit f2c056d

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

src/DSP.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,12 @@ end
2222
@importffts
2323

2424
if VERSION >= v"0.7.0-DEV.602"
25-
include("dspbase.jl")
26-
if isdefined(Base, :DSP)
25+
if VERSION < v"0.7.0-DEV.986" # JuliaLang/julia#22763
2726
import Base: conv, conv2, deconv, filt, filt!, xcorr
2827
else
2928
export conv, conv2, deconv, filt, filt!, xcorr
3029
end
30+
include("dspbase.jl")
3131
end
3232

3333
include("util.jl")

src/lpc.jl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
module LPC
2+
3+
if VERSION >= v"0.7.0-DEV.602"
4+
using ..DSP: xcorr
5+
end
6+
27
export lpc, LPCBurg, LPCLevinson
38

49
# Dispatch types for lpc()

test/filt_stream.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ function naivefilt(h::Vector, x::Vector, resamplerate::Rational=1//1)
1212
xZeroStuffed[n*upfactor+1] = x[n+1]
1313
end
1414

15-
y = Base.filt(h, one(eltype(x)), xZeroStuffed)
15+
y = filt(h, one(eltype(x)), xZeroStuffed)
1616
y = [y[n] for n = 1:downfactor:length(y)]
1717
end
1818

@@ -82,7 +82,7 @@ function test_singlerate(h, x)
8282
@printfifinteractive( "\nTesting single-rate fitering, h is %s, x is %s. xLen = %d, hLen = %d", string(eltype(h)), string(eltype(x)), xLen, hLen )
8383

8484
@printfifinteractive( "\n\tBase.filt\n\t\t")
85-
@timeifinteractive naiveResult = Base.filt(h, 1.0, x)
85+
@timeifinteractive naiveResult = filt(h, 1.0, x)
8686

8787
@printfifinteractive( "\n\tDSP.filt( h, x, 1//1 )\n\t\t" )
8888
@timeifinteractive statelesResult = DSP.filt( h, x )
@@ -186,7 +186,7 @@ function test_interpolation(h, x, interpolation)
186186
for n = 0:xLen-1;
187187
xZeroStuffed[n*interpolation+1] = x[n+1]
188188
end
189-
naiveResult = Base.filt(h, one(eltype(h)), xZeroStuffed)
189+
naiveResult = filt(h, one(eltype(h)), xZeroStuffed)
190190
end
191191

192192
@printfifinteractive( "\n\tDSP.filt( h, x, %d//1 )\n\t\t", interpolation )

0 commit comments

Comments
 (0)