summaryrefslogtreecommitdiffstats
path: root/stdlib/obj.ml
blob: b4c131ad4eaec2d04cef62b92cd3fea4158d235e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
(* Operations on internal representations of values *)

type t

external repr : 'a -> t = "%identity"
external magic : 'a -> 'b = "%identity"
external is_block : t -> bool = "obj_is_block"
external tag : t -> int = "%tagof"
external size : t -> int = "%array_length"
external field : t -> int -> t = "%array_get"
external set_field : t -> int -> t -> unit = "%array_set"
external new_block : int -> int -> t = "obj_block"
external update : t -> t -> unit = "%update"