On Monday, March 16, 2015 at 12:13:42 AM UTC+10, Christoph Ortner wrote:
>
> I've started to work mostly with Julia 0.4 recently since has a lot of 
> useful tools for me. I noticed the following error message:
>
> "indexing with non Integer Reals is deprecated"
>
> I guess this is due to Issue 
> https://github.com/JuliaLang/julia/issues/10154. I may well be missing a 
> crucial point here, but I think it is a huge mistake to take this step and 
> it is taking Julia in the wrong direction. It feels to be something along 
> the lines of "premature optimisation". For casual scripting, or just quick 
> testing, teaching numerical computing to beginners, converting from Matlab, 
> and probably for many other reasons, not having to worry about types is 
> really important.
>
>
The problem is that its fairly easy to be casually wrong when using reals 
as indexes.  What does 10. index? (Hint: floating point numbers can't 
represent 10 exactly, its 9.999999...) 

Do we round? truncate? how far is the real allowed to be away from an 
integer to "convert cleanly"?

Its setting people up with more ways of getting errors, and it will be 
harder for inexperienced programmers to debug those problems.  

Cheers
Lex
 

> More generally, it is important to keep the option of very simple 
> (Matlab-style) Julia. I wonder whether users could come up with other 
> examples where "simplicity, convenience" are sacrificed for "performance, 
> elegance of design, etc" ? 
>
> Christoph
>
>
>

Reply via email to