On Tuesday, April 29, 2014 5:13:08 PM UTC+1, Jacob Quinn wrote: > > In my experience, I can think of a single time when having an array of a > specific abstract type was useful (how multiple Period arithmetic is > handled: > https://github.com/karbarcca/Dates.jl/blob/master/src/periods.jl#L88). > > Almost always, I'm concentrating on making sure Arrays I work with are of > a specific, concrete type to ensure performance and memory benefits. If I > really realize a few different types might make it in an Array, I usually > just go straight to a {} (Any Array) and move on. > > -Jacob > > You will get performance and memory benefits if your arrays are homogeneous as opposed to heterogeneous. You don't always know what element type they'll have though. Sometimes you want Float64 for accuracy, sometimes Float32 for speed and lower memory use. To handle that you need a static function parameter, currently.
- [julia-users] Re: Array/Cell - a useful distinction, o... Ivar Nesje
- [julia-users] Re: Array/Cell - a useful distincti... Oliver Woodford
- Re: [julia-users] Re: Array/Cell - a useful d... John Myles White
- Re: [julia-users] Re: Array/Cell - a usef... Stefan Karpinski
- Re: [julia-users] Re: Array/Cell - a usef... Oliver Woodford
- [julia-users] Re: Array/Cell - a useful disti... Patrick O'Leary
- [julia-users] Re: Array/Cell - a useful d... Oliver Woodford
- [julia-users] Re: Array/Cell - a useful disti... Matt Bauman
- [julia-users] Re: Array/Cell - a useful d... Oliver Woodford
- Re: [julia-users] Re: Array/Cell - a ... Jacob Quinn
- Re: [julia-users] Re: Array/Cell... Oliver Woodford
- [julia-users] Array/Cell - a useful distinction, or no... Jason Merrill
- [julia-users] Re: Array/Cell - a useful distincti... Oliver Woodford
- Re: [julia-users] Array/Cell - a useful distinction, o... Stefan Karpinski
- Re: [julia-users] Array/Cell - a useful distincti... Stefan Karpinski
- Re: [julia-users] Array/Cell - a useful distincti... Milan Bouchet-Valat
- Re: [julia-users] Array/Cell - a useful distincti... Oliver Woodford
- Re: [julia-users] Array/Cell - a useful disti... Stefan Karpinski
- Re: [julia-users] Array/Cell - a useful d... Oliver Woodford
- [julia-users] Re: Array/Cell - a useful distinction, o... Oliver Woodford
- Re: [julia-users] Re: Array/Cell - a useful disti... Stefan Karpinski