зеркало из https://github.com/github/ruby.git
enum.c: fix declaration-after-statement
* enum.c (sum_iter): workaround of mixed declarations and code. erred by -Werror=declaration-after-statement option. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55043 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
5d0bf9ae15
Коммит
abe32a00b1
3
enum.c
3
enum.c
|
@ -3574,7 +3574,7 @@ struct enum_sum_memo {
|
||||||
static void
|
static void
|
||||||
sum_iter(VALUE i, struct enum_sum_memo *memo)
|
sum_iter(VALUE i, struct enum_sum_memo *memo)
|
||||||
{
|
{
|
||||||
assert(memo != NULL);
|
const int unused = (assert(memo != NULL), 0);
|
||||||
|
|
||||||
long n = memo->n;
|
long n = memo->n;
|
||||||
VALUE v = memo->v;
|
VALUE v = memo->v;
|
||||||
|
@ -3663,6 +3663,7 @@ sum_iter(VALUE i, struct enum_sum_memo *memo)
|
||||||
memo->r = r;
|
memo->r = r;
|
||||||
memo->f = f;
|
memo->f = f;
|
||||||
memo->c = c;
|
memo->c = c;
|
||||||
|
(void)unused;
|
||||||
}
|
}
|
||||||
|
|
||||||
static VALUE
|
static VALUE
|
||||||
|
|
Загрузка…
Ссылка в новой задаче