Use typename in place of class.

Template argument style thing. I like typename.
Add stop_at_invalid template argument to next_code.

If true, which it is by default, the function won't advance past
invalid octets.

This also fixes an issue where octets were only skipped if they weren't
intermediate octets. Basically, the things that needed to be skipped
weren't skipped, and those that shouldn't be skipped were.

find_invalid moved beneath next_code to avoid needing function
definitions.
Add a bunch of things to utf8.hh

- Add put_code that takes an rvalue-ref for the iterator to allow
  temporaries.
- Add advance and distance functions.
- Add iterator<T> (where T is an underlying iterator type). This is
  just a read-only codepoint iterator.
- Add unsafe namespace to provide equivalent unbounded functions/an
  iterator. The only major difference between these and the normal
  utf8:: functions is that these do not take an end iterator for bounds
  checking, hence the 'unsafe'. They cost less in terms of storage and
  may be faster, but overall I'd say the "safe" variants are better.
Fix namespace typo in comment.