vm.c: clear intermediate hash

* vm.c (rb_f_local_variables): clear intermediate hash after
  extracting its keys.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45853 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
vm_eval.c: valid name IDs only

* vm.c (vm_collect_local_variables_in_heap): use struct local_var_list
  instead of VALUE directly.

* vm_eval.c (local_var_list_update): add valid name IDs only.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45854 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
vm_eval.c: symbol identity

* vm_eval.c (local_var_list_add): use symbol identity, and get rid
  of method calls.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45855 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
hash.c: make rb_hash_keys extern

* hash.c (rb_hash_keys): make an internal public function.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45856 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
vm_eval.c: hide intermediate hash

* vm_eval.c (rb_f_local_variables): hide intermediate hash and use
  rb_hash_keys() directly.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45857 b2dd03c8-39d4-4d8f-98ff-823fe69b080e