Fix indexing hashes with string literals

Tried to be too clever, but only shifted creation of Brat string
from generated code to core code.