String processing - regex
Vlad Dumitrescu XX (LN/EAB)
vlad.xx.dumitrescu@REDACTED
Fri Jun 10 14:35:14 CEST 2005
Hi,
-----Original Message-----
From: Casper
>Also I tried with Cellicium's gregexp module.
Regexps wil only work if you can't have any of (),: in your args. Since I guess some of the args may be strings, it's not a realistic requirement.
You have to use a parser, either as Corrado suggested, or if the content is Erlang code by using erl_scan and erl_parse.
Since the code might also contain <> delimiters, you also have to extract it properly from the environment. This requires another parser :-) but a relatively simple one (just to recognize delimiters embedded in strings, character literals and escaped).
regards,
Vlad
More information about the erlang-questions
mailing list