[llvm-commits] CVS: llvm-java/test/Programs/SingleSource/UnitTests/test.c
Alkis Evlogimenos
alkis at cs.uiuc.edu
Mon Dec 6 20:55:56 PST 2004
Changes in directory llvm-java/test/Programs/SingleSource/UnitTests:
test.c added (r1.1)
---
Log message:
Commit sources for the test library.
---
Diffs of the changes: (+31 -0)
Index: llvm-java/test/Programs/SingleSource/UnitTests/test.c
diff -c /dev/null llvm-java/test/Programs/SingleSource/UnitTests/test.c:1.1
*** /dev/null Mon Dec 6 22:55:55 2004
--- llvm-java/test/Programs/SingleSource/UnitTests/test.c Mon Dec 6 22:55:45 2004
***************
*** 0 ****
--- 1,31 ----
+ #include <stdio.h>
+
+ #include "Test.h"
+
+ void Java_Test_print_1boolean_1ln(JNIEnv *env, jclass clazz, jboolean aBoolean)
+ {
+ if (aBoolean)
+ puts("true");
+ else
+ puts("false");
+ }
+
+ void Java_Test_print_1int_1ln(JNIEnv *env, jclass clazz, jint aInt)
+ {
+ printf("%d\n", aInt);
+ }
+
+ void Java_Test_print_1long_1ln(JNIEnv *env, jclass clazz, jlong aLong)
+ {
+ printf("%Ld\n", aLong);
+ }
+
+ void Java_Test_print_1float_1ln(JNIEnv *env, jclass clazz, jfloat aFloat)
+ {
+ printf("%f\n", aFloat);
+ }
+
+ void Java_Test_print_1double_1ln(JNIEnv *env, jclass clazz, jdouble aDouble)
+ {
+ printf("%lf\n", aDouble);
+ }
More information about the llvm-commits
mailing list