Translate [%ocaml.extension_constructor <path>] to the
runtime-representation of the extension constructor denoted by
<path>. This allows one to get the extension constructor without
having to create a dummy value.
From comments in typedtree.mli:
When introduced in 2000, this [type] enabled a more efficient code
generation for optional arguments. However, today the information is
redundant as labels are passed to [transl_apply] too. Could be cleaned
up.
- float
- int32
- int64
- nativeint
Not for int because the comparison is done directly on the untagged version.
Useful mainly for floats since they can be stored unboxed in records or arrays.
Adding [@unboxed] (resp [@untagged]) on a primitive argument means
that the argument must passed unboxed (resp untagged) to the external
function. Adding [@unboxed] (resp [@untagged]) on the result means
that the external function returns its result unboxed (resp untagged).
The unboxing (resp untagging) method is derived from the type.
Currently unboxing is suported for: float, int32, int64 and nativeint.
Untagging is supported for int.
This patch also increases the cm{i,o,a,x,xa} magic numbers as the type
Primitive.description is changed.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16382 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
(Peter Zotov and Jake Donham,
review by Gabriel Scherer and Jacques-Henri Jourdan)
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15830 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
This should cover all places involving filenames in the compiler.
There are a few more paths still using Latin-1 in other ways,
e.g. in ocamldoc.
From: Peter Zotov <whitequark@whitequark.org>
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15727 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
This commit introduces a new syntax for index operators.
Six core parenthesis operator are added:
.(), .[], .{}, .{,}, .{,,}, .{,..,}.
The .{,}/.{,,}/.{,,,} operators are defined for compatibility with the Bigarray syntax extension.
Each core index operator is available in a access/assignement versions. For instance, .() is declined in
* .() : index operator
* .()<- : indexed assignment operator
The general syntax for these index operators as implemented in the parser is index_operator::= index_operator_core [<-]
From: octachron <octa@polychoron.fr>
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15660 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
It allows to have non-standard limits for non-standard runtime.
ie: js_of_ocaml use 32bits integer, and can handle
string much bigger than 16Mo.
From: Hugo Heuzard <hugo.heuzard@gmail.com>
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15588 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
This will enable type-directed optimizations during translation of
module coercions.
WARNING: this breaks Typedtree representation, magic number will have to
be adjusted.
From: Frederic Bour <frederic.bour@lakaban.net>
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15582 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
and unshared default clauses in the presence of many (>= 32) non-matched
constructors.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15570 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02