test_assert_int.cocci (632B)
1 @@ 2 int e; 3 constant c; 4 @@ 5 6 ( 7 - tt_assert(e == c) 8 + tt_int_op(e, OP_EQ, c) 9 | 10 - tt_assert(e != c) 11 + tt_int_op(e, OP_NE, c) 12 | 13 - tt_assert(e < c) 14 + tt_int_op(e, OP_LT, c) 15 | 16 - tt_assert(e <= c) 17 + tt_int_op(e, OP_LE, c) 18 | 19 - tt_assert(e > c) 20 + tt_int_op(e, OP_GT, c) 21 | 22 - tt_assert(e >= c) 23 + tt_int_op(e, OP_GE, c) 24 ) 25 26 @@ 27 unsigned int e; 28 constant c; 29 @@ 30 31 ( 32 - tt_assert(e == c) 33 + tt_uint_op(e, OP_EQ, c) 34 | 35 - tt_assert(e != c) 36 + tt_uint_op(e, OP_NE, c) 37 | 38 - tt_assert(e < c) 39 + tt_uint_op(e, OP_LT, c) 40 | 41 - tt_assert(e <= c) 42 + tt_uint_op(e, OP_LE, c) 43 | 44 - tt_assert(e > c) 45 + tt_uint_op(e, OP_GT, c) 46 | 47 - tt_assert(e >= c) 48 + tt_uint_op(e, OP_GE, c) 49 )