idkwim / ouspg

Automatically exported from code.google.com/p/ouspg
3 stars 0 forks source link

radamsa doesn't get xml #85

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
The partial parser does not get XML very well. Consider adding a separate set 
of x* mutations that operate on partially parsed XML trees instead.

Original issue reported on code.google.com by aohelin on 15 May 2013 at 12:20

GoogleCodeExporter commented 9 years ago

Original comment by aohelin on 13 Jun 2013 at 7:56

GoogleCodeExporter commented 9 years ago
$ echo '<foo bar=baz> lol </p> <><><<<< </foo> <p />hai >>' | bin/radamsa -m xp 
-p od
-----------------------------8<-----------------------------
What I know so far:
 - 'foo' is a tag of type full
    + attribute 'bar', e.g. 'baz'
 - 'p' is a tag of type open-single
-----------------------------8<-----------------------------
<p /> <foo bar=baz> lol </p> <><><<<< </foo>hai >>

Original comment by aohelin on 13 Jun 2013 at 9:40

GoogleCodeExporter commented 9 years ago
Wrote a partial parser and some mutations similar to old tree mutator. Not 
finished, but you could say radamsa groks xml already.

$ echo '<foo a=A b="trololo"><bar><baz>hai</bar> <x />a</foo> <q> foo' | 
radamsa -m xp
<foo a=A b="trololo"><q><foo b="trololo">hai</foo> <x />a</foo> 
<bar><baz><q></bar> foo

Original comment by aohelin on 14 Jun 2013 at 2:56