One edge case that arises is indexing with a float where epsilon > 1:

julia> (1:10^17)[1e16:(1e16+5)] #Not the same as indexing with (10^16:10^16+5)
5-element Array{Int64,1}:
 10000000000000000
 10000000000000000
 10000000000000002
 10000000000000004
 10000000000000004

Thanks,

Jiahao Chen
Staff Research Scientist
MIT Computer Science and Artificial Intelligence Laboratory


On Sun, Mar 15, 2015 at 9:47 AM, Stefan Karpinski <[email protected]> wrote:
> I have to confess that I find it overly finicky to require indices to be of
> integer type. Reals that convert cleanly to Int generally seem reasonable to
> me.
>
> On Sun, Mar 15, 2015 at 10:14 AM, Christoph Ortner
> <[email protected]> wrote:
>>
>> Here is, right away, one other  example that has annoyed me for a long
>> time: `meshgrid`. It may not be "Julian", but it is incredibly convenient
>> for quick experiments. I know I can get it from examples, but I don't
>> understand why it hurts having it in Base.
>>
>> Christoph
>>
>

Reply via email to