summaryrefslogtreecommitdiff
path: root/libjava/resolve.cc
diff options
context:
space:
mode:
authortromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4>2002-09-25 20:57:03 +0000
committertromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4>2002-09-25 20:57:03 +0000
commit31c8980314b50044a5bfb3aaed06d9541a951ace (patch)
tree43e82772814712c2a3228d0a73999e5b18cc3b7f /libjava/resolve.cc
parent7151fd9e91afc42e713dbb97c32f95cc7aebc050 (diff)
downloadgcc-31c8980314b50044a5bfb3aaed06d9541a951ace.tar.gz
* java/lang/natClassLoader.cc:
(_Jv_PrepareCompiledClass): Throw NoClassDefFoundError, per spec. * resolve.cc: Include NoClassDefFoundError.h, not ClassNotFoundException.h. (_Jv_ResolvePoolEntry): Throw NoClassDefFoundError, per spec. * defineclass.cc: Don't include ClassNotFoundException.h. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@57516 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/resolve.cc')
-rw-r--r--libjava/resolve.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/libjava/resolve.cc b/libjava/resolve.cc
index 90df67b8ab9..af1f7c60c1a 100644
--- a/libjava/resolve.cc
+++ b/libjava/resolve.cc
@@ -29,7 +29,7 @@ details. */
#include <java/lang/ClassFormatError.h>
#include <java/lang/IllegalAccessError.h>
#include <java/lang/AbstractMethodError.h>
-#include <java/lang/ClassNotFoundException.h>
+#include <java/lang/NoClassDefFoundError.h>
#include <java/lang/IncompatibleClassChangeError.h>
#include <java/lang/reflect/Modifier.h>
@@ -98,7 +98,8 @@ _Jv_ResolvePoolEntry (jclass klass, int index)
if (! found)
{
jstring str = _Jv_NewStringUTF (name->data);
- throw new java::lang::ClassNotFoundException (str);
+ // This exception is specified in JLS 2nd Ed, section 5.1.
+ throw new java::lang::NoClassDefFoundError (str);
}
if ((found->accflags & Modifier::PUBLIC) == Modifier::PUBLIC