In addition to the points raised by others, this would fail to account for character references in the markup.
The quick & the deadOr greater than characters in attribute values
<p title="x > y">In reply to Re: HTML to text
by dorward
in thread HTML to text
by fatalserpent
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |