On Fri, Jun 19, 2009 at 9:06 AM, Yue Wang <yuleopen@gmail.com> wrote:
On Fri, Jun 19, 2009 at 2:29 PM, luigi scarso<luigi.scarso@gmail.com> wrote:
>>
>> Anyway, I highly respect the ConTeXt and LuaTeX's work.
>> But if Taco and Hans can :
>>
>> - use a proper regexp library (like lrexlib?), not the silly lpeg
>
> PEG are not silly at all. PEG *include* regex, but not viceversa,
> and it seems to have the same power of  CFG, so you can build a parser for
> pratically anything
> (and you can not do this with regex) .
> Perhaps the reverse sentence has more sense: drop the "silly" (?) regex, use
> the new peg.
> For what I know the reverse side of lpeg is that a file must be loaded in
> memory completly.

Well, I don't like to know what kind of thing is superior ... micro
kernel is superior than monolithic kernel, but...
Wrong paragon .
From *mathematical*  point  of  view, the set of all regular languages
are a subset of PEG languages .
PEG are more powerful than  regex --it's not an opinion, it's a fact.


The key reason for this is, more people are familiar with regexp. so
if you can build a 100% compatible regexp module on top of lpeg in
ConTeXt, it will be ok, or even better...
We already have lua for simple string manipulation, and lpeg for other stuffs .
Again we don't need regex .


>
>> - full support of xslt:)
>
> why not xquery too? Are mkiv  supposed to be a full  xml processor ?


No. I mean the user can have an option to convert an xml (that is, a
context document) using (maybe external) xslt tool.
This won't be too difficult to implement ...
hmm, external tools call for platform /SO issue ...
Personally xsltproc in linux it's OK -- I don't need
an integration ,
I prefear separations of concerns.

 

> A bit of xslt can be done with lpeg (and not regex),

a bit == far from all
It's enough for simple xml processing .
If you need more, are you sure that you are using  the right tool ?

 

>> Things might be a lot better...
>
> and worse too .
> Things are now a lot better than before ,IMMO .
>

it should be.

It is .
--
luigi