summaryrefslogtreecommitdiff
path: root/cross-project-tests/debuginfo-tests/dexter/feature_tests/subtools/test/label_offset.cpp
blob: 83f46de82b3b24d9dd206274988b44cc9740b15c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
// Purpose:
//      Check that we can use label-relative line numbers.
//
// RUN: %dexter_regression_test_cxx_build %s -o %t
// RUN: %dexter_regression_test_run --binary %t -v -- %s | FileCheck --dump-input-context=999999999 %s
//
// CHECK: label_offset.cpp: (1.0000)

int main() {  // DexLabel('main')
    int var = 0;
    var = var;
    return 0;
}

/*
DexExpectWatchValue('var', '0', from_line=ref('main')+2, to_line=ref('main')+3)
DexExpectProgramState({
    'frames': [
        {
            'location': { 'lineno': ref('main')+2 },
            'watches': { 'var': '0' }
        }
    ]
})
*/