To summarize: WebKit uses some Perl scripts (Perl seemed well suited to this task, btw) to compile a custom header file format, with help from C++ templates into code which converts the C++ datamodel into JavaScriptCore objects and back. To handle the prototype properties/methods, it constructs the hashmaps JavascriptCore indexes into at compile time.
I was a bit distracted getting through that, with more important work.