gcc/testsuite/jit.dg/test-error-gcc_jit_timer_pop-mismatch.c
raw| 1 | #include <stdlib.h> |
| 2 | #include <stdio.h> |
| 3 | |
| 4 | #include "libgccjit.h" |
| 5 | |
| 6 | #include "harness.h" |
| 7 | |
| 8 | void |
| 9 | create_code (gcc_jit_context *ctxt, void *user_data) |
| 10 | { |
| 11 | gcc_jit_timer *timer = gcc_jit_timer_new (); |
| 12 | /* Error: mismatched push/pop. */ |
| 13 | gcc_jit_timer_push (timer, "apples"); |
| 14 | gcc_jit_timer_pop (timer, "oranges"); |
| 15 | gcc_jit_timer_release (timer); |
| 16 | } |
| 17 | |
| 18 | void |
| 19 | verify_code (gcc_jit_context *ctxt, gcc_jit_result *result) |
| 20 | { |
| 21 | /* empty */ |
| 22 | } |