1995-08-09 08:06:35 -07:00
|
|
|
/***********************************************************************/
|
|
|
|
/* */
|
1996-04-30 07:53:58 -07:00
|
|
|
/* Objective Caml */
|
1995-08-09 08:06:35 -07:00
|
|
|
/* */
|
|
|
|
/* Xavier Leroy and Damien Doligez, INRIA Rocquencourt */
|
|
|
|
/* */
|
1996-04-30 07:53:58 -07:00
|
|
|
/* Copyright 1996 Institut National de Recherche en Informatique et */
|
1999-11-17 10:59:06 -08:00
|
|
|
/* en Automatique. All rights reserved. This file is distributed */
|
|
|
|
/* under the terms of the GNU Library General Public License. */
|
1995-08-09 08:06:35 -07:00
|
|
|
/* */
|
|
|
|
/***********************************************************************/
|
|
|
|
|
|
|
|
/* $Id$ */
|
|
|
|
|
1995-05-04 03:15:53 -07:00
|
|
|
#ifndef _alloc_
|
|
|
|
#define _alloc_
|
|
|
|
|
|
|
|
|
|
|
|
#include "misc.h"
|
|
|
|
#include "mlvalues.h"
|
|
|
|
|
1997-09-02 05:55:01 -07:00
|
|
|
value alloc (mlsize_t, tag_t);
|
1998-10-26 11:19:32 -08:00
|
|
|
value alloc_small (mlsize_t, tag_t);
|
1997-09-02 05:55:01 -07:00
|
|
|
value alloc_tuple (mlsize_t);
|
|
|
|
value alloc_string (mlsize_t);
|
|
|
|
value copy_string (char *);
|
|
|
|
value copy_string_array (char **);
|
|
|
|
value copy_double (double);
|
2000-02-11 04:03:31 -08:00
|
|
|
value copy_int32 (int32); /* defined in [ints.c] */
|
|
|
|
value copy_int64 (int64); /* defined in [ints.c] */
|
1997-09-02 05:55:01 -07:00
|
|
|
value alloc_array (value (*funct) (char *), char ** array);
|
1995-05-04 03:15:53 -07:00
|
|
|
|
2000-02-10 06:04:59 -08:00
|
|
|
typedef void (*final_fun)(value);
|
|
|
|
value alloc_final (mlsize_t /*size in words*/,
|
|
|
|
final_fun, /*finalization function*/
|
|
|
|
mlsize_t, /*resources consumed*/
|
|
|
|
mlsize_t /*max resources*/);
|
|
|
|
|
|
|
|
int convert_flag_list (value, int *);
|
1995-05-04 03:15:53 -07:00
|
|
|
|
|
|
|
#endif /* _alloc_ */
|