Prevent '&nbsp' from stripping as whitespace

Fix #1727.