Better comments around middleware stack caching
EnvInit middleware

Provide a standard middleware to set c.Env. Don't include it in the
default stack, however, since the RequestID middleware will end up
allocating Env anyways.

Fixes #11
Add RealIP middleware

This middleware allows you to override a http.Request's RemoteAddr with
a value derived from either the X-Forwarded-For or X-Real-IP headers.

Fixes #12.
Add route selection test

I'm about to make changes to the way routes are selected, so we may as
well get good test coverage of that.
Sort routes

Partially sort the routes on insertion. We're doing this so we can do
more efficient things to routes later.

The sorting rules are a bit subtle since we aren't allowed to rearrange
routes in a way that would cause the semantics to differ from the dumb
linear scan.
Fast bytecode router

Swap out the naive "try all the routes in order" router with a "compile
a trie down to bytecode" router. It's a ton faster, while providing all
the same semantics.

See the documentation at the top of web/fast_router.go for more.
Router benchmarks

These are based on https://github.com/cypriss/golang-mux-benchmark
Also report on allocations
Reduce allocations in string patterns
Fix routing behavior

The fast routing diff introduced a regression with how method sets were
calculated for routes that did not match. This fixes that behavior, as
well as making routing considerably more memory-efficient (and therefore
CPU-efficient too) for the case in which many routes share a prefix.
DRY up the benchmarks a bit
Also benchmark a single route, middleware
Don't worry so much about helping the GC

Let's just hope the GC does its job correctly and don't try to help it
out. This case is probably triggered very infrequently since most people
set up their middleware before they accept a single request, and it's
worth about 100ns of perf on the common case for us if we get rid of the
defer.
Only make a best-effort to release mStacks

It doesn't *actually* matter, and getting rid of the defer is worth
~80ns of perf.
Pass a *C between middleware and router

Previously, the middleware stack passed the router a C, but this was
both odd semantically (a pattern which mutated the environment might see
a *different* environment) and bad for perf: it cost us an allocation.

Now we only pass around *C's internally.

Importantly ("importantly"), this gets us down to 0 allocations for the
static routing case, and one allocation (the URLParams map) for the
normal routing case.
Rewrite perf section of README

We're fast now!
Split Pattern.Match in two; get rid of dryrun

The "dryrun" parameter on Pattern.Match was kind of ugly and made for an
exceedingly mediocre public interface. Instead, split its functionality
in two: the previous "dryrun" behavior now lives in the Match method,
and Patterns now actually mutate state when Run is called.

The code on the backend is of course still the same (for now), but at
least the interface is a little nicer.
+windows support
Merge remote-tracking branch 'upstream/master'
Merge branch 'master' of https://github.com/a-palchikov/goji