2 # UNSUPPORTED: system-windows
3 # RUN: %lldb -b -o 'settings set interpreter.stop-command-source-on-error false' -s %s 2>&1 | FileCheck %s
5 target create -l "ls" /bin/ls
7 # CHECK: * target #0 (ls): [[LS_PATH:.*]]
9 script lldb.target.SetLabel("")
11 # CHECK: * target #0: [[LS_PATH]]
13 target create -l "cat" /bin/cat
15 # CHECK: target #0: [[LS_PATH]]
16 # CHECK-NEXT: * target #1 (cat): [[CAT_PATH:.*]]
18 target create -l "cat" /bin/cat
19 # CHECK: Cannot use label 'cat' since it's set in target #1.
21 target create -l 42 /bin/cat
22 # CHECK: error: Cannot use integer as target label.
25 # CHECK: * target #0: [[LS_PATH]]
26 # CHECK-NEXT: target #1 (cat): [[CAT_PATH]]
29 # CHECK: target #0: [[LS_PATH]]
30 # CHECK-NEXT: * target #1 (cat): [[CAT_PATH]]
32 script lldb.target.GetLabel()
35 script lldb.debugger.GetTargetAtIndex(0).SetLabel('Not cat')
39 # CHECK: target #0 (Not cat): [[LS_PATH]]
40 # CHECK-NEXT: * target #1 (cat): [[CAT_PATH]]