Menu

#105 postchunk gives misformatted output if space at end of chunk

open
nobody
transfer (5)
2016-06-09
2016-06-09
No

say a transfer rule outputs
^Imp<SV><@+FAUXV>{^ij<vblex><neg><imp><p2><sg>$} $
(due to <chunk>...<b/></chunk> which the DTD allows)
then postchunk gives

$ echo '^Imp<SV><@+FAUXV>{^ij<vblex><neg><imp><p2><sg>$} $ ^adv<ADV><@←ADVL>{^olkese<adv>$}$'|apertium-postchunk apertium-sme-sma.sme-sma.t5x sme-sma.t5x.bin                                 
^Ij<vblex><neg><imp><p2><sg>$} $ ^adv<ADV><@←ADVL>{^olkese<adv>$

and hfst-proc crashes on that.

The DTD should disallow it, or interchunk should fix it behind the scenes, or postchunk should output correctly even if the input is weird.

Discussion


Log in to post a comment.