cases: prevent a bunch of unnecessary allocations

- processing options no longer allocates (res escaped)
- special-cased lower casing without final sigma
- use InheritanceMatcher. This is both more accurate for
   this purpose and it prevents an allocation or two

As a result, using upper casing or lower casing without
final sigma is now completely alloc free. Both of these
cases are also reentrant.

Change-Id: Ic6d5d0d2dd48ce20069ab897d76dd7d3ea0488a7
Reviewed-on: https://go-review.googlesource.com/30275
Run-TryBot: Marcel van Lohuizen <mpvl@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Nigel Tao <nigeltao@golang.org>
3 files changed