natFirstThread.cc (run): Renamed from `run0'.
* java/lang/natFirstThread.cc (run): Renamed from `run0'. Removed dead code. * java/lang/FirstThread.java (run0): Renamed to `run'. (run): Removed. From-SVN: r29626
This commit is contained in:
parent
9b0cb28706
commit
f08113ce11
3 changed files with 7 additions and 20 deletions
|
@ -19,16 +19,7 @@ package java.lang;
|
|||
|
||||
final class FirstThread extends Thread
|
||||
{
|
||||
public native void run0 ();
|
||||
public void run ()
|
||||
{
|
||||
try {
|
||||
run0 ();
|
||||
} catch (Throwable ex) {
|
||||
System.err.println ("uncaught exception at top level");
|
||||
ex.printStackTrace ();
|
||||
}
|
||||
}
|
||||
public native void run ();
|
||||
|
||||
public FirstThread (ThreadGroup g, Class k, Object o)
|
||||
{
|
||||
|
|
|
@ -27,20 +27,11 @@ details. */
|
|||
typedef void main_func (jobject);
|
||||
|
||||
void
|
||||
java::lang::FirstThread::run0 (void)
|
||||
java::lang::FirstThread::run (void)
|
||||
{
|
||||
Utf8Const* main_signature = _Jv_makeUtf8Const ("([Ljava.lang.String;)V", 22);
|
||||
Utf8Const* main_name = _Jv_makeUtf8Const ("main", 4);
|
||||
|
||||
#if 0
|
||||
// Note: this turns out to be more painful than useful. Apparently
|
||||
// many people rely on being able to have main in a non-public
|
||||
// class.
|
||||
// This is based on my reading of 12.3.3.
|
||||
if (! java::lang::reflect::Modifier::isPublic(klass->getModifiers()))
|
||||
DIE ("class must be public");
|
||||
#endif
|
||||
|
||||
if (klass == NULL)
|
||||
{
|
||||
klass = java::lang::Class::forName (klass_name);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue