OlivierNicole / ocaml

The core OCaml system: compilers, runtime system, base libraries

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

About the macros branch

macros_unstable is merged into macros on a regular basis, once a set of changes has been applied and the tests run.

Overview

This is an experimental implementation of OCaml macros, originally designed by Leo White and Jeremy Yallop:

You can find a summary of the current progress here:

This branch is based on version 4.04 of OCaml.

Installation

Installation instruction are the same as for the standard OCaml distribution. You can find a few examples of what is possible in the links above. You can also take a look at the testsuite/tests/macros/ directory.

Installing OPAM packages

Most packages should compile fine, but causes that may break your packages include:

  • a use of the reserved words static or macro as an identifier;

  • a use of $ as a regular operator.

If you need to install Camlp4, you will have to pin it to this repository. Please be aware that this version of Camlp4 is only provided for backward-compatibility and can only generate "pre-macro" OCaml, i.e. it cannot generate any of the macro constructs.

Contributing

You are very welcome to try out macros. Please do report any bugs or inconvenience by opening an issue on this repo.

Pull requests

Found a bug and know how to fix it? We certainly appreciate pull requests. If you plan on making big changes, please file an issue first to discuss why theses changes are needed.

Limitations / To Do

Things to be done sorted by descending priority:

  • Support for declaring static type extensions (including static exceptions)

  • Solve issues of static linking and side effects, possibly by banning the static keyword

  • Upgrade of ocamldep to take into account the modifications in dependency trees because of the above

  • Fix GADT matching in quotations

List of Contributors

The implementation of macros is an OCaml Labs research project.

Main collaborators:

  • Olivier Nicole, main developer

  • Leo White, quoting library, original design and supervision

  • Jeremy Yallop, original design and supervision

  • Oleg Kiselyov, developer of BER MetaOCaml, from which macros are inspired

  • Gemma Gordon, project manager

About

The core OCaml system: compilers, runtime system, base libraries

License:Other


Languages

Language:OCaml 76.7%Language:C 15.1%Language:Makefile 2.3%Language:Emacs Lisp 1.8%Language:Assembly 1.4%Language:Standard ML 1.4%Language:Shell 0.5%Language:TeX 0.4%Language:C++ 0.2%Language:Perl 0.1%Language:Awk 0.1%Language:CSS 0.0%Language:Forth 0.0%Language:C# 0.0%