[kaffe] CVS kaffe (dalibor): Replaced macro by static inline function
Kaffe CVS
Kaffe Mailing List <kaffe@kaffe.org>
Thu Feb 12 08:54:02 2004
PatchSet 4416
Date: 2004/02/12 16:47:38
Author: dalibor
Branch: HEAD
Tag: (none)
Log:
Replaced macro by static inline function
2004-02-12 Dalibor Topic <robilad@kaffe.org>
* kaffe/kaffevm/verify.c
(isNull): New static inline function.
(IS_NULL) Removed.
Replaced use of IS_NULL by isNull.
Members:
ChangeLog:1.1999->1.2000
kaffe/kaffevm/verify.c:1.33->1.34
Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.1999 kaffe/ChangeLog:1.2000
--- kaffe/ChangeLog:1.1999 Wed Feb 11 18:05:57 2004
+++ kaffe/ChangeLog Thu Feb 12 16:47:38 2004
@@ -1,3 +1,10 @@
+2004-02-12 Dalibor Topic <robilad@kaffe.org>
+
+ * kaffe/kaffevm/verify.c
+ (isNull): New static inline function.
+ (IS_NULL) Removed.
+ Replaced use of IS_NULL by isNull.
+
2004-02-11 Dalibor Topic <robilad@kaffe.org>
* kaffe/kaffevm/verify.c
Index: kaffe/kaffe/kaffevm/verify.c
diff -u kaffe/kaffe/kaffevm/verify.c:1.33 kaffe/kaffe/kaffevm/verify.c:1.34
--- kaffe/kaffe/kaffevm/verify.c:1.33 Wed Feb 11 18:05:59 2004
+++ kaffe/kaffe/kaffevm/verify.c Thu Feb 12 16:47:40 2004
@@ -951,8 +951,12 @@
static Type verify_NULL;
static Type* TNULL = &verify_NULL;
-#define IS_NULL(_TINFO) ((_TINFO)->data.class == TNULL->data.class)
-
+static inline
+bool
+isNull(const Type * tinfo)
+{
+ return (tinfo->data.class == TNULL->data.class);
+}
static const char* OBJECT_SIG = "Ljava/lang/Object;";
static Type verify_OBJ;
@@ -4556,7 +4560,7 @@
const char* sig2 = NULL;
uint32 len1, len2;
- if (IS_NULL(t1) || IS_NULL(t2)) {
+ if (isNull(t1) || isNull(t2)) {
return true;
}
@@ -5272,7 +5276,7 @@
if (type == NULL) {
dprintf("NULL");
}
- else if (IS_NULL(t)) {
+ else if (isNull(t)) {
dprintf("TNULL");
}