summaryrefslogtreecommitdiff
path: root/bytecomp/bytesections.ml
diff options
context:
space:
mode:
authorXavier Leroy <xavier.leroy@inria.fr>2004-02-22 15:07:51 +0000
committerXavier Leroy <xavier.leroy@inria.fr>2004-02-22 15:07:51 +0000
commite2b313a0556afc6c9d66400864aaea4347a0490f (patch)
treead71cf622f09f91b8197b8e40374cb9a04e1bcf3 /bytecomp/bytesections.ml
parent96b512c1da80960bde15ec04bd30cf2c93883e82 (diff)
downloadocaml-e2b313a0556afc6c9d66400864aaea4347a0490f.tar.gz
Rendre ocamlc -output-obj compatible avec Dynlink et le toplevel
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@6130 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'bytecomp/bytesections.ml')
-rw-r--r--bytecomp/bytesections.ml8
1 files changed, 7 insertions, 1 deletions
diff --git a/bytecomp/bytesections.ml b/bytecomp/bytesections.ml
index a9750cff49..16eaf23776 100644
--- a/bytecomp/bytesections.ml
+++ b/bytecomp/bytesections.ml
@@ -80,12 +80,18 @@ let seek_section ic name =
(* Return the contents of a section, as a string *)
-let read_section ic name =
+let read_section_string ic name =
let len = seek_section ic name in
let res = String.create len in
really_input ic res 0 len;
res
+(* Return the contents of a section, as marshalled data *)
+
+let read_section_struct ic name =
+ ignore (seek_section ic name);
+ input_value ic
+
(* Return the position of the beginning of the first section *)
let pos_first_section ic =