about summary refs log tree commit diff homepage
path: root/test/Feature/GetValue.c
blob: dfd40d695f770f1d7c8dfa3a62c04aec95c4232a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// RUN: %llvmgcc -c -o %t1.bc %s
// RUN: %klee --exit-on-error %t1.bc

#include <stdio.h>
#include <assert.h>

int main() {
  int x = klee_int("x");
  klee_assume(x > 10);
  klee_assume(x < 20);

  assert(!klee_is_symbolic(klee_get_value_i32(x)));
  assert(klee_get_value_i32(x) > 10);
  assert(klee_get_value_i32(x) < 20);

  return 0;
}