Draft tutorials on Modules, Functors and Libraries

Sharing some feedback here for Libraries With Dune · OCaml Documentation

  1. There’s no need for touch mixtli.opam as dune will generate the opam file
  2. I’d suggest not to introduce a new domain (clouds and their names) when teaching dune concepts, it will unnecessarily distract from the material. We can stick to simple concepts that everyone is familiar with, like say math (addition, subtraction, etc.: let add x y = x + y and so on)
  3. There’s no pressing need to introduce public_name for the executable stanza, at the beginner level. We can just say that the executable name is the same as its main module
  4. We should mention the most important reason for having wrapper modules for libraries, to avoid module name clashes, i.e. namespacing

Otherwise it looks good and is much needed.

3 Likes