Previous week Up Next week


Here is the latest OCaml Weekly News, for the week of December 08 to 15, 2015.

  1. Next OUPS meetup, 16th of December 2015
  2. webmachine.0.3.0
  3. Do you use a debugger with OCaml? If not, why not?
  4. Astring 0.8.0

Next OUPS meetup, 16th of December 2015


Louis Roché announced:
The next OUPS meetup will take place on the 16th of December 7pm, at
the school 42 (96 Boulevard Bessières). We will have a few talks, followed by

The talks will be the following:

- David Giron - Présentation de la pédagogie de 42 appliqué à OCaml
- Francois Berenger: Le logiciel Daft (Distributed file transfer application in user space)
- Benjamin Canou: Présentation du MOOC OCaml

Note that we are always in demand of talk *proposals* for future

To register, or for more information, go here:
(Registration is recommended, so that we can order enough food.)

Videos from previous sessions are available online:

École 42
96 Boulevard Bessières
75017 Paris
The meetup organizers.



Spiros Eliopoulos announced:
I wanted to bring to your attention the latest release of webmachine, weighing
in at version 0.3.0. This release includes bugfixes and a few major API
changes. Most notably is the way that users must create redirect responses.
There was an ambiguity in the state machine when dealing with POST requests
and redirects. To allow both a Location header to be set for a POST response
and redirection, users should use the redirect function on the Rd record like

Webmachine.continue body (Rd.redirect "/path/to/resource" rd)

Setting the Location header for a POST response remains unchanged.

In addition, the is_authorized handler now deviates slightly from the original
Erlang implementation. The return type for that function now looks like this:

type auth =
[ `Authorized (* The request is authorized to proceed *)
| `Basic of string (* Basic authentication challenge[0] for the given realm *)
| `Redirect of Uri.t (* Use the given URI to authenticate *)

You can see the full list of changes in the release notes:

As always, issues and pull requests are welcomed.

-Spiros E.


Do you use a debugger with OCaml? If not, why not?


A long time ago, John Whitington asked; Richard Jones now replied:
> So, I ask: What do you use for debugging small and large OCaml programs? If
> not a debugger, why not? What problems prevent it? How does your debugging
> process differ when writing OCaml compared with other languages you use?

No one seems to have mentioned gdb in this thread.  I use it on OCaml
programs quite often.  It's especially useful for finding bugs in my C
libraries :-)  In fact I missed gdb when we ported the tools to aarch64
because stack traces didn't work properly for quite a while [now fixed].

Astring 0.8.0


Daniel Bünzli announced:
I grew tired of the String module. Here's the first release of astring,
described by:

  Astring exposes an alternative String module for OCaml. This module tries to 
  balance minimality and expressiveness for basic, index-free, string processing 
  and provides types and functions for substrings, string sets and string maps.

  Remaining compatible with the OCaml String module is a non-goal. The 
  String module exposed by Astring has exception safe functions, removes 
  deprecated and rarely used functions, alters some signatures and names, adds
  a few missing functions and fully exploits OCaml's newfound string immutability.

  Astring depends only on the OCaml standard library. It is distributed 
  under the BSD3 license.

Feedback on the API is welcome, it could still slightly change before
stabilizing on a 1.0.0 release.

API docs:

My thanks to David Kaloper for a heated and useful discussion about the API.
Remaining misconceptions are mine.

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