f



regular expression compilation aborted

Hi folks,

I have the problem regarding the compilation of the regular expression.

I have given the regular expression as follows:

"(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ([ 0-9][0-9])
([0-9][0-9])(.*)"

and regcomp() function call gets aborted ( i think it is because of the
increased memory consumption at the time of regular expression
compilation ).
What is the reason behind this ?

Please put some light on the problem,

Thanks in advance,
torpedo

0
torpedo (6)
5/10/2005 8:24:32 AM
comp.unix.programmer 10848 articles. 0 followers. kokososo56 (350) is leader. Post Follow

2 Replies
457 Views

Similar Articles

[PageSpeed] 18

torpedo@bluebottle.com writes:

> Hi folks,
>
> I have the problem regarding the compilation of the regular expression.
>
> I have given the regular expression as follows:
>
> "(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ([ 0-9][0-9])
> ([0-9][0-9])(.*)"
>
> and regcomp() function call gets aborted ( i think it is because of the
> increased memory consumption at the time of regular expression
> compilation ).
> What is the reason behind this ?

I don't observe undue memory consumption.  This regexp is one of the simpliest.

[1]> (room)

Bytes permanently allocated:       90432
Bytes currently in use:          3061472
Bytes available until next GC:   1500436
3061472 ;
1500436
[2]> (regexp:regexp-compile "(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ([ 0-9][0-9]) ([0-9][0-9])(.*)" :extended t)
#<FOREIGN-POINTER #x081F5290>
[3]> (regexp:regexp-exec * "Aug 12 1932")
#S(REGEXP:MATCH :START 0 :END 11) ;
#S(REGEXP:MATCH :START 0 :END 3) ;
#S(REGEXP:MATCH :START 4 :END 6) ;
#S(REGEXP:MATCH :START 7 :END 9) ;
#S(REGEXP:MATCH :START 9 :END 11)
[4]> (room)

Bytes permanently allocated:       90432
Bytes currently in use:          3106560
Bytes available until next GC:   1455348
3106560 ;
1455348
[5]> 

-- 
__Pascal Bourguignon__                     http://www.informatimago.com/
Wanna go outside.
Oh, no! Help! I got outside!
Let me back inside!
0
Pascal
5/10/2005 10:16:28 AM
Ooops ...

Sorry, the problems was lying somewhere else!
I was doing some illigal memory reference.

Thank you very much.

torpedo

0
torpedo
5/12/2005 7:05:19 AM
Reply: