summaryrefslogtreecommitdiff
path: root/vm
diff options
context:
space:
mode:
authorAndrew John Hughes <gnu_andrew@member.fsf.org>2005-05-27 00:01:42 +0000
committerAndrew John Hughes <gnu_andrew@member.fsf.org>2005-05-27 00:01:42 +0000
commit9504f4c9901366e510c2d1824a8bf6cfea4e2cc5 (patch)
tree785795c0ca76eccf103edcf3af7437e98c3c8e64 /vm
parentc521023082fc793b1236b9964f0efaffc0aec767 (diff)
downloadclasspath-9504f4c9901366e510c2d1824a8bf6cfea4e2cc5.tar.gz
2005-05-26 Andrew John Hughes <gnu_andrew@member.fsf.org>
* Merge from HEAD --> generics for 2005/05/20 - 2005/05/26. 2005-05-26 Andrew John Hughes <gnu_andrew@member.fsf.org> * gnu/java/net/protocol/http/HTTPURLConnection.java: (connect()): Reverted the removal of the exception with 404s. 2005-05-26 Andrew John Hughes <gnu_andrew@member.fsf.org> * java/net/URI.java: (getURIGroup(String)): Correctly handle the difference between null and undefined optional values. (relativize(java.net.URI)): Corrected documentation. 2005-05-26 Andrew John Hughes <gnu_andrew@member.fsf.org> * gnu/xml/transform/StreamSerializer.java: (serialize(org.w3c.dom.Node,java.io.OutputStream, boolean)): Add missing 'DOCTYPE' keyword to DocumentType node output. 2005-05-26 Andrew John Hughes <gnu_andrew@member.fsf.org> * gnu/java/net/protocol/http/HTTPURLConnection.java: (connect()): Fixed a null pointer exception with 304 responses and an inappropriate exception with 404s. * gnu/java/net/protocol/http/Request.java: (readResponse(java.io.LineInputStream)): Fixed a fruitless attempt to read the non-existant body of a 304 response. 2005-05-25 Andrew John Hughes <gnu_andrew@member.fsf.org> * examples/Makefile.am: Fix command-line options for ecj. * lib/Makefile.am: Added a META-INF directory structure to glibj.zip. * resource/META-INF/services/javax.xml.parsers.DocumentBuilderFactory, resource/META-INF/services/javax.xml.parsers.SAXParserFactory, resource/META-INF/services/javax.xml.parsers.TransformerFactory, resource/META-INF/services/org.xml.sax.driver: Properties for the XML facilities. 2005-05-25 Thomas Fitzsimmons <fitzsim@redhat.com> * java/awt/Component.java (enableInputMethods): Implement. 2005-05-25 Audrius Meskauskas <AudriusA@Bioinformatics.org> * org/omg/CORBA/TRANSIENT.java (serialVersionUID): Added 1.4 SVUID. 2005-05-25 Audrius Meskauskas <AudriusA@Bioinformatics.org> * org/omg/CORBA/ValueBaseHelper.java, org/omg/CORBA/ValueBaseHolder.java, org/omg/CORBA/portable/ValueBase.java: New files. * gnu/CORBA/gnuAny.java (insert_Value, extract_Value): Implemented methods. 2005-05-25 Thomas Fitzsimmons <fitzsim@redhat.com> * NEWS: Add entry describing GTK scrollbar peer change. * INSTALL: Bump GTK requirement to 2.6.x. 2005-05-25 Audrius Meskauskas <AudriusA@Bioinformatics.org> * org/omg/CORBA/ORB.java (create_dyn_any, create_dyn_array, create_dyn_enum, create_dyn_sequence, create_dyn_struct, create_dyn_union, create_policy): Declaring they may throw an exceptions. * org/omg/CORBA/DefinitionKind.java: Making fields final and inherit from IDLEntity, Serializable. * org/omg/CORBA/IRObject.java: Inherit from org.omg.CORBA.Object, Serializable, IDLEntity. 2005-05-25 Audrius Meskauskas <AudriusA@Bioinformatics.org> * gnu/CORBA/Connected_objects.java (cObject, getKey, add, get, entrySet, remove), * gnu/CORBA/Functional_ORB.java (portServer, getFreePort, connect, startService, destroy, disconnect, object_to_string, run, shutdown, find_connected_object, createIOR, finalize): Implemented listening on different ports for different objects. 2005-05-25 Roman Kennke <roman@kennke.org> * javax/swing/AbstractButton.java: (constructor): Removed model creation. * javax/swing/JButton.java: (constructor): Added model creation. * javax/swing/JMenuItem.java: (init): Added model creation. 2005-05-25 Roman Kennke <roman@kennke.org> * javax/swing/JLayeredPane.java (static getLayer): Add cast to force a call to the instance method getLayer(). (getLayeredPaneAbove): Added and implemented method. * javax/swing/JInternalFrame.java (getLayer): Add cast to force a call to the instance method getLayer() of JLayeredPane. 2005-05-25 Roman Kennke <roman@kennke.org> * javax/swing/plaf/basic/BasicSplitPaneUI.java (paint): Added check to make sure the split pane divider has a valid location. 2005-05-25 Michael Koch <konqueror@gmx.de> * native/jni/gtk-peer/gnu_java_awt_peer_gtk_GtkScrollBarPeer.c (connetJObject): Removed. 2005-05-25 Michael Koch <konqueror@gmx.de> * java/util/Locale.java (getISOStrings): Re-implemented for locale properties files. 2005-05-24 Thomas Fitzsimmons <fitzsim@redhat.com> * native/jni/gtk-peer/gnu_java_awt_peer_gtk_GtkScrollBarPeer.c (connectSignals): Connect to new change-value signal. (post_change_event): Remove signal handler. (slider_moved_cb): New signal handler. * configure.ac: Require gtk+-2.0 >= 2.6. 2005-05-24 Audrius Meskauskas <AudriusA@Bioinformatics.org> * org/omg/CORBA/portable/Delegate.java (equals): Compare parameters. 2005-05-24 Gary Benson <gbenson@redhat.com> * java/text/MessageFormat.java (MessageFormatElement.setLocale): Handle DateFormat.DEFAULT case correctly. 2005-05-24 Mark Wielaard <mark@klomp.org> * java/util/regex/Pattern.java (split): Assign value of variable matched outside while statement. * gnu/regexp/RE.java (getCharUnit): Assign value of unit.bk variable outside if statement. * gnu/CORBA/bufferedResponseHandler.java (createReply): Assign values from static class type constants. * gnu/CORBA/IOR.java (_write_no_endian): Likewise. * gnu/CORBA/Functional_ORB.java (respond_to_client): Likewise. (serve): Likewise. 2005-05-23 Mark Wielaard <mark@klomp.org> * lib/Makefile.am (FOUND_JIKES): Add +Pno-switchcheck. 2005-05-23 Audrius Meskauskas <AudriusA@Bioinformatics.org> * gnu/CORBA/Asynchron.java: New file. * org/omg/CORBA/ORB.java (send_multiple_requests_oneway, send_multiple_requests_deferred, poll_next_response, get_next_response, perform_work, work_pending): New methods. * gnu/CORBA/gnuRequest.java (send_deferred, send_oneway): Launch the submission process in a separate thread. * org/omg/CORBA/portable/ObjectImpl.java (hashCode): Removing redundant method. * gnu/CORBA/Functional_ORB.java (send_multiple_requests_oneway, send_multiple_requests_deferred, poll_next_response, get_next_response, perform_work, work_pending): New methods. * gnu/CORBA/Restricted_ORB.java (send_multiple_requests_oneway, send_multiple_requests_deferred, poll_next_response, get_next_response, perform_work, work_pending): New methods. 2005-05-23 Tom Tromey <tromey@redhat.com> * doc/hacking.texinfo (Source Code Style Guide): Document UTF-8 use. * lib/Makefile.am (GCJF): New variable. (JAVAC): Use it. Add -encoding option where needed. 2005-05-23 Audrius Meskauskas <AudriusA@Bioinformatics.org> * org/omg/CORBA/NameValuePair.java: Inherit from Serializable, IDLEntity. * org/omg/CORBA/SetOverrideType.java (constuctor): Making protected. * org/omg/CORBA/DynFixed.java (set_value): Declare it may throw an InvalidValue. 2005-05-23 Roman Kennke <roman@kennke.org> * javax/swing/text/JTextComponent.java (getPreferredScrollableViewportSize): Implemented this method. (getScrollableUnitIncrement): Implemented this method. (getScrollableBlockIncrement): Implemented this method. 2005-05-23 Roman Kennke <roman@kennke.org> * javax/swing/JTextArea.java (getPreferredScrollableViewportSize): Added and implemented new method. (getScrollableUnitIncrement): Added and implemented new method. 2005-05-23 Audrius Meskauskas <AudriusA@Bioinformatics.org> * org/omg/CORBA/DefinitionKind.java, org/omg/CORBA/IRObject.java, org/omg/CORBA/IRObjectOperations.java, org/omg/CORBA/IDLTypeOperations.java: New files. * org/omg/CORBA/IDLType.java: Inherit from IDLTypeOperations. 2005-05-23 Roman Kennke <roman@kennke.org> * javax/swing/JLayeredPane.java (getLayer): Added and implemented new (static) method. 2005-05-23 Roman Kennke <roman@kennke.org> * javax/swing/JFileChooser.java (constructor(String, FileSystemView)): Added constructor. 2005-05-23 Roman Kennke <roman@kennke.org> * javax/swing/JViewport.java (createLayoutManager): Added and implemented new method. (constructor): Set the LayoutManager that is created by createLayoutManager(). * javax/swing/plaf/basic/BasicViewportUI.java (installUI): Removed setLayout(..). This is moved into the constructor of JViewport (as the API docs suggest). 2005-05-23 Audrius Meskauskas <AudriusA@Bioinformatics.org> * org/omg/CORBA/ORB.java (create_context_list, create_basic_dyn_any, create_dyn_any, create_dyn_array, create_dyn_enum, create_dyn_sequence, create_dyn_struct, create_dyn_union, create_policy, get_current): New methods. 2005-05-23 Roman Kennke <roman@kennke.org> * javax/swing/JViewport.java: (ViewListener): Added and implemented inner class. (createViewListener): Added and implemented new method. (setView): Add and remove ViewListener to/from the view component. 2005-05-23 Roman Kennke <roman@kennke.org> * javax/swing/DefaultListSelectionModel.java (fireValueChanged(boolean)): Added and implemented this method. 2005-05-23 Roman Kennke <roman@kennke.org> * javax/swing/SwingUtilities.java: (getWindowAncestor): Added and implemented this method. 2005-05-23 Roman Kennke <roman@kennke.org> * javax/swing/JFileChooser.java: Fixed the values of several public constant fields. 2005-05-23 Audrius Meskauskas, <AudriusA@Bioinformatics.org> * doc/www.gnu.org/tasks.wml: Improved text of the CORBA task. 2005-05-23 Roman Kennke <roman@kennke.org> * javax/swing/plaf/basic/BasicLookAndFeel.java (initComponentDefaults): Uncommented code that has accidentally been commented out. 2005-05-22 Roman Kennke <roman@kennke.org> * javax/swing/BoxLayout.java (maximumLayoutSize): Added checks for overflow. This is necessary because some components have maximumSize of Integer.MAX_VALUE, that would cause an overflow if summed up. 2005-05-22 Roman Kennke <roman@kennke.org> * javax/swing/tree/TreePath.java (getParentPath): Return null if this path only has no parent. 2005-05-22 Roman Kennke <roman@kennke.org> * javax/swing/plaf/basic/BasicTextUI.java: (getMaximumSize): Fixed comment. 2005-05-22 Roman Kennke <roman@kennke.org> * javax/swing/tree/TreePath.java: Reformatted this file in order to match our coding style. 2005-05-22 Audrius Meskauskas, <AudriusA@Bioinformatics.org> * org/omg/CORBA/ServerRequest.java, org/omg/CORBA/DynamicImplementation.java: New files. 2005-05-22 Dalibor Topic <robilad@kaffe.org> * gnu/java/security/provider/SHA1PRNG.java (SEED_SIZE, DATA_SIZE): new constants. Use them instead of magic numbers. (SHA1PRNG) Added documentation. 2005-05-22 Roman Kennke <roman@kennke.org> * javax/swing/plaf/basic/BasicTextUI.java (getMaximumSize): Implemented this method. 2005-05-22 Audrius Meskauskas, <AudriusA@Bioinformatics.org> * gnu/CORBA/cdrOutput.java (write_octet_array): Removing redundant loop. 2005-05-22 Audrius Meskauskas, <AudriusA@Bioinformatics.org> * org/omg/CORBA/ServiceInformation.java, org/omg/CORBA/ServiceInformationHelper.java, org/omg/CORBA/ServiceInformationHolder: New files. 2005-05-22 Audrius Meskauskas, <AudriusA@Bioinformatics.org> * org/omg/CORBA/ServiceDetail.java, org/omg/CORBA/ServiceDetailHelper.java, gnu/CORBA/ServiceDetailHolder.java: New files. 2005-05-21 Audrius Meskauskas, <AudriusA@Bioinformatics.org> * gnu/CORBA/ObjectCreator.java: Use gnu/CORBA namespace. 2005-05-21 Audrius Meskauskas, <AudriusA@Bioinformatics.org> * gnu/CORBA/universalHolder.java: New file. * gnu/CORBA/gnuAny.java (create_input_stream, read_value): Use the universalHolder. * gnu/CORBA/CDR/aligningInputStream.java (getBuffer): New method. 2005-05-21 Andreas Jaeger <aj@suse.de> * java/lang/mprec.c (mult, lshift, b2d, d2b): Add parenthesis to avoid warnings. 2005-05-21 Archie Cobbs <archie@dellroad.org> * NEWS: document VM interface changes. * java/lang/ClassLoader.java: (vmdata): add * vm/reference/java/lang/VMClass.java: (getModifiers()): add new parameter ignoreInnerClassesAttrib * vm/reference/java/lang/VMClassLoader.java: (defineClass()): remove deprecated version (getPrimitiveClass(String)): remove (getPrimitiveClass(char)): make native (loadClass()): make native * vm/reference/java/lang/VMThread.java: (vmdata): add (countStackFrames()): make native * vm/reference/java/lang/VMThrowable.java: (vmdata): add (fillInStackTrace()): make native (getStackTrace()): make native * vm/reference/java/lang/reflect/Constructor.java: (parameterTypes, exceptionTypes): remove (getParameterTypes(), getExceptionTypes()): make native 2005-05-21 Michael Koch <konqueror@gmx.de> * resource/gnu/java/locale/LocaleInformation_as.properties, resource/gnu/java/locale/LocaleInformation_bg.properties, resource/gnu/java/locale/LocaleInformation_cs.properties, resource/gnu/java/locale/LocaleInformation_da.properties, resource/gnu/java/locale/LocaleInformation_de.properties, resource/gnu/java/locale/LocaleInformation_dz.properties, resource/gnu/java/locale/LocaleInformation_en.properties, resource/gnu/java/locale/LocaleInformation_en_GB.properties, resource/gnu/java/locale/LocaleInformation_en_IE.properties, resource/gnu/java/locale/LocaleInformation_en_SG.properties, resource/gnu/java/locale/LocaleInformation_es.properties, resource/gnu/java/locale/LocaleInformation_fa.properties, resource/gnu/java/locale/LocaleInformation_fa_AF.properties, resource/gnu/java/locale/LocaleInformation_fi.properties, resource/gnu/java/locale/LocaleInformation_fr.properties, resource/gnu/java/locale/LocaleInformation_ga.properties, resource/gnu/java/locale/LocaleInformation_hi.properties, resource/gnu/java/locale/LocaleInformation_it.properties, resource/gnu/java/locale/LocaleInformation_ja.properties, resource/gnu/java/locale/LocaleInformation_ko.properties, resource/gnu/java/locale/LocaleInformation_mr.properties, resource/gnu/java/locale/LocaleInformation_mt.properties, resource/gnu/java/locale/LocaleInformation_nb.properties, resource/gnu/java/locale/LocaleInformation_nl.properties, resource/gnu/java/locale/LocaleInformation_ps.properties, resource/gnu/java/locale/LocaleInformation_pt.properties, resource/gnu/java/locale/LocaleInformation_sr.properties, resource/gnu/java/locale/LocaleInformation_sr_Latn.properties, resource/gnu/java/locale/LocaleInformation_sv.properties, resource/gnu/java/locale/LocaleInformation_sw.properties, resource/gnu/java/locale/LocaleInformation_ta.properties, resource/gnu/java/locale/LocaleInformation_uz_AF.properties, resource/gnu/java/locale/LocaleInformation_zh.properties, resource/gnu/java/locale/LocaleInformation_zh_Hant.properties: Regenerated with newer gnu.localegen to fix newline bug. 2005-05-21 Andrew John Hughes <gnu_andrew@member.fsf.org> * java/text/DateFormatSymbols.java: (getStringArray(java.util.ResourceBundle,String)): Fixed parsing of new property files. (getZoneStrings(java.util.ResourceBundle)): Likewise. 2005-05-21 Dalibor Topic <robilad@kaffe.org> * native/jni/gtk-peer/gnu_java_awt_peer_gtk_GdkPixbufDecoder.c (area_updated): Delete jpixels reference after use to avoid wasting references. 2005-05-20 Audrius Meskauskas, <AudriusA@Bioinformatics.org> * doc/www.gnu.org/tasks.wml: Adding CORBA task. 2005-05-20 Roman Kennke <roman@kennke.org> * java/awt/DefaultKeyboardFocusManager.java: Documentation fixes. 2005-05-20 Roman Kennke <roman@kennke.org> * javax/swing/text/JTextComponent.java (CaretBlinkTimer): Added inner class to make caret blinking. (constructor): Create one instance of CaretBlinkTimer. (setEditable): Switch caret on and off depending on the editable property. (setCare): Register caret with the CaretBlinkTimer. * javax/swing/text/DefaultCaret.java: Set a good blink rate of 500ms. 2005-05-20 Roman Kennke <roman@kennke.org> * javax/swing/JEditorPane.java: (processComponentKeyEvent): Removed this method. This blocks key events from beeing delivered and is not in the API. (processKeyEvent): Removed this method. This blocks key events from beeing delivered and is not in the API. 2005-05-20 Roman Kennke <roman@kennke.org> * java/awt/DefaultKeyboardFocusManager.java (processKeyEvent): Properly swallow KEY_TYPED events after a KEY_PRESSED event for a focusTraversalKey has been received. Otherwise the focusTraversalKey (e.g. a TAB) would end up beeing delivered to the focused component. 2005-05-20 Roman Kennke <roman@kennke.org> * java/awt/Component.java (dispatchEventImpl): Let MouseEvents trigger a focus change on lightweight components. 2005-05-20 Roman Kennke <roman@kennke.org> * javax/swing/JTextField.java (constructor): Set default value for the horizontalAlignment property. 2005-05-20 Roman Kennke <roman@kennke.org> * javax/swing/plaf/basic/BasicInternalFrameTitlePane.java (setButtonIcons): Added checks for null references. 2005-05-20 Roman Kennke <roman@kennke.org> * javax/swing/JProgressBar.java (paintBorder): Check if border is null before trying to paint it. * javax/swing/plaf/basic/BasicProgressBarUI.java (paint): Don't paint the border here. This would lead to the border beeing painted twice. 2005-05-20 Roman Kennke <roman@kennke.org> * javax/swing/SwingUtilities.java (convertPoint): Check for visibility of source and destination before calling convertPointToScreen or convertPointFromScreen. 2005-05-20 Audrius Meskauskas, <AudriusA@Bioinformatics.org> * org/omg/CORBA/SetOverrideType.java (_ADD_OVERRIDE, _SET_OVERRIDE), org/omg/CORBA/CompletionStatus.java (_COMPLETED_YES, _COMPLETED_NO, _COMPLETED_MAYBE): Making public. * org/omg/CORBA/ValueMember.java: Inherit from org.omg.CORBA.portable.IDLEntity. 2005-05-20 Audrius Meskauskas, <AudriusA@Bioinformatics.org> * org/omg/CORBA/portable/ApplicationException.java, org/omg/CORBA/portable/RemarshalException.java: Adding serialVersionUID. *org/omg/CORBA/portable/OutputStream.java(write_Context): Making concrete. org/omg/CORBA/portable/ServantObject.java (servant): Fixing typo in the field name. 2005-05-20 Michael Koch <konqueror@gmx.de> * scripts/generate-locale-list.sh: Use the new locale properties files. 2005-05-20 Robert Schuster <thebohemian@gmx.net> * javax/swing/SizeRequirements.java: Removed two non-UTF8 chars.
Diffstat (limited to 'vm')
-rw-r--r--vm/reference/java/lang/VMClass.java7
-rw-r--r--vm/reference/java/lang/VMClassLoader.java98
-rw-r--r--vm/reference/java/lang/VMThread.java10
-rw-r--r--vm/reference/java/lang/VMThrowable.java15
-rw-r--r--vm/reference/java/lang/reflect/Constructor.java16
5 files changed, 21 insertions, 125 deletions
diff --git a/vm/reference/java/lang/VMClass.java b/vm/reference/java/lang/VMClass.java
index 2d46da132..e94299204 100644
--- a/vm/reference/java/lang/VMClass.java
+++ b/vm/reference/java/lang/VMClass.java
@@ -193,12 +193,7 @@ final class VMClass
* @see Modifer
* @since 1.1
*/
- static int getModifiers(Class klass, boolean ignoreInnerClassesAttrib)
- {
- return getModifiers(klass);
- }
-
- private static native int getModifiers(Class klass);
+ static native int getModifiers(Class klass, boolean ignoreInnerClassesAttrib);
/**
* If this is a nested or inner class, return the class that declared it.
diff --git a/vm/reference/java/lang/VMClassLoader.java b/vm/reference/java/lang/VMClassLoader.java
index 203cc062d..fbfae9a6f 100644
--- a/vm/reference/java/lang/VMClassLoader.java
+++ b/vm/reference/java/lang/VMClassLoader.java
@@ -66,30 +66,6 @@ final class VMClassLoader
/**
* Helper to define a class using a string of bytes. This assumes that
* the security checks have already been performed, if necessary.
- * <strong>This method will be removed in a future version of GNU
- * Classpath</strong>.
- *
- * @param name the name to give the class, or null if unknown
- * @param data the data representing the classfile, in classfile format
- * @param offset the offset into the data where the classfile starts
- * @param len the length of the classfile data in the array
- * @return the class that was defined
- * @throws ClassFormatError if data is not in proper classfile format
- * @deprecated Implement
- * {@link #defineClass(ClassLoader, String, byte[], int, int, ProtectionDomain)}
- * instead.
- */
- static final native Class defineClass(ClassLoader cl, String name,
- byte[] data, int offset, int len)
- throws ClassFormatError;
-
- /**
- * Helper to define a class using a string of bytes. This assumes that
- * the security checks have already been performed, if necessary.
- *
- * <strong>For backward compatibility, this just ignores the protection
- * domain; that is the wrong behavior, and you should directly implement
- * this method natively if you can.</strong>
*
* Implementations of this method are advised to consider the
* situation where user code modifies the byte array after it has
@@ -105,13 +81,10 @@ final class VMClassLoader
* @return the class that was defined
* @throws ClassFormatError if data is not in proper classfile format
*/
- static final Class defineClass(ClassLoader cl, String name,
+ static final native Class defineClass(ClassLoader cl, String name,
byte[] data, int offset, int len,
ProtectionDomain pd)
- throws ClassFormatError
- {
- return defineClass(cl, name, data, offset, len);
- }
+ throws ClassFormatError;
/**
* Helper to resolve all references to other classes from this class.
@@ -123,19 +96,14 @@ final class VMClassLoader
/**
* Helper to load a class from the bootstrap class loader.
*
- * XXX - Not implemented; this requires native help.
- *
* @param name the class name to load
* @param resolve whether to resolve it
* @return the class, loaded by the bootstrap classloader or null
* if the class wasn't found. Returning null is equivalent to throwing
* a ClassNotFoundException (but a possible performance optimization).
*/
- static final Class loadClass(String name, boolean resolve)
- throws ClassNotFoundException
- {
- return null;
- }
+ static final native Class loadClass(String name, boolean resolve)
+ throws ClassNotFoundException;
/**
* Helper to load a resource from the bootstrap class loader.
@@ -262,66 +230,10 @@ final class VMClassLoader
* <li>'V' - void</li>
* </ul>
*
- * Note that this is currently a java version that converts the type code
- * to a string and calls the native <code>getPrimitiveClass(String)</code>
- * method for backwards compatibility with VMs that used old versions of
- * GNU Classpath. Please replace this method with a native method
- * <code>final static native Class getPrimitiveClass(char type);</code>
- * if your VM supports it. <strong>The java version of this method and
- * the String version of this method will disappear in a future version
- * of GNU Classpath</strong>.
- *
- * @param type the primitive type
- * @return a "bogus" class representing the primitive type
- */
- static final Class getPrimitiveClass(char type)
- {
- String t;
- switch (type)
- {
- case 'Z':
- t = "boolean";
- break;
- case 'B':
- t = "byte";
- break;
- case 'C':
- t = "char";
- break;
- case 'D':
- t = "double";
- break;
- case 'F':
- t = "float";
- break;
- case 'I':
- t = "int";
- break;
- case 'J':
- t = "long";
- break;
- case 'S':
- t = "short";
- break;
- case 'V':
- t = "void";
- break;
- default:
- throw new NoClassDefFoundError("Invalid type specifier: " + type);
- }
- return getPrimitiveClass(t);
- }
-
- /**
- * Old version of the interface, added here for backwards compatibility.
- * Called by the java version of getPrimitiveClass(char) when no native
- * version of that method is available.
- * <strong>This method will be removed in a future version of GNU
- * Classpath</strong>.
* @param type the primitive type
* @return a "bogus" class representing the primitive type
*/
- static final native Class getPrimitiveClass(String type);
+ static final native Class getPrimitiveClass(char type);
/**
* The system default for assertion status. This is used for all system
diff --git a/vm/reference/java/lang/VMThread.java b/vm/reference/java/lang/VMThread.java
index 25401041a..dccf8bb84 100644
--- a/vm/reference/java/lang/VMThread.java
+++ b/vm/reference/java/lang/VMThread.java
@@ -82,6 +82,11 @@ final class VMThread
private volatile boolean running;
/**
+ * VM private data.
+ */
+ private transient Object vmdata;
+
+ /**
* Private constructor, create VMThreads with the static create method.
*
* @param thread The Thread object that was just created.
@@ -221,10 +226,7 @@ final class VMThread
*
* @deprecated unsafe operation
*/
- int countStackFrames()
- {
- return 0;
- }
+ native int countStackFrames();
/**
* Wait the specified amount of time for the Thread in question to die.
diff --git a/vm/reference/java/lang/VMThrowable.java b/vm/reference/java/lang/VMThrowable.java
index beaf4147e..2a1a6fb88 100644
--- a/vm/reference/java/lang/VMThrowable.java
+++ b/vm/reference/java/lang/VMThrowable.java
@@ -50,6 +50,11 @@ package java.lang;
final class VMThrowable
{
/**
+ * VM private data.
+ */
+ private transient Object vmdata;
+
+ /**
* Private contructor, create VMThrowables with fillInStackTrace();
*/
private VMThrowable() { }
@@ -63,10 +68,7 @@ final class VMThrowable
* @return a new VMThrowable containing the current execution stack trace.
* @see Throwable#fillInStackTrace()
*/
- static VMThrowable fillInStackTrace(Throwable t)
- {
- return null;
- }
+ static native VMThrowable fillInStackTrace(Throwable t);
/**
* Returns an <code>StackTraceElement</code> array based on the execution
@@ -76,8 +78,5 @@ final class VMThrowable
* @return a non-null but possible zero length array of StackTraceElement.
* @see Throwable#getStackTrace()
*/
- StackTraceElement[] getStackTrace(Throwable t)
- {
- return new StackTraceElement[0];
- }
+ native StackTraceElement[] getStackTrace(Throwable t);
}
diff --git a/vm/reference/java/lang/reflect/Constructor.java b/vm/reference/java/lang/reflect/Constructor.java
index 40d40714d..e2c5e65a0 100644
--- a/vm/reference/java/lang/reflect/Constructor.java
+++ b/vm/reference/java/lang/reflect/Constructor.java
@@ -79,8 +79,6 @@ public final class Constructor<T>
{
private Class<T> clazz;
private int slot;
- private Class[] parameterTypes;
- private Class[] exceptionTypes;
/**
* This class is uninstantiable except from native code.
@@ -130,12 +128,7 @@ public final class Constructor<T>
*
* @return a list of the types of the constructor's parameters
*/
- public Class<?>[] getParameterTypes()
- {
- if (parameterTypes == null)
- return new Class[0];
- return parameterTypes;
- }
+ public native Class<?>[] getParameterTypes();
/**
* Get the exception types this constructor says it throws, in no particular
@@ -144,12 +137,7 @@ public final class Constructor<T>
*
* @return a list of the types in the constructor's throws clause
*/
- public Class<?>[] getExceptionTypes()
- {
- if (exceptionTypes == null)
- return new Class[0];
- return exceptionTypes;
- }
+ public native Class<?>[] getExceptionTypes();
/**
* Compare two objects to see if they are semantically equivalent.