1 int storage = 45;
2 thread_local int tl_global_int = 123;
3 thread_local int *tl_global_ptr = &storage;
4 
5 int main(int argc, char **argv) {
6   //% self.expect("expr tl_local_int", error=True, substrs=["couldn't get the value of variable tl_local_int"])
7   //% self.expect("expr *tl_local_ptr", error=True, substrs=["couldn't get the value of variable tl_local_ptr"])
8   thread_local int tl_local_int = 321;
9   thread_local int *tl_local_ptr = nullptr;
10   tl_local_ptr = &tl_local_int;
11   tl_local_int++;
12   //% self.expect("expr tl_local_int + 1", substrs=["int", "= 323"])
13   //% self.expect("expr *tl_local_ptr + 2", substrs=["int", "= 324"])
14   //% self.expect("expr tl_global_int", substrs=["int", "= 123"])
15   //% self.expect("expr *tl_global_ptr", substrs=["int", "= 45"])
16   return 0;
17 }
18