Better generation schemes.

This is modelled strongly after Python's.
Switch to the new scheme. This takes the tables from 2.6MB to 530KB.

(About 40KB smaller than Python, too.)