Clean up and optimize want handling.

Avoids a couple of hash lookups, repeated num to string coercions, and
so forth.