Actions
Bug #8522
closedr41264 causes "implicit conversion loses integer precision" on clang
Description
=begin
compiling ../trunk/bignum.c
../trunk/bignum.c:1128:46: error: implicit conversion loses integer precision:
'unsigned long' to 'int' [-Werror,-Wshorten-64-to-32]
*nlp_bits_ret = num_bdigits * BITSPERDIG - num_bits;
~ ~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~
1 error generated.
make: *** [bignum.o] Error 1
=end
Files
Updated by drbrain (Eric Hodel) over 11 years ago
- File bignum.c.bug8522.patch bignum.c.bug8522.patch added
This patch changes int nlp_bits to size_t nlp_bits, but I don't know enough about bignum.c to know if this is appropriate.
Updated by akr (Akira Tanaka) over 11 years ago
- Status changed from Assigned to Closed
- % Done changed from 0 to 100
This issue was solved with changeset r41267.
Eric, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.
- bignum.c (integer_unpack_num_bdigits_small): Fix a comple error on
clang -Werror,-Wshorten-64-to-32
Reported by Eric Hodel. [ruby-core:55467] [Bug #8522]
Actions
Like0
Like0Like0