6 ms·
You're assuming a context free grammar, this is a context sensitive grammar. Much like <b>being bold <i> being both </b> being italic </i> is a malformed CFG b
by thrown_22 4y ago
You're assuming a context free grammar, this is a context sensitive grammar.
Much like <b>being bold <i> being both </b> being italic </i> is a malformed CFG but a perfectly valid CSG.
Ironically it's the one advantage XML type notation has over Lisp type notation when it comes to expressiveness. It's rather unfortunate that, essentially, all XML tools assume proper nesting.