]> granicus.if.org Git - onig/commitdiff
refactoring
authorK.Kosako <kosako@sofnec.co.jp>
Tue, 6 Feb 2018 08:25:43 +0000 (17:25 +0900)
committerK.Kosako <kosako@sofnec.co.jp>
Tue, 6 Feb 2018 08:25:43 +0000 (17:25 +0900)
src/regexec.c

index 149cf9d3723b57fea4619256509c31cd5f52d2ce..1231df9cd373b4845b866f2697e0d02f4dc5df41 100644 (file)
@@ -819,10 +819,10 @@ onig_region_copy(OnigRegion* to, OnigRegion* from)
   result = (func)((OnigCalloutArgs* )&args, user);\
 } while (0)
 
-#define RETRACTION_CALLOUT_CODE(func, dir, sid, cstart, cend, user) do {\
+#define RETRACTION_CALLOUT_CODE(func, sid, cstart, cend, user) do {\
   int result;\
   CalloutArgs args;\
-  CALLOUT_CODE_BODY(func, dir, sid, cstart, cend, user, args, result);\
+  CALLOUT_CODE_BODY(func, ONIG_CALLOUT_DIRECTION_RETRACTION, sid, cstart, cend, user, args, result);\
   switch (result) {\
   case ONIG_CALLOUT_FAIL:\
     goto fail;\
@@ -1472,7 +1472,7 @@ stack_double(int is_alloca, char** arg_alloc_base,
           mem_end_stk[stk->zid]   = stk->u.mem.end;\
         }\
         else if (stk->type == STK_CALLOUT_CODE) {\
-          RETRACTION_CALLOUT_CODE(msa->mp->retraction_callout_by_code, ONIG_CALLOUT_DIRECTION_RETRACTION, stk->zid, stk->u.callout_code.content, stk->u.callout_code.content_end, msa->mp->callout_user_data);\
+          RETRACTION_CALLOUT_CODE(msa->mp->retraction_callout_by_code, stk->zid, stk->u.callout_code.content, stk->u.callout_code.content_end, msa->mp->callout_user_data);\
         }\
       }\
     }\