in reply to Re: Metacharacters in regex expression
in thread Metacharacters in regex expression
my $func_def = "char *strcmp(const char *s1, const char *s2)"; foreach my $i ('char *','const char.*','*') { if ( index( $func_def, $i ) >= 0 ) { print "'$func_def' contains '$i'\n"; } }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Metacharacters in regex expression
by BrowserUk (Patriarch) on Sep 16, 2004 at 10:17 UTC |