rustboot compile error with OCaml 3.12
Changes in OCaml for version 3.12 give compile errors in rustboot:
compile: boot/fe/cexp.ml
File "boot/fe/cexp.ml", line 347, characters 15-24:
Warning 9: the following labels are not bound in this record pattern:
id
Either bind these labels explicitly or add ; _' to the pattern. File "boot/fe/cexp.ml", line 361, characters 15-24: Warning 9: the following labels are not bound in this record pattern: id Either bind these labels explicitly or add; _' to the pattern.
File "boot/fe/cexp.ml", line 1, characters 0-1:
Error: Error-enabled warnings (2 occurrences)
make: *** [boot/fe/cexp.cmx] Error 2
(thanks to Jeff Schultz for confirming this)
Commit 99086292ac50458244722aedbad53c5047214429 should fix this; please verify.
Patrick Walton at 2010-10-11 17:53:10
Apologies. I should have done 'make -k'. There are a lot more than this, which I've fixed myself by adding '; _' where suggested. Is that syntax OK in 3.11? If so I can post a diff or push the changes. However there were 2 more errors I couldn't fix: compile: boot/llvm/lltrans.ml File "boot/llvm/lltrans.ml", line 371, characters 25-26: Warning 28: wildcard pattern given as argument to a constant constructor File "boot/llvm/lltrans.ml", line 373, characters 25-26: Warning 28: wildcard pattern given as argument to a constant constructor I tried a named var instead of the wildcard but got a different warning instead. Thanks.
Deleted user at 2010-10-11 20:42:11
Actually I just got rid of the _ since MODE_alias didn't seem to take an argument, i.e.
@@ -368,9 +368,9 @@ let trans_crate in let base_llty = trans_ty ty in match slot.Ast.slot_mode with - | Ast.MODE_alias _ -> + | Ast.MODE_alias -> Llvm.pointer_type base_llty - | Ast.MODE_local _ -> base_llty + | Ast.MODE_local -> base_llty in let get_element_ptrDoes that look OK?
Deleted user at 2010-10-11 20:49:30
'; _' is fine in OCaml 3.11.
And that looks good to me. I'd take a pull request, thanks for looking into this :)
Patrick Walton at 2010-10-12 15:06:04
I've put in the pull request, it's issue #172.
Deleted user at 2010-10-12 17:03:39
Fixed long ago.
Graydon Hoare at 2011-01-27 01:59:17