Skip to content

Commit

Permalink
The new regexp compilation function must be added to the engine struc…
Browse files Browse the repository at this point in the history
…ture.

p4raw-id: //depot/perl@29458
  • Loading branch information
rgs committed Dec 4, 2006
1 parent 2a5d9b1 commit 3c6f95d
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ext/re/re.xs
Expand Up @@ -12,6 +12,7 @@
START_EXTERN_C

extern regexp* my_regcomp (pTHX_ char* exp, char* xend, PMOP* pm);
extern regexp* my_re_compile(pTHX_ char *exp, char *xend, PMOP *pm);
extern I32 my_regexec (pTHX_ regexp* prog, char* stringarg, char* strend,
char* strbeg, I32 minend, SV* screamer,
void* data, U32 flags);
Expand All @@ -32,6 +33,7 @@ END_EXTERN_C

const struct regexp_engine my_reg_engine = {
my_regcomp,
my_re_compile,
my_regexec,
my_re_intuit_start,
my_re_intuit_string,
Expand Down
1 change: 1 addition & 0 deletions ext/re/re_top.h
Expand Up @@ -13,6 +13,7 @@
#define Perl_regprop my_regprop
#define Perl_re_intuit_start my_re_intuit_start
#define Perl_pregcomp my_regcomp
#define Perl_re_compile my_re_compile
#define Perl_regfree_internal my_regfree
#define Perl_re_intuit_string my_re_intuit_string
#define Perl_regdupe_internal my_regdupe
Expand Down
1 change: 1 addition & 0 deletions regcomp.h
Expand Up @@ -405,6 +405,7 @@ EXTCONST regexp_engine PL_core_reg_engine;
#else /* DOINIT */
EXTCONST regexp_engine PL_core_reg_engine = {
Perl_pregcomp,
Perl_re_compile,
Perl_regexec_flags,
Perl_re_intuit_start,
Perl_re_intuit_string,
Expand Down
1 change: 1 addition & 0 deletions regexp.h
Expand Up @@ -110,6 +110,7 @@ typedef struct re_scream_pos_data_s

typedef struct regexp_engine {
regexp* (*comp) (pTHX_ char* exp, char* xend, PMOP* pm);
regexp* (*compile) (pTHX_ char *exp, char *xend, PMOP *pm);
I32 (*exec) (pTHX_ regexp* prog, char* stringarg, char* strend,
char* strbeg, I32 minend, SV* screamer,
void* data, U32 flags);
Expand Down

0 comments on commit 3c6f95d

Please sign in to comment.