summaryrefslogtreecommitdiff
path: root/test/cairo-test-private.h
diff options
context:
space:
mode:
authorAndrea Canciani <ranma42@gmail.com>2011-03-17 09:27:02 +0100
committerAndrea Canciani <ranma42@gmail.com>2011-03-17 17:35:28 +0100
commit4ef32a36ba1e457e8dd6244a6483866d33477aac (patch)
tree9bce70969ea3ddcfb86bc444814e6d144a79e031 /test/cairo-test-private.h
parentd6efb2a0b78ec8c3cc520e7a1ddebc8a5c5dc706 (diff)
downloadcairo-4ef32a36ba1e457e8dd6244a6483866d33477aac.tar.gz
test: Silence gcc warnings
warning: cannot optimize possibly infinite loops gcc does not detect that the "infinite" loops are actually just one or two iterations, depending on the has_similar value being FALSE or TRUE. It realizes it if the iteration variable and the iteration stop value are both enum values.
Diffstat (limited to 'test/cairo-test-private.h')
-rw-r--r--test/cairo-test-private.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/test/cairo-test-private.h b/test/cairo-test-private.h
index 8c841493b..e89eb70a2 100644
--- a/test/cairo-test-private.h
+++ b/test/cairo-test-private.h
@@ -36,7 +36,12 @@
CAIRO_BEGIN_DECLS
-cairo_bool_t
+typedef enum {
+ DIRECT,
+ SIMILAR
+} cairo_test_similar_t;
+
+cairo_test_similar_t
cairo_test_target_has_similar (const cairo_test_context_t *ctx,
const cairo_boilerplate_target_t *target);