[relaxng-user] Latest proposal for smart regexes in RELAX NG
David Tolpin
dvd at davidashen.net
Thu May 6 22:22:09 ICT 2004
> > > to XML) syntax for regular expressions (unix-like, adopted by W3C Schema)
> > > is the compact syntax. It is easy to write and convenient to use,
> > > and actually needs just one addition: ability to compose a regular
> > > expression from parts.
> >
> >It's neither easy to write nor convenient to use, it's just that we're all
> >so used to it.
>
> Would we expect people 'new' to regex to learn it from relax-ng?
> My guess would be that unless you knew (something) of it, you'd
> steer well clear of it, but it is useful, if inconvenient, hard etc.
> Any attempt to clarify/group the regex line noise would help IMHO.
>
As funny as it is, I think that the accepted syntax for regular
expressions is exceptionally elegant, and tools success is a proof
of it. There were (and are) other approaches for string pattern
matches, but unix/posix regexps are very good.
They do solve the problem they are designed for -- efficient expression
of string templates. XML regexps don't even come close -- all attempts
to express regexps in XML (I've seen so far) are the real line noise,
not string regexps.
The learning curve is steep, but at the top of the hill you get
a tool which is pleasant to use and fun to debug. As opposite to
XML markup.
David
More information about the relaxng-user
mailing list