in reply to Re: C vs perl
in thread C vs perl
What I don't agree with is using realloc instead of scanning the string twice, as realloc will have to copy the string over to a new location if it fails to allocate a larger size of contiguous memory at the same location. I might be wrong and it might even be implementations dependant (what malloc library guarantees giving you the same location if you realloc to a larger size?).
Hope this helps...
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Re: Re: C vs perl
by samtregar (Abbot) on Apr 28, 2002 at 19:04 UTC | |
by abstracts (Hermit) on Apr 29, 2002 at 02:09 UTC | |
by samtregar (Abbot) on Apr 29, 2002 at 03:22 UTC |