- PR#4766: incorrect simplification of some type abbreviations.
- PR#4768: printf: %F does not respect width and precision specifications
- PR#4769: Format.bprintf fails to flush
-- PR#4775: compiler crash on crazy types (temporary fix)
+- PR#4775: fatal error Ctype.Unify during module type-checking (temporary fix)
- PR#4776: bad interaction between exceptions and classes
- PR#4780: labltk build problem under Windows.
- PR#4790: under Windows, map ERROR_NO_DATA Win32 error to EPIPE Unix error.
- PR#4792: bug in Big_int.big_int_of_int64 on 32-bit platforms.
+- PR#4796: ocamlyacc: missing NUL termination of string
+- PR#4804: bug in Big_int.int64_of_big_int on 32-bit platforms.
+- PR#4805: improving compatibility with the clang C compiler
+- PR#4809: issue with Unix.create_process under Win32
- Module Parsing: improved computation of locations when an ocamlyacc rule
starts with an empty nonterminal
- Type-checker: fixed wrong variance computation for private types
* First public release.
-$Id: Changes,v 1.183.2.13 2009/05/19 14:46:13 doligez Exp $
+$Id: Changes,v 1.183.2.17 2009/06/02 21:41:53 doligez Exp $
-3.11.1+rc0
+3.11.1+rc1
# The version string is the first line of this file.
# It must be in the format described in stdlib/sys.mli
-# $Id: VERSION,v 1.26.2.13 2009/05/19 14:46:13 doligez Exp $
+# $Id: VERSION,v 1.26.2.17 2009/06/02 21:41:53 doligez Exp $
ocamlyacc
camlheader
myocamlbuild
+myocamlbuild.native
#!/bin/sh
-# $Id: fastworld.sh,v 1.3.4.1 2008/10/23 15:29:11 ertai Exp $
+# $Id: fastworld.sh,v 1.3.4.2 2009/06/02 09:37:47 doligez Exp $
cd `dirname $0`
set -e
if [ -e ocamlbuild_mixed_mode ]; then
./mkconfig.sh
./mkmyocamlbuild_config.sh
. ../config/config.sh
-if [ "x$EXE" = "x.exe" ]; then
+if [ "x$EXE" = "x.exe" -a "x$SYSTEM" != "xcygwin" ]; then
./boot-c-parts-windows.sh
else
./boot-c-parts.sh
#!/bin/sh
-# $Id: otherlibs-targets.sh,v 1.4 2007/11/29 10:32:38 ertai Exp $
+# $Id: otherlibs-targets.sh,v 1.4.4.1 2009/05/26 12:49:16 ertai Exp $
OTHERLIBS_BYTE=""
OTHERLIBS_NATIVE=""
OTHERLIBS_UNIX_NATIVE=""
add_ocaml_lib() {
add_native "$1.cmxa"
+ add_native "$1.$A"
add_byte "$1.cma"
}
add_c_lib mldbm;;
dynlink)
add_ocaml_lib dynlink
- add_native dynlink.cmx
+ add_native dynlink.cmx dynlink.$O
add_file $lib.cmi extract_crc;;
win32unix)
UNIXDIR="otherlibs/win32unix"
#!/bin/sh
-# $Id: world.sh,v 1.3.4.1 2008/10/23 15:29:11 ertai Exp $
+# $Id: world.sh,v 1.3.4.2 2009/06/02 09:37:47 doligez Exp $
cd `dirname $0`
set -e
if [ -e ocamlbuild_mixed_mode ]; then
./mkconfig.sh
./mkmyocamlbuild_config.sh
. ../config/config.sh
-if [ "x$EXE" = "x.exe" ]; then
+if [ "x$EXE" = "x.exe" -a "x$SYSTEM" != "xcygwin" ]; then
./boot-c-parts-windows.sh
else
./boot-c-parts.sh
# #
#########################################################################
-# $Id: Makefile,v 1.64.2.3 2009/05/13 05:00:48 garrigue Exp $
+# $Id: Makefile,v 1.64.2.5 2009/05/25 12:25:25 doligez Exp $
include Makefile.common
DOBJS=$(OBJS:.o=.d.o) instrtrace.d.o
PICOBJS=$(OBJS:.o=.pic.o)
-TMP_SHARED_LIBRARIES=$(SUPPORTS_SHARED_LIBRARIES:false=)
-SHARED_LIBRARIES_DEPS=$(TMP_SHARED_LIBRARIES:true=libcamlrun_shared.so)
+SHARED_LIBS_TMP=$(SUPPORTS_SHARED_LIBRARIES:%false=)
+SHARED_LIBS_DEPS=$(SHARED_LIBS_TMP:%true=libcamlrun_shared.so)
-all:: $(SHARED_LIBRARIES_DEPS)
-
-install::
- if test -f libcamlrun_shared.so; then \
- cp libcamlrun_shared.so $(LIBDIR)/libcamlrun_shared.so; fi
+all:: $(SHARED_LIBS_DEPS)
ocamlrun$(EXE): libcamlrun.a prims.o
$(MKEXE) $(BYTECCLINKOPTS) -o ocamlrun$(EXE) \
libcamlrun_shared.so: $(PICOBJS)
$(MKDLL) -o libcamlrun_shared.so $(PICOBJS) $(BYTECCLIBS)
+install::
+ if test -f libcamlrun_shared.so; then \
+ cp libcamlrun_shared.so $(LIBDIR)/libcamlrun_shared.so; fi
+
+clean::
+ rm -f libcamlrun_shared.so
+
+
.SUFFIXES: .d.o .pic.o
.c.d.o:
# #
#########################################################################
-# $Id: Makefile.common,v 1.6 2008/09/10 05:51:11 weis Exp $
+# $Id: Makefile.common,v 1.6.2.1 2009/05/25 12:25:25 doligez Exp $
include ../config/Makefile
version.h : ../VERSION
echo "#define OCAML_VERSION \"`head -1 ../VERSION`\"" > version.h
-clean:
+clean ::
rm -f ocamlrun$(EXE) ocamlrund$(EXE) *.$(O) *.$(A) *.$(SO)
rm -f primitives prims.c opnames.h jumptbl.h ld.conf
rm -f version.h
/* */
/***********************************************************************/
-/* $Id: interp.c,v 1.97 2008/08/01 11:52:31 xleroy Exp $ */
+/* $Id: interp.c,v 1.97.2.1 2009/05/25 08:02:16 xleroy Exp $ */
/* The bytecode interpreter */
#include <stdio.h>
For GCC, I have hand-assigned hardware registers for several architectures.
*/
-#if defined(__GNUC__) && !defined(__INTEL_COMPILER) && !defined(DEBUG)
+#if defined(__GNUC__) && !defined(DEBUG) && !defined(__INTEL_COMPILER) && !defined(__llvm__)
#ifdef __mips__
#define PC_REG asm("$16")
#define SP_REG asm("$17")
# #
#########################################################################
-# $Id: configure,v 1.266.2.4 2009/05/19 13:23:47 doligez Exp $
+# $Id: configure,v 1.266.2.5 2009/05/20 15:33:09 weis Exp $
configure_options="$*"
prefix=/usr/local
for dir in \
$x11_include_dir \
\
+ /usr/X11R7/include \
+ /usr/include/X11R7 \
+ /usr/local/X11R7/include \
+ /usr/local/include/X11R7 \
+ /opt/X11R7/include \
+ \
/usr/X11R6/include \
/usr/include/X11R6 \
/usr/local/X11R6/include \
/* */
/***********************************************************************/
-/* $Id: parser.mly,v 1.7.28.3 2009/04/15 11:09:56 xclerc Exp $ */
+/* $Id: parser.mly,v 1.7.28.4 2009/05/23 14:42:57 xclerc Exp $ */
%{
opt_longident :
UIDENT { Some (Lident $1) }
+ | LIDENT { Some (Lident $1) }
| module_path DOT UIDENT { Some (Ldot($1, $3)) }
| { None };
-\" $Id: ocamldoc.m,v 1.5 2008/09/15 14:12:56 doligez Exp $
+\" $Id: ocamldoc.m,v 1.5.2.1 2009/05/27 14:35:27 doligez Exp $
.TH OCAMLDOC 1
.TP
.BI \-g \ file
Dynamically load the given file (which extension usually is .cmo or .cma),
-which defines a custom documentation generator. This option is supported by the
-.BR ocamldoc (1)
-command, but not by its native-code version
-.BR ocamldoc.opt .
+which defines a custom documentation generator.
If the given file is a simple one and does not exist in
the current directory, then ocamldoc looks for it in the custom
generators default directory, and in the directories specified with the
(* *)
(***********************************************************************)
-(* $Id: myocamlbuild.ml,v 1.23.2.5 2009/05/05 13:40:18 ertai Exp $ *)
+(* $Id: myocamlbuild.ml,v 1.23.2.6 2009/05/26 12:49:16 ertai Exp $ *)
open Ocamlbuild_plugin
open Command
copy_rule' ~insert:`top "otherlibs/dynlink/natdynlink.ml" "otherlibs/dynlink/nat/dynlink.ml";;
copy_rule' ~insert:`top "otherlibs/dynlink/dynlink.mli" "otherlibs/dynlink/nat/dynlink.mli";;
copy_rule' ~insert:`top "otherlibs/dynlink/nat/dynlink.cmx" "otherlibs/dynlink/dynlink.cmx";;
+copy_rule' ~insert:`top ("otherlibs/dynlink/nat/dynlink"-.-C.o) ("otherlibs/dynlink/dynlink"-.-C.o);;
copy_rule' ~insert:`top "otherlibs/dynlink/nat/dynlink.cmxa" "otherlibs/dynlink/dynlink.cmxa";;
copy_rule' ~insert:`top ("otherlibs/dynlink/nat/dynlink"-.-C.a) ("otherlibs/dynlink/dynlink"-.-C.a);;
dep ["ocaml"; "compile"; "native"; "file:otherlibs/dynlink/nat/dynlink.cmx"] ["otherlibs/dynlink/nat/dynlink.cmi"];;
let labltk_cmxa_contents = labltk_contents "cmx" in
rule "labltk.cmxa"
- ~prod:"otherlibs/labltk/lib/labltk.cmxa"
+ ~prods:["otherlibs/labltk/lib/labltk.cmxa"; "otherlibs/labltk/lib/labltk"-.-C.a]
~deps:labltk_cmxa_contents
(Ocamlbuild_pack.Ocaml_compiler.native_library_link_modules
labltk_lib_contents "otherlibs/labltk/lib/labltk.cmxa");;
let bindir = ref Ocamlbuild_Myocamlbuild_config.bindir;;
let libdir = ref begin
- try Filename.concat (Sys.getenv "OCAMLLIB") "ocamlbuild"
- with Not_found -> Ocamlbuild_Myocamlbuild_config.libdir
+ Filename.concat
+ (try Sys.getenv "OCAMLLIB"
+ with Not_found -> Ocamlbuild_Myocamlbuild_config.libdir)
+ "ocamlbuild"
end;;
#(* *)
#(***********************************************************************)
-# $Id: Makefile.nt,v 1.27.4.1 2009/04/09 13:56:38 guesdon Exp $
+# $Id: Makefile.nt,v 1.27.4.2 2009/05/20 12:07:05 doligez Exp $
include ../config/Makefile
OCAMLPP=-pp "grep -v DEBUG"
-# For installation
+# For installation
##############
MKDIR=mkdir
CP=cp
all: exe lib
exe: $(OCAMLDOC)
-lib: $(OCAMLDOC_LIBCMA) $(OCAMLDOC_LIBCMI)
+lib: $(OCAMLDOC_LIBCMA) $(OCAMLDOC_LIBCMI)
opt.opt: exeopt libopt
exeopt: $(OCAMLDOC_OPT)
-libopt: $(OCAMLDOC_LIBCMXA) $(OCAMLDOC_LIBCMI)
-debug:
+libopt: $(OCAMLDOC_LIBCMXA) $(OCAMLDOC_LIBCMI)
+debug:
make OCAMLPP=""
-$(OCAMLDOC): $(EXECMOFILES)
+$(OCAMLDOC): $(EXECMOFILES)
$(OCAMLC) -o $@ -linkall unix.cma str.cma dynlink.cma $(LINKFLAGS) $(OCAMLCMOFILES) $(EXECMOFILES)
$(OCAMLDOC_OPT): $(EXECMXFILES)
- $(OCAMLOPT) -o $@ unix.cmxa str.cmxa $(LINKFLAGS) $(OCAMLCMXFILES) $(EXECMXFILES)
+ $(OCAMLOPT) -o $@ unix.cmxa str.cmxa dynlink.cmxa $(LINKFLAGS) $(OCAMLCMXFILES) $(EXECMXFILES)
$(OCAMLDOC_LIBCMA): $(LIBCMOFILES)
$(OCAMLC) -a -o $@ $(LINKFLAGS) $(OCAMLCMOFILES) $(LIBCMOFILES)
-include ../support/Makefile.common.nt
+include ../support/Makefile.common
# We are using the non-installed library !
COMPFLAGS= -I ../lib -I ../camltk -I ../support
-include ../support/Makefile.common.nt
+include ../support/Makefile.common
# We are using the non-installed library !
COMPFLAGS= -I ../lib -I ../labltk -I ../support
(* *)
(***********************************************************************)
-(* $Id: big_int.ml,v 1.24.2.1 2009/05/18 13:08:03 xleroy Exp $ *)
+(* $Id: big_int.ml,v 1.24.2.2 2009/05/24 19:46:44 xleroy Exp $ *)
open Int_misc
open Nat
else begin
let i =
match num_digits_big_int bi with
- | 1 -> Int64.of_nativeint (nth_digit_nat_native bi.abs_value 0)
+ | 1 -> Int64.logand
+ (Int64.of_nativeint (nth_digit_nat_native bi.abs_value 0))
+ 0xFFFFFFFFL
| 2 -> Int64.logor
(Int64.logand
(Int64.of_nativeint (nth_digit_nat_native bi.abs_value 0))
(int64_of_big_int (big_int_of_string "-9223372036854775808"), -9223372036854775808L);;
test 4 eq_int64
(int64_of_big_int (big_int_of_string "-9223372036854775"), -9223372036854775L);;
+test 5 eq_int64 (* PR#4804 *)
+ (int64_of_big_int (big_int_of_string "2147483648"), 2147483648L);;
let should_fail s =
try ignore (int64_of_big_int (big_int_of_string s)); 0
with Failure _ -> 1;;
-test 4 eq_int
+test 6 eq_int
(should_fail "9223372036854775808", 1);;
-test 5 eq_int
+test 7 eq_int
(should_fail "-9223372036854775809", 1);;
-test 6 eq_int
+test 8 eq_int
(should_fail "18446744073709551616", 1);;
/* */
/***********************************************************************/
-/* $Id: createprocess.c,v 1.14 2008/01/11 16:13:16 doligez Exp $ */
+/* $Id: createprocess.c,v 1.14.4.1 2009/06/02 13:12:53 xleroy Exp $ */
#include <windows.h>
#include <mlvalues.h>
envp = NULL;
}
/* Prepare stdin/stdout/stderr redirection */
- GetStartupInfo(&si);
- si.dwFlags |= STARTF_USESTDHANDLES;
+ ZeroMemory(&si, sizeof(STARTUPINFO));
+ si.cb = sizeof(STARTUPINFO);
+ si.dwFlags = STARTF_USESTDHANDLES;
si.hStdInput = Handle_val(fd1);
si.hStdOutput = Handle_val(fd2);
si.hStdError = Handle_val(fd3);
/* If we do not have a console window, then we must create one
before running the process (keep it hidden for apparence).
- Also one must suppress spurious flags in si.dwFlags.
- Otherwise the redirections are ignored.
If we are starting a GUI application, the newly created
console should not matter. */
if (win_has_console())
/* Based on public-domain code from Berkeley Yacc */
-/* $Id: reader.c,v 1.32 2005/10/06 06:34:51 garrigue Exp $ */
+/* $Id: reader.c,v 1.32.18.1 2009/05/20 11:58:43 doligez Exp $ */
#include <string.h>
#include "defs.h"
for (i = 0; i < len; i++){
buf[i] = str[start+i];
}
+ buf[i] = '\0'; /* PR#4796 */
return buf;
}
n = cinc;
s = MALLOC(n);
if (s == 0) no_space();
-
+
for (i = 0; i < n; ++i)
s[i] = cache[i];
{
++cptr;
i = get_number();
-
+
if (i <= 0 || i > n)
unknown_rhs(i);
item = pitem[nitems + i - n - 1];
fwrite(cptr, 1, 2, f);
cptr += 2;
} else
- if (cptr[0] == '\\'
+ if (cptr[0] == '\\'
&& isdigit((unsigned char) cptr[1])
&& isdigit((unsigned char) cptr[2])
&& isdigit((unsigned char) cptr[3])