From f2170066e86bb9c6c15673995ee4a0f8ef08870b Mon Sep 17 00:00:00 2001 From: Tom Kwong Date: Thu, 22 Feb 2018 00:09:51 -0800 Subject: [PATCH] Fixed arg type for getindex --- src/ObjectPool.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ObjectPool.jl b/src/ObjectPool.jl index d293c19..91b9e94 100644 --- a/src/ObjectPool.jl +++ b/src/ObjectPool.jl @@ -62,7 +62,7 @@ end # Base.IndexStyle(::Type{<:ObjectPool}) = IndexLinear() # single indexing -Base.getindex(op::ObjectPool, i::Number) = op.pool[op.idx[convert(Int, i)]] +Base.getindex(op::ObjectPool, i::Integer) = op.pool[op.idx[convert(Int, i)]] # general sizes Base.size(op::ObjectPool) = (op.itemscount, )