Add support for changing the stdout and stderr file in Lua's I/O library and hook it up with the debugger's output and error file respectively for the interactive Lua interpreter. https://reviews.llvm.org/D82273
17 lines
423 B
Plaintext
17 lines
423 B
Plaintext
# REQUIRES: lua
|
|
# UNSUPPORTED: lldb-repro
|
|
#
|
|
# RUN: cat %s | %lldb --script-language lua 2> %t.stderr > %t.stdout
|
|
# RUN: cat %t.stdout | FileCheck %s --check-prefix STDOUT
|
|
# RUN: cat %t.stderr | FileCheck %s --check-prefix STDERR
|
|
script
|
|
file = lldb.SBFile(2, "w", false)
|
|
lldb.debugger:SetOutputFile(file)
|
|
io.write(95000 + 126, "\n")
|
|
quit
|
|
script
|
|
io.write(95000 + 14, "\n")
|
|
# STDOUT: 95126
|
|
# STDOUT-NOT: 95014
|
|
# STDERR: 95014
|