ruby-changes:49624
From: mame <ko1@a...>
Date: Tue, 9 Jan 2018 23:11:45 +0900 (JST)
Subject: [ruby-changes:49624] mame:r61740 (trunk): iseq.c: Add explicit casts from long to int (to pass compile on clang)
mame 2018-01-09 23:11:39 +0900 (Tue, 09 Jan 2018) New Revision: 61740 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=61740 Log: iseq.c: Add explicit casts from long to int (to pass compile on clang) Modified files: trunk/iseq.c Index: iseq.c =================================================================== --- iseq.c (revision 61739) +++ iseq.c (revision 61740) @@ -2840,9 +2840,9 @@ struct succ_index_table { https://github.com/ruby/ruby/blob/trunk/iseq.c#L2840 } succ_index_table; #define imm_block_rank_set(v, i, r) (v) |= (uint64_t)(r) << (7 * (i)) -#define imm_block_rank_get(v, i) (((v) & 0x7fL << (i) * 7) >> ((i) * 7)) +#define imm_block_rank_get(v, i) ((int) (((v) & 0x7fL << (i) * 7) >> ((i) * 7))) #define small_block_rank_set(v, i, r) (v) |= (uint64_t)(r) << (9 * ((i) - 1)) -#define small_block_rank_get(v, i) ((i) == 0 ? 0 : ((v) & 0x1ffL << ((i) - 1) * 9) >> (((i) - 1) * 9)) +#define small_block_rank_get(v, i) ((int) ((i) == 0 ? 0 : ((v) & 0x1ffL << ((i) - 1) * 9) >> (((i) - 1) * 9))) static struct succ_index_table * succ_index_table_create(int max_pos, int *data, int size) -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/