comparison src/share/vm/runtime/signature.cpp @ 1508:2ffde6cfe049

6939196: method handle signatures off the boot class path get linkage errors Summary: Adjust MethodType lookup logic to search off the BCP, but not to cache those results Reviewed-by: twisti
author jrose
date Sat, 01 May 2010 21:57:35 -0700
parents a61af66fc99e
children df736661d0c8
comparison
equal deleted inserted replaced
1507:cd5dbf694d45 1508:2ffde6cfe049
325 325
326 symbolOop result = oopFactory::new_symbol(_signature, begin, end, CHECK_NULL); 326 symbolOop result = oopFactory::new_symbol(_signature, begin, end, CHECK_NULL);
327 return result; 327 return result;
328 } 328 }
329 329
330 klassOop SignatureStream::as_klass(Handle class_loader, Handle protection_domain,
331 FailureMode failure_mode, TRAPS) {
332 if (!is_object()) return NULL;
333 symbolOop name = as_symbol(CHECK_NULL);
334 if (failure_mode == ReturnNull) {
335 return SystemDictionary::resolve_or_null(name, class_loader, protection_domain, THREAD);
336 } else {
337 bool throw_error = (failure_mode == NCDFError);
338 return SystemDictionary::resolve_or_fail(name, class_loader, protection_domain, throw_error, THREAD);
339 }
340 }
341
342 oop SignatureStream::as_java_mirror(Handle class_loader, Handle protection_domain,
343 FailureMode failure_mode, TRAPS) {
344 if (!is_object())
345 return Universe::java_mirror(type());
346 klassOop klass = as_klass(class_loader, protection_domain, failure_mode, CHECK_NULL);
347 if (klass == NULL) return NULL;
348 return Klass::cast(klass)->java_mirror();
349 }
330 350
331 symbolOop SignatureStream::as_symbol_or_null() { 351 symbolOop SignatureStream::as_symbol_or_null() {
332 // Create a symbol from for string _begin _end 352 // Create a symbol from for string _begin _end
333 ResourceMark rm; 353 ResourceMark rm;
334 354