Ocaml 代码注释中的预处理错误

Ocaml 代码注释中的预处理错误,ocaml,camlp4,Ocaml,Camlp4,使用corebuild编译代码时出现此错误: ~/project $ corebuild debug.byte ocamlfind ocamldep -syntax camlp4o -package bin_prot.syntax -package sexplib.syntax,comparelib.syntax,fieldslib.syntax,variantslib.syntax -package core -modules globals.ml > globals.ml.depend

使用
corebuild
编译代码时出现此错误:

~/project $ corebuild debug.byte
ocamlfind ocamldep -syntax camlp4o -package bin_prot.syntax -package sexplib.syntax,comparelib.syntax,fieldslib.syntax,variantslib.syntax -package core -modules globals.ml > globals.ml.depends
+ ocamlfind ocamldep -syntax camlp4o -package bin_prot.syntax -package sexplib.syntax,comparelib.syntax,fieldslib.syntax,variantslib.syntax -package core -modules globals.ml > globals.ml.depends
File "globals.ml", line 744, characters 57-17803 (end at line 1402, character 0):
Quotation not terminated
Preprocessing error on file globals.ml
Error while running external preprocessor
Command line: camlp4 '-I' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/ocaml/camlp4' '-I' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/type_conv' '-I' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/ocaml' '-I\
' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/ocaml' '-I' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/bin_prot' '-I' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/bin_prot' '-I' '/Users/mapleleaf/.opam/4.0\
1.0dev+trunk/lib/ocaml' '-I' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/num' '-I' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/sexplib' '-I' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/sexplib' '-I' '/Us\
ers/mapleleaf/.opam/4.01.0dev+trunk/lib/comparelib' '-I' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/comparelib' '-I' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/fieldslib' '-I' '/Users/mapleleaf/.opam/4\
.01.0dev+trunk/lib/fieldslib' '-I' '/Users/mapleleaf/.opam/4.01.0dev+trunk/lib/variantslib' '-I
令人不快的是:

let allow_imm_inv = ref true (* imm inv to add of form @M<:v<:@A *)
让allow_imm_inv=ref true(*imm inv to add of form@MCamlP4不会“忽略”已注释的引用。即使在注释中,它们也必须平衡

这就像OCaml要求在注释中平衡字符串引号一样。例如:

(* " *)        <-  rejected as a syntax error

(*“*)谢谢!我在这里读到了camlp4是如何解析源代码和注释的:。这就是ocamldoc如何从javadoc之类的注释生成文档的。
(* " *) " *)   <-  a valid comment (the syntax highlight gone crazy though)
(* @M <: v <: @A *)