Fix namespaced keyword conversion, add test and benchmark.
Merge branch 'support-key-conversion-in-generate'