From de74d2c3b0005048a2c4433bde68b9be10c86f01 Mon Sep 17 00:00:00 2001 From: Takashi Kokubun Date: Sun, 1 Dec 2019 17:32:50 -0800 Subject: [PATCH] Simplify variable declaration by C99 --- mjit.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/mjit.c b/mjit.c index 93845cdb04..d8e431a81c 100644 --- a/mjit.c +++ b/mjit.c @@ -768,14 +768,12 @@ mjit_init(const struct mjit_options *opts) cc_added_args = split_flags(opts->debug_flags); xfree(opts->debug_flags); #if MJIT_CFLAGS_PIPE - { // eliminate a flag incompatible with `-pipe` - size_t i, j; - for (i = 0, j = 0; i < sizeof(CC_COMMON_ARGS) / sizeof(char *); i++) { - if (CC_COMMON_ARGS[i] && strncmp("-save-temps", CC_COMMON_ARGS[i], strlen("-save-temps")) == 0) - continue; // skip -save-temps flag - cc_common_args[j] = CC_COMMON_ARGS[i]; - j++; - } + // eliminate a flag incompatible with `-pipe` + for (size_t i = 0, j = 0; i < sizeof(CC_COMMON_ARGS) / sizeof(char *); i++) { + if (CC_COMMON_ARGS[i] && strncmp("-save-temps", CC_COMMON_ARGS[i], strlen("-save-temps")) == 0) + continue; // skip -save-temps flag + cc_common_args[j] = CC_COMMON_ARGS[i]; + j++; } #endif