sb-ext:run-program 的参数
有人可以准确地告诉我 sb-ext:run-program 的 args 参数应该是什么样子吗?
如果我这样做:
(sb-ext:run-program "C:/Program Files/iTunes/iTunes.exe"
"C:/lispbox-0.7/opus.mid")
我收到此错误:
debugger invoked on a TYPE-ERROR:
The value "C:/lispbox-0.7/opus.mid" is not of type LIST.
但是,如果我这样做:
(sb-ext:run-program "C:/Program Files/iTunes/iTunes.exe"
(list "C:\lispbox-0.7\opus.mid"))
iTunes 打开,但 MIDI 文件无法播放,即使从 Windows 命令提示符进行此调用工作正常:
U:\>"C:\Program Files\iTunes\iTunes.exe" C:\lispbox-0.7\opus.mid
请注意,此(带有正斜杠) :
CL-USER> (sb-ext:run-program "C:/Program Files/iTunes/iTunes.exe"
(list "C:/lispbox-0.7/opus.mid"))
具有相同的效果:iTunes 打开,但文件未播放。
Can someone tell me exactly what the args argument should look like for sb-ext:run-program?
If I do this:
(sb-ext:run-program "C:/Program Files/iTunes/iTunes.exe"
"C:/lispbox-0.7/opus.mid")
I get this error:
debugger invoked on a TYPE-ERROR:
The value "C:/lispbox-0.7/opus.mid" is not of type LIST.
However, if I do this:
(sb-ext:run-program "C:/Program Files/iTunes/iTunes.exe"
(list "C:\lispbox-0.7\opus.mid"))
iTunes opens, but the MIDI file doesn't play, even though this invocation from the Windows command prompt works just fine:
U:\>"C:\Program Files\iTunes\iTunes.exe" C:\lispbox-0.7\opus.mid
Note that this (with forward slashes):
CL-USER> (sb-ext:run-program "C:/Program Files/iTunes/iTunes.exe"
(list "C:/lispbox-0.7/opus.mid"))
has the same effect: iTunes opens, but the file is not played.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在列表版本中,您使用单个反斜杠,它被解析为转义序列。您需要使用双反斜杠。
In the list version you're using single backslashes, which get parsed as escape sequences. You need to use double backslashes.