diff options
author | Gabriel Scherer <gabriel.scherer@gmail.com> | 2014-12-13 22:13:37 +0000 |
---|---|---|
committer | Gabriel Scherer <gabriel.scherer@gmail.com> | 2014-12-13 22:13:37 +0000 |
commit | 4a80e9da1114cb1e351a8c61cab6f04e6c1ba927 (patch) | |
tree | 5dea9eb4607ba607678186f43d26f32c58e43830 /boot | |
parent | 7e47735db8bbc4e54e1653d218cc1e6c90813ba4 (diff) |
Simplify the definition of custom .{} operators
This commits modify the Bigarray syntax extension in order to facilitate the use of custom .{} operators. The compatibility with the existing Bigarray syntax has been preserved as much as possible. However, this commit will break code which use the Bigarray .{}
syntax without opening the Bigarray module first!
Like the previous commit, this commit modifies the parser to desugar bigarray1.{index} to ( .{} ) bigarray1 index. Following the bigarray syntax, the index operator used
in the desugaring changes if the index is a n-tuple:
1-tuple => .{}
2-tuple => .{,}
3-tuple => .{,,}
4 and more tuples => .{,..,}
The bigarray modules has been modified to use this new index operators. Note that this means that these index operators are not anymore accessible without opening the bigarray module.
From: octachron <octa@polychoron.fr>
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15662 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'boot')
-rwxr-xr-x | boot/ocamlc | bin | 1733481 -> 1733459 bytes |
-rwxr-xr-x | boot/ocamldep | bin | 535509 -> 535487 bytes |
2 files changed, 0 insertions, 0 deletions
diff --git a/boot/ocamlc b/boot/ocamlc Binary files differindex 7607ce4f7..6a2dc3590 100755 --- a/boot/ocamlc +++ b/boot/ocamlc diff --git a/boot/ocamldep b/boot/ocamldep Binary files differindex e62f25bcf..cf7beac25 100755 --- a/boot/ocamldep +++ b/boot/ocamldep |