[Israel.pm] Regex that matches a C-style function definition.

Meron Cohen Meron.Cohen at ecitele.com
Sun Nov 11 04:17:01 PST 2007


Hello,
 
I'm trying to parse ".c" file and extract a given function's definition.
 
Example:
 
void f ()
{
    /* definition of f () */
}
 
I know that the name of the function is "f" and what I want is the
definition of f (), inside the "{" and "}".
Could you tell me if there is a CPAN module that already does it, or
give me a Regex that does it.
 
10x,
Meron



More information about the Perl mailing list