diff options
| author | Junio C Hamano <gitster@pobox.com> | 2025-04-15 13:50:16 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2025-04-15 13:50:17 -0700 |
| commit | 7b03646f85b6eb4c0f6e05ed4b235577d3969532 (patch) | |
| tree | c3daadeb7eeaf85c3dbd10b85d776f93347ce969 /compat/regex/regex_internal.c | |
| parent | a8c207797f2fe624c4959487e3508dde96f68976 (diff) | |
| parent | abd4192b07c5a7dbb4b13a532d0643982b42526f (diff) | |
Merge branch 'js/comma-semicolon-confusion'
Code clean-up.
* js/comma-semicolon-confusion:
detect-compiler: detect clang even if it found CUDA
clang: warn when the comma operator is used
compat/regex: explicitly mark intentional use of the comma operator
wildmatch: avoid using of the comma operator
diff-delta: avoid using the comma operator
xdiff: avoid using the comma operator unnecessarily
clar: avoid using the comma operator unnecessarily
kwset: avoid using the comma operator unnecessarily
rebase: avoid using the comma operator unnecessarily
remote-curl: avoid using the comma operator unnecessarily
Diffstat (limited to 'compat/regex/regex_internal.c')
| -rw-r--r-- | compat/regex/regex_internal.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/compat/regex/regex_internal.c b/compat/regex/regex_internal.c index ec5cc5d2dd..4a4f849629 100644 --- a/compat/regex/regex_internal.c +++ b/compat/regex/regex_internal.c @@ -1232,7 +1232,10 @@ re_node_set_merge (re_node_set *dest, const re_node_set *src) is = src->nelem - 1, id = dest->nelem - 1; is >= 0 && id >= 0; ) { if (dest->elems[id] == src->elems[is]) - is--, id--; + { + is--; + id--; + } else if (dest->elems[id] < src->elems[is]) dest->elems[--sbase] = src->elems[is--]; else /* if (dest->elems[id] > src->elems[is]) */ |
