summarylogtreecommitdiffstats
path: root/4.05-typing-fix.patch
diff options
context:
space:
mode:
authorMarek Kubica2017-08-14 19:15:56 +0200
committerMarek Kubica2017-08-14 19:16:29 +0200
commit99daecf261b863238f22f3a68bc17a0ec1567001 (patch)
treec3241ba2a5af46294108f4e2b2884a1e1ee2de68 /4.05-typing-fix.patch
parentd0d9c11f2f7cd41ff9b680647edb3d8bbaefbd25 (diff)
downloadaur-99daecf261b863238f22f3a68bc17a0ec1567001.tar.gz
Fix compilation by copying patch from OPAM
Diffstat (limited to '4.05-typing-fix.patch')
-rw-r--r--4.05-typing-fix.patch43
1 files changed, 43 insertions, 0 deletions
diff --git a/4.05-typing-fix.patch b/4.05-typing-fix.patch
new file mode 100644
index 000000000000..178e4d19debb
--- /dev/null
+++ b/4.05-typing-fix.patch
@@ -0,0 +1,43 @@
+From 0fa0a19f15998e89e4b04150dd74529bbd406f42 Mon Sep 17 00:00:00 2001
+From: Gabriel Scherer <gabriel.scherer@gmail.com>
+Date: Fri, 24 Feb 2017 22:30:23 -0500
+Subject: [PATCH] 4.05 compatibility: use explicit module signatures
+
+In 4.05, checking for non-generalizable inference variable ('_a)
+(forbidden in toplevel modules and functors) happens before checking
+the .ml file against the .mli signature, so non-generalizable
+variables that were previously resolved through the .mli constraint
+are now underspecified and result in a compilation failure
+(see MPR#7414, GPR#929). This commit adds enough annotations to avoid
+such underspecified variables in functors.
+---
+ internal/unimap.ml | 2 +-
+ public/uCharInfo.ml | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/internal/unimap.ml b/internal/unimap.ml
+index b6fdbde..6a7cc30 100644
+--- a/internal/unimap.ml
++++ b/internal/unimap.ml
+@@ -58,7 +58,7 @@ val of_name : string -> t
+ end
+
+
+-module Make (Config : ConfigInt.Type) = struct
++module Make (Config : ConfigInt.Type) : Type = struct
+
+ type mapping = {no_char : int; tbl : Tbl31.Bytes.t}
+
+diff --git a/public/uCharInfo.ml b/public/uCharInfo.ml
+index 69bf141..6a0337a 100644
+--- a/public/uCharInfo.ml
++++ b/public/uCharInfo.ml
+@@ -298,7 +298,7 @@ val load_composition_exclusion_tbl : unit -> UCharTbl.Bool.t
+
+ end
+
+-module Make (Config : ConfigInt.Type) = struct
++module Make (Config : ConfigInt.Type) : Type = struct
+ include Unidata.Make(Config)
+
+ (* General category *)