[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 21/24] coccinelle: add g_assert_cmp* to macro file
From: |
Paolo Bonzini |
Subject: |
[Qemu-devel] [PULL 21/24] coccinelle: add g_assert_cmp* to macro file |
Date: |
Mon, 23 May 2016 17:09:56 +0200 |
This helps applying semantic patches to unit tests.
Signed-off-by: Paolo Bonzini <address@hidden>
---
scripts/cocci-macro-file.h | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/scripts/cocci-macro-file.h b/scripts/cocci-macro-file.h
index eceb4be..9f2e72e 100644
--- a/scripts/cocci-macro-file.h
+++ b/scripts/cocci-macro-file.h
@@ -117,3 +117,9 @@ struct {
\
type *tqe_next; /* next element */ \
type **tqe_prev; /* address of previous next element */ \
}
+
+/* From glib */
+#define g_assert_cmpint(a, op, b) g_assert(a op b)
+#define g_assert_cmpuint(a, op, b) g_assert(a op b)
+#define g_assert_cmphex(a, op, b) g_assert(a op b)
+#define g_assert_cmpstr(a, op, b) g_assert(strcmp(a, b) op 0)
--
1.8.3.1
- [Qemu-devel] [PULL 14/24] cpus.c: Use pthread_sigmask() rather than sigprocmask(), (continued)
- [Qemu-devel] [PULL 14/24] cpus.c: Use pthread_sigmask() rather than sigprocmask(), Paolo Bonzini, 2016/05/23
- [Qemu-devel] [PULL 23/24] nmi: remove x86 specific nmi handling, Paolo Bonzini, 2016/05/23
- [Qemu-devel] [PULL 19/24] esp: check dma length before reading scsi command(CVE-2016-4441), Paolo Bonzini, 2016/05/23
- [Qemu-devel] [PULL 12/24] memory: Drop FlatRange.romd_mode, Paolo Bonzini, 2016/05/23
- [Qemu-devel] [PULL 17/24] scripts/signrom.py: Check for magic in option ROMs., Paolo Bonzini, 2016/05/23
- [Qemu-devel] [PULL 11/24] memory: Remove code for mr->may_overlap, Paolo Bonzini, 2016/05/23
- [Qemu-devel] [PULL 16/24] scripts/signrom.py: Allow option ROM checksum script to write the size header., Paolo Bonzini, 2016/05/23
- [Qemu-devel] [PULL 24/24] cpus: call the core nmi injection function, Paolo Bonzini, 2016/05/23
- [Qemu-devel] [PULL 20/24] iscsi: pass SCSI status back for SG_IO, Paolo Bonzini, 2016/05/23
- [Qemu-devel] [PULL 22/24] target-i386: add a generic x86 nmi handler, Paolo Bonzini, 2016/05/23
- [Qemu-devel] [PULL 21/24] coccinelle: add g_assert_cmp* to macro file,
Paolo Bonzini <=
- Re: [Qemu-devel] [PULL 00/24] Misc patches for 2016-05-23, Peter Maydell, 2016/05/23