Skip to content

Commit 9bb71fd

Browse files
committed
removes Compat
1 parent e7c1bb9 commit 9bb71fd

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

src/LibSndFile.jl

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,6 @@ __precompile__()
22

33
module LibSndFile
44

5-
using Compat
6-
# we should be able to remove UTF8String and rename to String when we drop 0.4 support
7-
import Compat: UTF8String, view
8-
95
using SampledSignals
106
import SampledSignals: nchannels, nframes, samplerate, unsafe_read!, unsafe_write
117
using FileIO
@@ -56,10 +52,10 @@ subformatcode(::Type{Float64}) = SF_FORMAT_DOUBLE
5652
# WAV is a subtype of RIFF, as is AVI
5753
function detectwav(io)
5854
seekstart(io)
59-
magic = UTF8String(read(io, UInt8, 4))
55+
magic = String(read(io, UInt8, 4))
6056
magic == "RIFF" || return false
6157
seek(io, 8)
62-
submagic = UTF8String(read(io, UInt8, 4))
58+
submagic = String(read(io, UInt8, 4))
6359

6460
submagic == "WAVE"
6561
end
@@ -94,7 +90,7 @@ type SF_INFO
9490
end
9591

9692
type SndFileSink{T} <: SampleSink
97-
path::UTF8String
93+
path::String
9894
filePtr::Ptr{Void}
9995
sfinfo::SF_INFO
10096
nframes::Int64
@@ -113,7 +109,7 @@ nframes(sink::SndFileSink) = sink.nframes
113109
Base.eltype(sink::SndFileSink) = fmt_to_type(sink.sfinfo.format)
114110

115111
type SndFileSource{T} <: SampleSource
116-
path::UTF8String
112+
path::String
117113
filePtr::Ptr{Void}
118114
sfinfo::SF_INFO
119115
pos::Int64

0 commit comments

Comments
 (0)