Previous week Up Next week


Here is the latest OCaml Weekly News, for the week of April 01 to 08, 2014.

  1. OCaml release 5.00
  2. React 1.0.0
  3. OCaml Engineers and Scientists at CEA, Software Security Labs (Paris Saclay, France)
  4. IOCaml 0.4
  5. Second CFP: Higher-order, Typed, Inferred, Strict: ML Family Workshop
  6. Hashset implementation
  7. Core Suite 111.08.00
  8. Experiment: OCaml patch review on
  9. Other OCaml News

OCaml release 5.00


On April 1st, Damien Doligez announced:
(English version below)

Chers utilisateurs,

La nouvelle version du langage Java intègre les lambdas. Nous
(concepteurs de langages fonctionnels) avons gagné; il y a dix ans
encore nous nous battions pour faire comprendre aux programmeurs
"courant principal" les intérêts des fonctions d'ordre supérieur,
maintenant c'est eux qui écrivent des billets de journaux intimes
à leur gloire.

Pour célébrer ce changement, et le besoin ainsi diminué de convaincre
les masses incultes, nous avons décidé de revenir sur une décision
démagogique et trop coûteuse dans la conception du langage Chamelle: sa
soumission à la langue anglaise.

    type 'a arbre = Feuille de 'a | Nœud de 'a arbre * 'a arbre

    soit rec feuille_existe p arbre =
      filtre arbre avec
      | Feuille v -> p v
      | Nœud (gauche, droite) ->
          feuille_existe p gauche
          || feuille_existe p droite

    soit a_une_feuille_paire =
      feuille_existe (fun n -> n mod 2 = 0)

C'est avec plaisir et fierté que nous célébrons la naissance d'Otto
Von Bismarck en vous faisant découvrir Chamelle numéro 5, première
version en français de votre langage préféré. Nous espérons que
l'usage de la "langue de la diplomatie" permettra aux communautés
informatiques un dialogue plus serein.

    $ cat
    soit unis = 1
    soit 1 = unis

    $ ./ocamlc
    File "", line 2, characters 5-6:
    Avertissement 8: ce filtrage de motif n'est pas exhaustif.
    Ceci est un exemple de valeur qui n'est pas filtrée:

Cette libération linguistique nous a donné des ailes, et la première
sortie de Chamelle numéro 5 contient un certain nombre de
fonctionnalités prometteuses et améliorations diverses.

Dans le but de favoriser les contributions externes, nous avons laissé
en anglais la documentation du langage, et les commentaires du
compilateur. Vos rustines de traduction sont les bienvenues.

Bien sûr, nous attachons toujours autant d'importance à la
rétro-compatibilité, et nous sommes assurés que le code écrit pour les
versions précédentes du langage fonctionne toujours : pas de blague !
Pour des raisons diverses, vous pourriez même avoir besoin d'une
conversion de la nouvelle syntaxe vers l'ancienne, disponible grâce
à une nouvelle option du compilateur: utilisez la variable
d'environnement OCAML_LEX_NO_ROUNDTRIP à 1 pour désactiver toute
traduction, et OCAML_PERFIDE_ALBION (ou l'option de ligne de commande
`-perfide-albion` pour traduire vers l'anglais).

Les sources du compilateur sont disponibles à cette adresse :
Des versions binaires seront mises a votre disposition très

-- Gabriel Scherer et Jacques-Henri Jourdan pour l'équipe Chamelle.

Dear users,

The new version of the Java language includes lambdas . we
( designers of functional languages ​​) have won and there was ten years
yet we fight to understand programmers
" mainstream " the interests of higher-order functions ,
Now it is they who write tickets diaries
their glory.

To celebrate this change, and thus reduced the need to convince
the uneducated masses , we decided to reverse a decision
demagogic and costly in design Chamelle language : its
submission to the English language.

    type 'a tree = Leaf of ' a | Node of 'a tree *' a tree

    or rec feuille_existe p = tree
      shaft with filter
      | Leaf v - > p v
      | Node ( left, right) ->
          feuille_existe left p
          | | P feuille_existe right

    is a_une_feuille_paire =
      feuille_existe (fun n - > n mod 2 = 0)

It is with pleasure and pride that we celebrate the birth of Otto
Von Bismarck making you discover Chamelle number 5 , first
French version of your preferred language. We hope that
the use of " language of diplomacy " will allow communities
IT a more serene dialogue.

    $ Cat
    be united = 1
    ie 1 = United

    $ . / Ocamlc
    File " " , line 2 , characters 5-6:
    Warning 8: this pattern-matching is not exhaustive .
    This is an example of a value that is not filtered :

This language release has given us wings, and the first
Chamelle output number 5 contains a number of
promising features and various improvements .

In order to encourage external contributions , we left
English language documentation , and comments
compiler . Your translation patches are welcome.

Of course, we always attach much importance to the
backward compatibility , and we are assured that the code written for
previous versions of the language always works no joke !
For various reasons , you might even need a
conversion of the new to the old syntax , available through
a new compiler option : use the variable
environmental OCAML_LEX_NO_ROUNDTRIP to 1 to disable all
translation and OCAML_PERFIDE_ALBION (or command line option
`-perfide-albion` to translate into English ) .

The sources of the compiler are available at this address:
Binary versions will be at your disposal very

-- Gabriel Scherer and Jacques-Henri Jourdan for Chamelle team.

React 1.0.0


Daniel Bünzli announced:
I'd like to announce the release of React 1.0.0 which should be
available shortly in opam. 

React provides declarative events and signals for functional reactive
programming (FRP).

Home page:
API Documentation:

This is an incompatible release. Here are the main changes:

1. Exposes update steps (formerly called update cycles) in the
   API. This allows to perform transaction-like, semantically
   simultaneous, *primitive* signal updates and event occurences. It
   can make the reactive engine both more convenient and efficient for
   certain use cases.

2. To avoid leaks when weak arrays are not (i.e. JavaScript), some
   form of manual memory management can now be performed by using the
   new `strong` optional parameter of {S,E}.stop on the leaves of your
   reactive system.
3. S.switch no longer requires a bootstrapping argument. As a result
   S.bind is now trivially definable and is provided by the
   module. Consult the release notes for an equation to migrate your

Other details are in the release notes:
Daniel later added:
> As a result S.bind is now trivially definable

In fact it's so trivial that I managed to get it wrong (signals can't be
compared structurally, it may raise). I'll do a bug fix release in a few
days but meanwhile you can pin the github repo:

opam pin react

OCaml Engineers and Scientists at CEA, Software Security Labs (Paris Saclay, France)


Julien Signoles announced:
The CEA' Software Security Laboratory is opening positions for OCaml
engineers and scientists at Paris Saclay, France.

## Engineer & Scientist.
### Research and develop the next-generation of software verification

The Software Security Laboratory - LSL - has an ambitious goal: enable
developers and validation experts to design high-confidence software. We
believe that programs should be as reliable as mathematical truths.

Within CEA, LSL is dedicated to inventing the best possible means to
conduct software verification. We craft methods and tools that leverage
exciting, cutting-edge formal methods to ensure that industrial code can
comply with the highest standards. And in doing so, we get to interact
with the most creative people in academia and the industry.

Our organizational structure is very simple: those who pioneer
scientific innovations are the same ones who implement them. We are
a dynamic twenty-person laboratory, and your work will have a direct and
visible impact on the state of formal verification.

Our brand-new offices are located in the heart of Campus Paris Saclay,
in the largest European cluster of public and private research.

#### You

You dream of devising the next breakthrough in code analysis and to see
it through low-level implementation details. You read research papers
with passion, but you are fully aware that a toy prototype is quite
different from a hardened tool. You understand that what stands between
both is a series of complex implementation problems. And that's great,
because it means getting your hands dirty and confronting your tools to
challenging real-life use cases.

You enjoy being a constructive member of a team of talented and
dedicated people; you are extremely reliable and the nightly builds will
prove it every time. Last week's bleeding-edge release of obscure
packages is not really your thing. You want the source code, you want
scalability, and you want results.

If this sounds like you, we have a job for you.

#### Role

We need you to help us develop the Frama-C platform, by improving the
current analyses and designing complementary approaches. You will
contribute to growing the community of users, handling feedback and
helping real people solve real problems.

You will take an active part in research activities and industrial
partnerships, alongside other members of the laboratory. This can
include writing proposals, managing projects, publishing papers, and
attending scientific and technical events worldwide.

#### Requirements

- Background in formal methods, and programming languages.
- Experience with significant OCaml development.
- Experience with software engineering practices: source code management
  and reviews, continuous integration, and bug-tracking.
- Self-organized, with an ability to prioritize effectively.
- Team-minded - you know when to let someone else take the lead.

#### Pluses

- Strong proficiency in foreign languages.
- Experience with writing scientific papers and technical reports.
- Understanding of C or C++ semantics.
- Knowledge in the fields of cybersecurity, concurrency, or
  floating-point arithmetics.
- Administration of Linux environments and software development tools.
- Design of Graphical User Interfaces.
- Hands-on experience with formal verification tools: Coq, PVS, Why3,

#### Applying

If you're interested in joining LSL, send us an email to share what
inspires you, and why you think you are perfect for the team. Send it
along with a resume at

IOCaml 0.4


Andy Ray announced:
IOCaml provides an OCaml REPL in a webbrowser.  Version 0.4 frees us
from the tyranny of Python and provides an OCaml based webserver.  Put
another way you no longer need IPython installed at all.

The project is split into 3 opam packages;

* iocaml-kernel ( - byte code OCaml kernel
* iocamljs-kernel ( - javascript
OCaml kernel(s)
* iocaml ( - iocaml webserver

In general from a 4.01.0 compiler

$ opam install iocaml

should get everything installed.  OS requirements are libssl-dev and
libzmq3-dev (possibly some others as well, let me know and I'll add
them to the project pages).  Chrome, Firefox and Safari have been

To run iocaml;

$ iocaml


$ iocaml path/to/dir

To bring up the dashboard interface.  Or

$ iocaml notebook.ipynb

To directly load a notebook.

Use the "-js <kernel>" option to load a javascript based ocaml kernel.

$ iocaml -js min [...]

will load a minimal javascript ocaml REPL while

$ iocaml -js full [...]

will load a REPL with the js_of_ocaml and lwt libraries including
syntax extensions included.

For those brave souls you can try

$ iocaml -js min -serve-jslibs [...]

and have a play with #use "topfind" / #require.  Its probably worth
mentioning that the various "-serve" options allow the browser access
to your file system so don't run it on a public network without due
Anil Madhavapeddy then added:
A little tip for MacOS X users trying to get the Homebrew dependencies
is that zmq3 is available via the 'versions' tap.  You need to:

$ brew tap homebrew/versions
$ brew install zeromq32
$ brew link zeromq32

This will get you a version of ZeroMQ that satisfies the OPAM
library needs for the rest of IOCaml. 
Andy also added:
You can now try iocamljs online.

There's no way to save your work at the moment unfortunately.

Second CFP: Higher-order, Typed, Inferred, Strict: ML Family Workshop


oleg announced:
Higher-order, Typed, Inferred, Strict: ACM SIGPLAN ML Family Workshop
Thursday September 4, 2014, Gothenburg, Sweden
(immediately following ICFP and preceding OCaml Users and Developers Workshop)

Call For Papers

News: Post-proceedings will be published in EPTCS

ML is a very large family of programming languages that includes Standard ML,
OCaml, F#, SML#, Manticore, MetaOCaml, JoCaml, Alice ML, Dependent ML, Flow
Caml, and many others. All ML languages, beside the great deal of syntax, share
several fundamental traits. They are all higher-order, strict, mostly pure, and
typed, with algebraic and other data types. Their type systems inherit from
Hindley-Milner. The development of these languages has inspired a significant
amount of computer science research and influenced a number of programming
languages, including Haskell, Scala and Clojure, as well as Rust, ATS and many

ML workshops have been held in affiliation with ICFP continuously since 2005.
This workshop specifically aims to recognize the entire extended ML family and
to provide the forum to present and discuss common issues, both practical
(compilation techniques, implementations of concurrency and parallelism,
programming for the Web) and theoretical (fancy types, module systems,
metaprogramming). The scope of the workshop includes all aspects of the design,
semantics, theory, application, implementation, and teaching of the members of
the ML family. We also encourage presentations from related languages (such as
Scala, Rust, Nemerle, ATS, etc.), to exchange experience of further developing
ML ideas.

The ML family workshop will be held in close coordination with the OCaml Users
and Developers Workshop.


Since 2010, the ML workshop has adopted an informal model. Presentations are
selected from submitted abstracts. There are no published proceedings, so any
contributions may be submitted for publication elsewhere. We hope that this
format encourages the presentation of exciting (if unpolished) research and
deliver a lively workshop atmosphere.

Each presentation should take 20-25 minutes, except demos, which should take
10-15 minutes. The exact time will be decided based on the number of accepted
submissions. The presentations will likely be recorded.

Post-conference proceedings

The post-proceedings of selected papers from the ML Family and the
OCaml Users and Developers workshops will be published in the 
Electronic Proceedings in Theoretical Computer Science (EPTCS). The
Program Committee shall invite interested authors of selected
presentations to expand their abstract for inclusion in the
proceedings.  The submissions are to be reviewed according to the
EPTCS standards.

Coordination with the OCaml Users and Developers Workshop

The OCaml workshop is seen as more practical and is dedicated in significant
part to the OCaml community building and the evolution of the OCaml system. In
contrast, the ML family workshop is not focused on any language in particular,
is more research oriented, and deals with general issues of the ML-style
programming and type systems. Yet there is an overlap, which we are keen to
explore in various ways. The authors who feel their submission fits both
workshops are encouraged to mention it at submission time or contact the
Program Chairs.


We acknowledge the whole breadth of the ML family and aim to include languages
that are closely related (although not by blood), such as Rust, ATS, Scala,
Typed Clojure. Those languages have implemented and investigated run-time and
type system choices that may be worth considering for OCaml, F# and other ML
languages. We also hope that the exposure to the state of the art ML might
favorably influence those related languages. Specifically, we seek research
presentations on topics including but not limited to

  * Design: concurrency, distribution and mobility, programming for the web and
    embedded systems, handling semi-structured data, facilitating interactive
    programming, higher forms of polymorphism, generic programming, objects
  * Implementation: compilation techniques, interpreters, type checkers,
    partial evaluators, runtime systems, garbage collectors, etc.
  * Type systems: fancy types, inference, effects, overloading, modules,
    contracts, specifications and assertions, dynamic typing, error reporting,
  * Applications: case studies, experience reports, pearls, etc.
  * Environments: libraries, tools, editors, debuggers, cross-language
    interoperability, functional data structures, etc.
  * Education: ML and ML-like languages in college or high-school, in general
    or computer science curriculum.

Four kinds of submissions will be accepted: Informed Positions, Research
Presentations, Experience Reports and Demos.

  * Informed Positions: A justified argument for or against a language feature.
    The argument must be substantiated, either theoretically (e.g., by a
    demonstration of (un)soundness, an inference algorithm, a complexity
    analysis), empirically or by a substantial experience. Personal experience
    is accepted as justification so long as it is extensive and illustrated
    with concrete examples.
  * Research Presentations: Research presentations should describe new ideas,
    experimental results, or significant advances in ML-related projects. We
    especially encourage presentations that describe work in progress, that
    outline a future research agenda, or that encourage lively discussion.
    These presentations should be structured in a way which can be, at least in
    part, of interest to (advanced) users.
  * Experience Reports: Users are invited to submit Experience Reports about
    their use of ML and related languages. These presentations do not need to
    contain original research but they should tell an interesting story to
    researchers or other advanced users, such as an innovative or unexpected
    use of advanced features or a description of the challenges they are facing
    or attempting to solve.
  * Demos: Live demonstrations or short tutorials should show new developments,
    interesting prototypes, or work in progress, in the form of tools,
    libraries, or applications built on or related to ML. (You will need to
    provide all the hardware and software required for your demo; the workshop
    organizers are only able to provide a projector.)

Important dates

Monday May 19 (any time zone):   Abstract submission
Monday June 30:                  Author notification
Thursday September 4, 2014:      ML Family Workshop


Submissions should be at most two pages, in PDF format, and printable on US
Letter or A4 sized paper. A submission should have a synopsis (2-3 lines) and a
body between 1 and 2 pages, in one- or two-column layout. The synopsis should
be suitable for inclusion in the workshop program.

Submissions must be uploaded to the workshop submission website before the
submission deadline (Monday May 19, 2014).
For any question concerning the scope of the workshop or the submission
process, please contact the program chair.

Program Committee

Kenichi Asai             Ochanomizu University, Japan
Matthew Fluet            Rochester Institute of Technology, USA
Jacques Garrigue         Nagoya University, Japan
Dave Herman              Mozilla, USA
Stefan Holdermans        Vector Fabrics, Netherlands
Oleg Kiselyov (Chair)    Monterey, CA, USA
Keiko Nakata             Tallinn University of Technology, Estonia
Didier Remy              INRIA Paris-Rocquencourt, France
Zhong Shao               Yale University, USA
Hongwei Xi               Boston University, USA

Hashset implementation


Johan Mazel asked and Tianyi Cui replied:
> I want to use hashset in OCaml.
> I found these two implemtetations:
> *
> *
> Is there anything else available somewhere ?

If you're willing to consider an alternative standard library, you can
try Core ( It includes hash set
and many more goodies.
Simon Cruanes also replied:
Hi, the standard Hashtbl can be used as a basic hashset (using unit as
values and the set elements as keys) for simple uses. It won't provide
intersection or union, though.

Core Suite 111.08.00


Ben Millwood announced:
I am delighted to announce the 111.08.00 release of the Core suite.

The following packages were upgraded:

- async_extra
- async_kernel
- async_ssl
- async_unix
- core
- core_kernel
- enumerate
- jenga
- ocaml_plugin
- pa_test
- re2

This time we are including another new package:

- bignum, a Core-flavoured wrapper around arbitrary-precision rational
numbers provided by the zarith library.

Heads up, though: in preparation for the public release of bignum, we
made a few changes and improvements to the library, but they weren't
completed in time and weren't essential enough to hold up the release
for them. Next public release, bignum will have an improved rounding
API, fewer dependencies, and a better bin_prot encoding.

Files and documentation for this release are available on our website
and all packages are in opam:

Here is the list of changes for this version:

## async_extra

- Added `Log.Message.add_tags`, which extends a message with a list of
key-value pairs.

val add_tags : t -> (string * string) list -> t

## async_kernel

- Changed low-level error messages to use `Sexp.to_string_hum` rather
than `to_string_mach`.

## async_ssl

- Improved the propagation of SSL errors to the caller.

## async_unix

- Added `Sys.when_file_changes : string -> Time.t Pipe.Reader.t`.
- Added ` ()` to some error messages.

## core

- Improved `Command` to print a good error message if command-line
parsing raises.

`Command`'s `Exn.handle_uncaught` now protects the phase of parsing
command-line arguments in addition to protecting the phase of
running the `main` function as it did already.

## core_kernel

- Added `Hashtbl.for_all` and `for_alli`.
- Added `Float.to_padded_compact_string` for converting a floating point
number to a lossy, compact, human-readable representation.

E.g., `1_000_001.00` becomes `"1m "`.

- Tweaked the form of the definition of `Blang.Stable.V1`.

Removed a `type t_` that is not necessary now that we can use `nonrec`
without triggering spurious warnings.

## enumerate

- Restricted the signature of the `all` value generated by
`with enumerate`.

Now, in:

type t = [ `Foo | ... ] with enumerate

the type of `all` will be `t list`, instead of `[> t] list`.

When taking unions of polymorphic variant types, inserted the
appropriate coercions.

## jenga

- Fix a hang.

Jenga could reach a state with a non-zero todo-count, but have no
jobs actually running, and then hang in this state forever. The hang
would be evident from a progress line with not all targets built and
with `j=0+0` such as:

todo: 17 (100406 / 100423) j=0+0 con=149956 act=3303, finish at: 16:20

## ocaml_plugin

- Use `ocamldep` to generate the dependencies of an `.ml` file, if

Added a function to find the dependencies of a module, but did not
change the existing behavior and interface of the library if one
does not choose to use this functionality.

## pa_test

- Made it possible to use `<:test_eq< >>` and friends in `Core_kernel`.

Removed the dependency of the code generated by `pa_test` on
`Core_kernel`, so `pa_test` can be used there.

## re2

- Upgraded to upstream library version 20140304. 

Added options `Dot_nl` and `Never_capture`.

Experiment: OCaml patch review on


Jeremy Yallop continued this old thread:
We now also have a GitHub mirror of the OCaml manual:

Could we please extend the experiment to include pull requests to the
manual as well as to the main source tree?  There have been a few pull
requests recently that will need corresponding updates to the
documentation.  It'd be useful to give source and documentation
changes the same visibility.
Jacques-Pascal Deplaix then said:
I'm a little skeptical for the name of this repository. I think «
ocamldoc » should be reserved to the tool.
Maybe « documentation » or « manual » would be better.
Gabriel Scherer also replied:
Sure, let's consider this repository is also part of the PR experiment.

Jacques-Pascal: that's a good remark, but to be fair the names comes
from the original SVN repository for the ocaml manual, itself named
"ocamldoc". I agree "ocaml-manual" would be a better name.
Anil Madhavapeddy then said:
I've renamed it to ocaml-manual.  GitHub maintains a redirection, so the
scripts can continue to push to the old name.

Other OCaml News

From the ocamlcore planet blog:
Thanks to Alp Mestan, we now include in the OCaml Weekly News the links to the
recent posts from the ocamlcore planet blog at

Grepping the source of every OCaml package in OPAM:

Generic mapping and folding in OCaml:

Full Time: Platform Engineer at Gawker Media in New York, NY:

React 1.0.0:

Old cwn

If you happen to miss a CWN, you can send me a message and I'll mail it to you, or go take a look at the archive or the RSS feed of the archives.

If you also wish to receive it every week by mail, you may subscribe online.

Alan Schmitt