Statically generate lookup tables using Template Haskell.