Add Math.pow() and Math.sqrt() native peers

This commit is contained in:
Eric Scharff 2007-10-11 16:41:52 -06:00
parent 9d3027540b
commit 3fbe5b9a01

View File

@ -81,6 +81,18 @@ Java_java_lang_System_doMapLibraryName(JNIEnv* e, jclass, jstring name)
return r;
}
extern "C" JNIEXPORT jdouble JNICALL
Java_java_lang_Math_sqrt(JNIEnv*, jclass, jdouble val)
{
return sqrt(val);
}
extern "C" JNIEXPORT jdouble JNICALL
Java_java_lang_Math_pow(JNIEnv*, jclass, jdouble val, jdouble exp)
{
return pow(val, exp);
}
extern "C" JNIEXPORT jdouble JNICALL
Java_java_lang_Math_floor(JNIEnv*, jclass, jdouble val)
{