Skip to content

Instantly share code, notes, and snippets.

View samoht's full-sized avatar
💭
⛵️

Thomas Gazagnaire samoht

💭
⛵️
View GitHub Profile
module type LIST = (module type of List)
module M (X: sig end) = struct
module K = (val (match Random.int 2 with 0 -> assert false | _ -> (module List)): LIST)
end

Keybase proof

I hereby claim:

  • I am samoht on github.
  • I am samoht (https://keybase.io/samoht) on keybase.
  • I have a public key whose fingerprint is 8DD5 2ABD 293E 73E8 FD6E 8992 1A7B D9B2 EA10 4FBB

To claim this, I am signing this object:

@samoht
samoht / type_error.ml
Last active December 21, 2015 23:39
type error
module type S1 = sig
type t
end
module X = struct
type t = int
let f x = x
end
module type S2 = sig
@samoht
samoht / check_ocamlfind.ml
Last active December 21, 2015 18:19
Check that all the package correctly depend on ocamlfind
(* Run that file at the root of your repository:
ocamlbuild -pkg opam chek_ocamlfind.native --
This will rewrite all the OPAM files to add the missing ocamlfind dependency if needed.
*)
open OpamTypes
module N = OpamPackage.Name
@samoht
samoht / loc-lambda.diff
Created November 12, 2012 13:38
Location in lambda IR
commit 7c0725871e7dddf8fa9b3000405199cfe96886c3
Author: Thomas Gazagnaire <thomas@gazagnaire.org>
Date: Sun Dec 4 22:53:34 2011 +0100
Add location in lambda code
This is a very preliminary patch as there is just enough change to make everything compile, but location are not propagated through the backend.
Also the Levent are still there.