Skip to content

Commit abb4c51

Browse files
committed
add newline; <:Real -> <:Number
1 parent 9d87210 commit abb4c51

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/AbstractFFTs.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ export fft, ifft, bfft, fft!, ifft!, bfft!,
77

88
include("definitions.jl")
99

10-
end # module
10+
end # module

src/definitions.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -399,7 +399,7 @@ end
399399
##############################################################################
400400

401401

402-
struct Frequencies{T<:Real} <: AbstractVector{T}
402+
struct Frequencies{T<:Number} <: AbstractVector{T}
403403
nreal::Int
404404
n::Int
405405
multiplier::T
@@ -425,7 +425,7 @@ Frequencies object is an AbstractVector containing the frequency
425425
bin centers at every sample point. `fs` is the sample rate of the
426426
input signal.
427427
"""
428-
fftfreq(n::Int, fs::Real=1) = Frequencies(((n-1) >> 1)+1, n, fs/n)
428+
fftfreq(n::Int, fs::Number=1) = Frequencies(((n-1) >> 1)+1, n, fs/n)
429429

430430
"""
431431
rfftfreq(n, fs=1)
@@ -434,7 +434,7 @@ Return discrete fourier transform sample frequencies for use with
434434
containing the frequency bin centers at every sample point. `fs`
435435
is the sample rate of the input signal.
436436
"""
437-
rfftfreq(n::Int, fs::Real=1) = Frequencies((n >> 1)+1, (n >> 1)+1, fs/n)
437+
rfftfreq(n::Int, fs::Number=1) = Frequencies((n >> 1)+1, (n >> 1)+1, fs/n)
438438

439439
fftshift(x::Frequencies) = (x.nreal-x.n:x.nreal-1)*x.multiplier
440440

0 commit comments

Comments
 (0)