Skip to content

Commit 2f729fe

Browse files
authored
move GenericMemory-related definitions to the main file (JuliaArrays#86)
They're not `FixedSizeArray`-specific, might be useful for `FixedSizeBitArray`.
1 parent f63721e commit 2f729fe

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/FixedSizeArray.jl

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,6 @@ end
2828
const FixedSizeVector{T} = FixedSizeArray{T,1}
2929
const FixedSizeMatrix{T} = FixedSizeArray{T,2}
3030

31-
const default_underlying_storage_type = (@isdefined Memory) ? Memory : Vector
32-
33-
const optional_memory = (@isdefined Memory) ? (Memory,) : ()
34-
const optional_atomic_memory = (@isdefined AtomicMemory) ? (AtomicMemory,) : ()
35-
const optional_generic_memory = (@isdefined GenericMemory) ? (GenericMemory,) : ()
36-
3731
function FixedSizeArray{T,N,V}(::UndefInitializer, size::NTuple{N,Int}) where {T,N,V}
3832
FixedSizeArray{T,N,V}(Internal(), V(undef, checked_dims(size))::V, size)
3933
end

src/FixedSizeArrays.jl

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
module FixedSizeArrays
22

3+
const default_underlying_storage_type = (@isdefined Memory) ? Memory : Vector
4+
5+
const optional_memory = (@isdefined Memory) ? (Memory,) : ()
6+
const optional_atomic_memory = (@isdefined AtomicMemory) ? (AtomicMemory,) : ()
7+
const optional_generic_memory = (@isdefined GenericMemory) ? (GenericMemory,) : ()
8+
39
include("FixedSizeArray.jl")
410

511
if isdefined(Base, :dataids) && (Base.dataids isa Function)

0 commit comments

Comments
 (0)