did you look at the test harness src/cmd/re/testmatch.c?
On Fri, 27 Jul 2012 13:58:02 +0200 Dan Shelton wrote:
> I'm trying to implement the following code in ANSI C:
> ksh -c 's="val1=hello val2=foobar" ;
> nop="${s//~(E)(val1=[[:alnum:]]+)|(val2=[[:alnum:]]+)/NOP}" ; printf
> "val1 is ${.sh.match[1][*]}, val2 is ${.sh.match[2][*]}'
> I've tried to get strgrpmatch() working but the only thing I got were
> core dumps.
> Does anyone have a good, simple example for strgrpmatch()? Please just
> a simple example with main(), string in, matches out; the ones I found
> in ast-open are all very complex and thus very hard to grok.
> _______________________________________________
> ast-developers mailing list
> [email protected]
> https://mailman.research.att.com/mailman/listinfo/ast-developers
_______________________________________________
ast-users mailing list
[email protected]
https://mailman.research.att.com/mailman/listinfo/ast-users