diff --git a/src/common.jl b/src/common.jl index 14f7fc5d..eee8518f 100644 --- a/src/common.jl +++ b/src/common.jl @@ -1,5 +1,9 @@ ## Generic ## +if VERSION < v"1.1" + eachcol(A::AbstractVecOrMat) = (view(A, :, i) for i in axes(A, 2)) +end + Base.one(::Irrational) = true function vcatmapreduce(f, args...)