New files, initially from ../srfi/ but heavily modified.
[bpt/guile.git] / libguile / srfi-4.h
CommitLineData
f8579182
MV
1#ifndef SCM_SRFI_4_H
2#define SCM_SRFI_4_H
3/* srfi-4.c --- Homogeneous numeric vector datatypes.
4 *
5 * Copyright (C) 2001, 2004 Free Software Foundation, Inc.
6 *
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Lesser General Public
9 * License as published by the Free Software Foundation; either
10 * version 2.1 of the License, or (at your option) any later version.
11 *
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Lesser General Public License for more details.
16 *
17 * You should have received a copy of the GNU Lesser General Public
18 * License along with this library; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 */
21\f
22
23#include "libguile/__scm.h"
24
25SCM_API SCM scm_u8vector_p (SCM obj);
26SCM_API SCM scm_make_u8vector (SCM n, SCM fill);
27SCM_API SCM scm_u8vector (SCM l);
28SCM_API SCM scm_u8vector_length (SCM uvec);
29SCM_API SCM scm_u8vector_ref (SCM uvec, SCM index);
30SCM_API SCM scm_u8vector_set_x (SCM uvec, SCM index, SCM value);
31SCM_API SCM scm_u8vector_to_list (SCM uvec);
32SCM_API SCM scm_list_to_u8vector (SCM l);
33
34SCM_API SCM scm_s8vector_p (SCM obj);
35SCM_API SCM scm_make_s8vector (SCM n, SCM fill);
36SCM_API SCM scm_s8vector (SCM l);
37SCM_API SCM scm_s8vector_length (SCM uvec);
38SCM_API SCM scm_s8vector_ref (SCM uvec, SCM index);
39SCM_API SCM scm_s8vector_set_x (SCM uvec, SCM index, SCM value);
40SCM_API SCM scm_s8vector_to_list (SCM uvec);
41SCM_API SCM scm_list_to_s8vector (SCM l);
42
43SCM_API SCM scm_u16vector_p (SCM obj);
44SCM_API SCM scm_make_u16vector (SCM n, SCM fill);
45SCM_API SCM scm_u16vector (SCM l);
46SCM_API SCM scm_u16vector_length (SCM uvec);
47SCM_API SCM scm_u16vector_ref (SCM uvec, SCM index);
48SCM_API SCM scm_u16vector_set_x (SCM uvec, SCM index, SCM value);
49SCM_API SCM scm_u16vector_to_list (SCM uvec);
50SCM_API SCM scm_list_to_u16vector (SCM l);
51
52SCM_API SCM scm_s16vector_p (SCM obj);
53SCM_API SCM scm_make_s16vector (SCM n, SCM fill);
54SCM_API SCM scm_s16vector (SCM l);
55SCM_API SCM scm_s16vector_length (SCM uvec);
56SCM_API SCM scm_s16vector_ref (SCM uvec, SCM index);
57SCM_API SCM scm_s16vector_set_x (SCM uvec, SCM index, SCM value);
58SCM_API SCM scm_s16vector_to_list (SCM uvec);
59SCM_API SCM scm_list_to_s16vector (SCM l);
60
61SCM_API SCM scm_u32vector_p (SCM obj);
62SCM_API SCM scm_make_u32vector (SCM n, SCM fill);
63SCM_API SCM scm_u32vector (SCM l);
64SCM_API SCM scm_u32vector_length (SCM uvec);
65SCM_API SCM scm_u32vector_ref (SCM uvec, SCM index);
66SCM_API SCM scm_u32vector_set_x (SCM uvec, SCM index, SCM value);
67SCM_API SCM scm_u32vector_to_list (SCM uvec);
68SCM_API SCM scm_list_to_u32vector (SCM l);
69
70SCM_API SCM scm_s32vector_p (SCM obj);
71SCM_API SCM scm_make_s32vector (SCM n, SCM fill);
72SCM_API SCM scm_s32vector (SCM l);
73SCM_API SCM scm_s32vector_length (SCM uvec);
74SCM_API SCM scm_s32vector_ref (SCM uvec, SCM index);
75SCM_API SCM scm_s32vector_set_x (SCM uvec, SCM index, SCM value);
76SCM_API SCM scm_s32vector_to_list (SCM uvec);
77SCM_API SCM scm_list_to_s32vector (SCM l);
78
79SCM_API SCM scm_u64vector_p (SCM obj);
80SCM_API SCM scm_make_u64vector (SCM n, SCM fill);
81SCM_API SCM scm_u64vector (SCM l);
82SCM_API SCM scm_u64vector_length (SCM uvec);
83SCM_API SCM scm_u64vector_ref (SCM uvec, SCM index);
84SCM_API SCM scm_u64vector_set_x (SCM uvec, SCM index, SCM value);
85SCM_API SCM scm_u64vector_to_list (SCM uvec);
86SCM_API SCM scm_list_to_u64vector (SCM l);
87
88SCM_API SCM scm_s64vector_p (SCM obj);
89SCM_API SCM scm_make_s64vector (SCM n, SCM fill);
90SCM_API SCM scm_s64vector (SCM l);
91SCM_API SCM scm_s64vector_length (SCM uvec);
92SCM_API SCM scm_s64vector_ref (SCM uvec, SCM index);
93SCM_API SCM scm_s64vector_set_x (SCM uvec, SCM index, SCM value);
94SCM_API SCM scm_s64vector_to_list (SCM uvec);
95SCM_API SCM scm_list_to_s64vector (SCM l);
96
97SCM_API SCM scm_f32vector_p (SCM obj);
98SCM_API SCM scm_make_f32vector (SCM n, SCM fill);
99SCM_API SCM scm_f32vector (SCM l);
100SCM_API SCM scm_f32vector_length (SCM uvec);
101SCM_API SCM scm_f32vector_ref (SCM uvec, SCM index);
102SCM_API SCM scm_f32vector_set_x (SCM uvec, SCM index, SCM value);
103SCM_API SCM scm_f32vector_to_list (SCM uvec);
104SCM_API SCM scm_list_to_f32vector (SCM l);
105
106SCM_API SCM scm_f64vector_p (SCM obj);
107SCM_API SCM scm_make_f64vector (SCM n, SCM fill);
108SCM_API SCM scm_f64vector (SCM l);
109SCM_API SCM scm_f64vector_length (SCM uvec);
110SCM_API SCM scm_f64vector_ref (SCM uvec, SCM index);
111SCM_API SCM scm_f64vector_set_x (SCM uvec, SCM index, SCM value);
112SCM_API SCM scm_f64vector_to_list (SCM uvec);
113SCM_API SCM scm_list_to_f64vector (SCM l);
114
115SCM_API SCM scm_i_read_homogenous_vector (SCM port, char pfx);
116
117SCM_API void scm_init_srfi_4 (void);
118
119#endif /* SCM_SRFI_4_H */