diff options
author | Jörg Frings-Fürst <debian@jff.email> | 2021-04-26 22:25:42 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff.email> | 2021-04-26 22:25:42 +0200 |
commit | 5d5f76cad47d13dc0dd4328c2172ddc1d4b19d7b (patch) | |
tree | cd59a8ea003d6768af284fc913353983e2794a58 /test/test_back.c | |
parent | eac65ba44805c402f894b700b602c2e891f92a84 (diff) | |
parent | 96b0c9871630512ec2c2e84072da0085d68d740f (diff) |
Merge branch 'release/debian/6.9.7.1-1'debian/6.9.7.1-1
Diffstat (limited to 'test/test_back.c')
-rw-r--r-- | test/test_back.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/test/test_back.c b/test/test_back.c index 6bf5159..9a6e4a8 100644 --- a/test/test_back.c +++ b/test/test_back.c @@ -1,8 +1,7 @@ /* * test_back.c - * Copyright (c) 2020 K.Kosako + * Copyright (c) 2020-2021 K.Kosako */ -#include "config.h" #ifdef ONIG_ESCAPE_UCHAR_COLLISION #undef ONIG_ESCAPE_UCHAR_COLLISION #endif @@ -141,7 +140,7 @@ static void xe(char* pattern, char* str, int error_no, int line_no) #define x2(p,s,f,t) xx2(p,s,f,t, __LINE__) #define x3(p,s,f,t,m) xx3(p,s,f,t,m, __LINE__) #define n(p,s) xn(p,s, __LINE__) -#define e(p,s,e) xe(p,s,e, __LINE__) +#define e(p,s,en) xe(p,s,en, __LINE__) extern int main(int argc, char* argv[]) { @@ -1331,10 +1330,10 @@ extern int main(int argc, char* argv[]) x2("(?<!v|^t|^a+.*[efg])z", "uabcdfz", 6, 7); x2("((?(a)\\g<1>|b))", "aab", 2, 3); - x2("((?(a)\\g<1>))", "aab", 1, 2); + x2("((?(a)\\g<1>))", "aab", 3, 3); x2("(b(?(a)|\\g<1>))", "bba", 1, 3); e("(()(?(2)\\g<1>))", "", ONIGERR_NEVER_ENDING_RECURSION); - x2("(?(a)(?:b|c))", "ac", 0, 2); + x2("(?(a)(?:b|c))", "ac", 2, 2); n("^(?(a)b|c)", "ac"); x2("(?i)a|b", "B", 0, 1); n("((?i)a|b.)|c", "C"); |