我想在OCaml中使用regexps,似乎Str模块提供了这些功能。
所以我试着用一个简单的程序:@H_404_2@
open Str let regx = regexp "."
File “lol.ml”,line 1,characters 0-1:
Error: Error while linking lol.cmo:
Reference to undefined global `Str’@H_404_2@
好像模块不存在,但是如果我删除了开放的Str它表示regexp是一个未绑定的值。@H_404_2@
我不会得到什么样的问题,Str应该是一个标准的模块(根据http://caml.inria.fr/pub/docs/old-311/libref/Str.html),所以我没有意义。唯一的想法是认为是签名(mli)存在,但是实现(ml)不是。@H_404_2@
我根据ocaml工具运行Objective Caml版本3.11.0。@H_404_2@
有人可以帮我弄清楚吗?
提前致谢@H_404_2@
从
the manual:
Programs that use the str library must be linked as follows:@H_404_2@
06000@H_404_2@