javaprims.h (_Jv_FormatInt): New declaration.

* gcj/javaprims.h (_Jv_FormatInt):  New declaration.
	* java/lang/natString.cc (_JvFormatInt):  New primitive, with logic
	taken from old Integer.toString code.
	(Integer::valueOf):  Use _Jv_FormatInt.
	* java/lang/Integer.java (toString):  Just use call String.valueOf.
	* java/lang/Long.java (toString):  Fix typo in comment.
	* java/lang/String.java (valueOf(int)):  Make native.
	* java/lang/StringBuffer.java (append(int)):  Make native.
	* java/lang/natStringBuffer.cc:  New file, for append(jint).
	* Makefile.am (ant_source_files):  Add java/lang/natStringBuffer.cc.

From-SVN: r42419
This commit is contained in:
Per Bothner 2001-05-21 21:38:37 -07:00 committed by Per Bothner
parent f5d6a24c2e
commit ef0a7b49a9
10 changed files with 98 additions and 40 deletions

View file

@ -89,10 +89,7 @@ public final class StringBuffer implements Serializable
* @return this <code>StringBuffer</code>.
* @see java.lang.String#valueOf(int)
*/
public StringBuffer append (int inum)
{
return append (String.valueOf(inum));
}
public native StringBuffer append (int inum);
/** Append the <code>String</code> value of the argument to this <code>StringBuffer</code>.
* Uses <code>String.valueOf()</code> to convert to