1 // Purpose: 2 // Check that \DexExpectWatchValue applies no penalties when expected 3 // values are found. 4 // 5 // UNSUPPORTED: system-darwin 6 // 7 // RUN: %dexter_regression_test -- %s | FileCheck %s 8 // CHECK: expect_watch_value.cpp: 9 10 unsigned long Factorial(int n) { 11 volatile unsigned long fac = 1; // DexLabel('entry') 12 13 for (int i = 1; i <= n; ++i) 14 fac *= i; // DexLabel('loop') 15 16 return fac; // DexLabel('ret') 17 } 18 19 int main() 20 { 21 return Factorial(8); 22 } 23 24 /* 25 DexExpectWatchValue('n', '8', on_line=ref('entry')) 26 DexExpectWatchValue('i', 27 '1', '2', '3', '4', '5', '6', '7', '8', 28 on_line=ref('loop')) 29 30 DexExpectWatchValue('fac', 31 '1', '2', '6', '24', '120', '720', '5040', 32 on_line=ref('loop')) 33 34 DexExpectWatchValue('n', '8', on_line=ref('loop')) 35 DexExpectWatchValue('fac', '40320', on_line=ref('ret')) 36 DexExpectWatchValue('n', '8', on_line=ref('ret')) 37 */ 38