在 IDL 中定义函数时出错:"programs can't be compiled in single statement mode"

Error when defining function in IDL: "programs can't be compiled in single statement mode"

我正在使用 IDL 8.0.1 版,Windows 7 操作系统。

尝试在命令行中定义函数时,出现错误 "programs can't be compiled in single statement mode"。不太确定如何修复。

通常您会在文件中定义 functions/procedures,但您可以从命令行执行此操作:

IDL> .compile
- function triple, x
-   return, 3 * x
- end
% Compiled module: TRIPLE