     @class_lookup type
     @set_obj type, obj
   init_string: (str,intern=false) ->
-    # this is a bit of a kludge: if the string we want to intern is __proto__ or a function name,
-    # we fail to intern it.
-    return @string_pool[str] if intern and @string_pool[str]?.type?.toClassString?() is 'java/lang/String'
+    return @string_pool[str] if intern and @string_pool[str]?
     carr = @init_carr str
     jvm_str = new JavaObject c2t('java/lang/String'), @, {'value':carr, 'count':str.length}
     @string_pool[str] = jvm_str if intern

  # 5.5 of the SE7 spec.
  class_lookup: (type, dyn) ->
    UNSAFE? || throw new Error "class_lookup needs a type object, got #{typeof type}: #{type}" unless type instanceof types.Type
    return '<primitive>' if type instanceof types.PrimitiveType
    class_file = @load_class type, dyn
    cls = type.toClassString?() ? type.toString()
    unless @class_states[type].fields?
      trace "initializing class: #{cls}"
      @class_states[type].fields = Object.create null
      if type instanceof types.ArrayType
        component = type.component_type

        delete c.$in_progress
        class_file.methods['<clinit>()V']?.run(this)
    class_file

  # called by user-defined classloaders
  define_class: (cls, data, loader) ->
    # replicates some logic from class_lookup
    class_file = new ClassFile(data)
