caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] Syntax errors with match and interface files
@ 2005-07-21 22:42 Jonathan Roewen
  2005-07-22  0:26 ` Stephane Glondu
  2005-07-22  5:47 ` skaller
  0 siblings, 2 replies; 3+ messages in thread
From: Jonathan Roewen @ 2005-07-21 22:42 UTC (permalink / raw)
  To: caml-list

Hi,

I'm getting a curious syntax error:

in my Key.mli file, I have:

val kEnter: int;
val kBksp: int;

then, in Console.ml, I'm trying something like:

try
let put c = putch c; Queue.add c buffer in
match char_code with
| Key.kEnter -> put '\n'
| Key.kBksp -> put '\b'
| ch -> put (Key.to_char ch)
with Key.Not_printable -> ()

but I get a syntax error at any match case with Key.xxx. I tried
replacing with arbitrary numbers, and the errors at those lines
disappear.

Is this a problem with the ocaml[opt] compiler?

Jonathan


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2005-07-22  5:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-07-21 22:42 [Caml-list] Syntax errors with match and interface files Jonathan Roewen
2005-07-22  0:26 ` Stephane Glondu
2005-07-22  5:47 ` skaller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).