LinearML icon indicating copy to clipboard operation
LinearML copied to clipboard

let one = 1 in (fun() -> one) () evaluates to 32767

Open magnusjonsson opened this issue 14 years ago • 0 comments

On amd64, this outputs 32767 instead of 1.

module Main = struct

  val main: unit -> unit
  let main() =
    let one = 1 in
    Print.int((fun() -> one) ())
end

magnusjonsson avatar Mar 13 '11 20:03 magnusjonsson