I've seen Julia's non-checking of integer overflows questioned (and I know the answer/performance section (and BigInt alternative, that is just slow/overkill), and recall a discussion in the forums).
Just now I noticed: https://github.com/JuliaLang/julia/issues/855 [for 1.0 milestone - after the 0.5 (and 0.4) milestone..] while still unread (seemed to be about LLVM, that I will not touch), previously, to me, there seemed to be a simple solution - a new checked integer type. [I just noticed in another thread a modN (integer) type, that is a generalization, I guess I should look into it but anyway a checked type (the opposite, non-mod..) seems trivial.] Assuming I had this type, that I guess I could manage to program all literals will still be the old type, but you could do something like c"1" (that is not optimal..). What was asked for was a default option for checked overflows that could be disabled by a command line switch. I wander it that is just not needed and a global macro (similar to @everywhere) could just change all literals, like c"1" -> 1? I still haven't done any macro programming and this could be my first try (if one of the macro-gods doesn't beat me to it.. or already has). Are there any forseen problems to this solution (other than where mod behavior is really wanted..)? Would ones() and zeros() still work? Would a macro not work as it would only work at one file at a time and would need to be recursive to your whole project (and standard library)? Still a good start? -- Palli.
