I'm not sure why the result of leading_zeros should be of the same type as the argument. What's the use case?
On Thu, Apr 30, 2015 at 11:23 AM, Sebastian Good < sebast...@palladiumconsulting.com> wrote: > Recent 0.4 changes made expressions like Int32(1) + Int32(2) type stable, > i.e returning Int32 instead of Int64 as they did previously (on a 64-bit > system, anyway). However leading_zeros seems to always return an Int64. I > wonder if it makes sense to convert the result of leading_zeros to the > same type as its argument, at least for the base Integer bittypes? > > FWIW, this came up while updating StreamStats.jl for v0.4, where a few > functions had to take care to convert intermediate results back to Int32. >