0 | |
Description: hid_t is now 64bit
|
1 | |
This is a temporary hack that really works only on 64-bit arches.
|
2 | |
A better fix is under way.
|
3 | |
Author: Thibaut Paumard <thibaut@debian.org>
|
|
0 |
Description: wrap 64-bit long hid_t into Yorick's "long" type
|
|
1 |
HDF5 has changed hid_t to now be always 64bit. There is no
|
|
2 |
64-bit-long type in Yorick on 32-bit architectures. On these
|
|
3 |
architectures, we keep a list of open ids and index them with the
|
|
4 |
32-bit long "long" type.
|
|
5 |
Author: Thibaut Paumard
|
4 | 6 |
Origin: vendor
|
|
7 |
Bug: https://github.com/frigaut/yorick-hdf5/issues/1
|
5 | 8 |
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=842817
|
6 | |
Forwarded: not-needed
|
7 | |
Last-Update: 2016-11-02
|
|
9 |
Last-Update: 2016-11-03
|
8 | 10 |
---
|
9 | 11 |
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
|
10 | 12 |
--- a/hdf5.c
|
11 | 13 |
+++ b/hdf5.c
|
12 | |
@@ -59,9 +59,9 @@
|
|
14 |
@@ -34,8 +34,107 @@
|
|
15 |
#include <stdlib.h> /* For EXIT_FAILURE, EXIT_SUCCESS */
|
|
16 |
#include "hdf5.h"
|
|
17 |
#include "ydata.h"
|
|
18 |
+#include "yapi.h"
|
|
19 |
#include "pstdlib.h"
|
|
20 |
|
|
21 |
+/* Make a new data type for hid_t */
|
|
22 |
+// Y_WRAP_HID_T should be defined whenever sizeof(long) < sizeof(hid_t).
|
|
23 |
+// User may force wrapping.
|
|
24 |
+#ifndef Y_WRAP_HID_T
|
|
25 |
+# if H5_SIZEOF_LONG < H5_SIZEOF_HID_T
|
|
26 |
+# define Y_WRAP_HID_T
|
|
27 |
+# endif
|
|
28 |
+#endif
|
|
29 |
+
|
|
30 |
+#ifndef Y_WRAP_HID_T
|
|
31 |
+// Y_WRAP_HID_T is not defined: hid_t can be represented immediately
|
|
32 |
+// as either int or long.
|
|
33 |
+# if H5_SIZEOF_HID_T <= H5_SIZEOF_INT
|
|
34 |
+# define ypush_hid_t ypush_int
|
|
35 |
+# define ygets_hid_t ygets_i
|
|
36 |
+# else
|
|
37 |
+# define ypush_hid_t ypush_long
|
|
38 |
+# define ygets_hid_t ygets_l
|
|
39 |
+# endif
|
|
40 |
+# define yfree_hid_t(hid) do {} while (0)
|
|
41 |
+
|
|
42 |
+#else
|
|
43 |
+// Y_WRAP_HID_T is defined: wrap hid_t into long. We will maintain a
|
|
44 |
+// list of hid_t values, the interpreter will only see long integer
|
|
45 |
+// references to this list.
|
|
46 |
+
|
|
47 |
+#define Y_H5_DEFAULT_SIZE 1024
|
|
48 |
+static struct {
|
|
49 |
+ hid_t * ids;
|
|
50 |
+ size_t n_allocated;
|
|
51 |
+ long last;
|
|
52 |
+} y_hids = {
|
|
53 |
+ .ids = 0,
|
|
54 |
+ .n_allocated = 0,
|
|
55 |
+ .last = -1,
|
|
56 |
+} ;
|
|
57 |
+
|
|
58 |
+void ypush_hid_t(hid_t hid) {
|
|
59 |
+ long yid=0;
|
|
60 |
+ if (hid <0) yid=-1;
|
|
61 |
+ else if (hid >0) {
|
|
62 |
+ if (y_hids.n_allocated == 0) {
|
|
63 |
+ y_hids.ids=malloc(Y_H5_DEFAULT_SIZE*sizeof(hid_t));
|
|
64 |
+ if (!(y_hids.ids)) y_error("Failed to allocate list of hids");
|
|
65 |
+ y_hids.n_allocated = Y_H5_DEFAULT_SIZE;
|
|
66 |
+ }
|
|
67 |
+ long cur;
|
|
68 |
+ long first_free=-1;
|
|
69 |
+ for (cur=0; cur<=y_hids.last; ++cur) {
|
|
70 |
+ if (y_hids.ids[cur] == hid) {
|
|
71 |
+ yid = cur+1; // because we map hid=0 to yid=0
|
|
72 |
+ break;
|
|
73 |
+ }
|
|
74 |
+ if (y_hids.ids[cur]==-1 && first_free==-1) first_free=cur;
|
|
75 |
+ }
|
|
76 |
+ if (yid==0) { // did not find matching id
|
|
77 |
+ if (first_free != -1) cur=first_free;
|
|
78 |
+ yid=cur+1;
|
|
79 |
+ if (yid<0) { // long int overflow
|
|
80 |
+ y_error("Pushed to many hids, please close some");
|
|
81 |
+ }
|
|
82 |
+ if (yid>y_hids.n_allocated) { // need to grow y_hids.ids
|
|
83 |
+ size_t n_allocated=2*y_hids.n_allocated;
|
|
84 |
+ hid_t * tmp=realloc(y_hids.ids, n_allocated*sizeof(hid_t));
|
|
85 |
+ if (!tmp) y_error("Failed to grow list of hids");
|
|
86 |
+ y_hids.ids=tmp;
|
|
87 |
+ y_hids.n_allocated=n_allocated;
|
|
88 |
+ }
|
|
89 |
+ y_hids.ids[cur]=hid;
|
|
90 |
+ if (cur > y_hids.last) y_hids.last=cur;
|
|
91 |
+ }
|
|
92 |
+ }
|
|
93 |
+ ypush_long(yid);
|
|
94 |
+}
|
|
95 |
+
|
|
96 |
+hid_t ygets_hid_t(int iarg) {
|
|
97 |
+ // receive hid_t from Yorick.
|
|
98 |
+ long yid=ygets_l(iarg);
|
|
99 |
+ if (yid<=0) return yid;
|
|
100 |
+ long cur=yid-1;
|
|
101 |
+ if (cur>y_hids.last) y_error("No such id. Was it closed already?");
|
|
102 |
+ return y_hids.ids[cur];
|
|
103 |
+}
|
|
104 |
+
|
|
105 |
+void yfree_hid_t(hid_t hid) {
|
|
106 |
+ long cur, i;
|
|
107 |
+ for (cur=0; cur<=y_hids.last; ++cur) {
|
|
108 |
+ if (y_hids.ids[cur] == hid) {
|
|
109 |
+ y_hids.ids[cur]=-1;
|
|
110 |
+ break;
|
|
111 |
+ }
|
|
112 |
+ }
|
|
113 |
+ while (y_hids.last>=0 && y_hids.ids[y_hids.last]==-1) --y_hids.last;
|
|
114 |
+}
|
|
115 |
+#endif
|
|
116 |
+
|
|
117 |
+/* Done wrapping 64-bit hids into 32-bit yids */
|
|
118 |
+
|
|
119 |
void Y__H5Eon() { H5Eset_auto((H5E_auto_t)H5Eprint,stderr); }
|
|
120 |
void Y__H5Eoff() { H5Eset_auto(NULL,NULL); }
|
|
121 |
void Y__H5close() { H5close(); }
|
|
122 |
@@ -59,34 +158,35 @@
|
13 | 123 |
long mode = YGetInteger(sp-nArgs+2);
|
14 | 124 |
long create_id = YGetInteger(sp-nArgs+3);
|
15 | 125 |
long access_id = YGetInteger(sp-nArgs+4);
|
16 | 126 |
- int status;
|
17 | 127 |
- status=H5Fcreate(filename, (uint) mode, (hid_t) create_id, (hid_t) access_id);
|
18 | 128 |
- PushIntValue(status);
|
19 | |
+ hid_t fid;
|
20 | |
+ fid=H5Fcreate(filename, (uint) mode, (hid_t) create_id, (hid_t) access_id);
|
21 | |
+ PushLongValue(fid);
|
|
129 |
+ hid_t id;
|
|
130 |
+ id=H5Fcreate(filename, (uint) mode, (hid_t) create_id, (hid_t) access_id);
|
|
131 |
+ ypush_hid_t(id);
|
22 | 132 |
}
|
23 | 133 |
|
24 | 134 |
void Y__H5Fopen(int nArgs)
|
25 | |
@@ -69,18 +69,18 @@
|
|
135 |
{
|
26 | 136 |
char *filename = YGetString(sp-nArgs+1);
|
27 | 137 |
long flags = YGetInteger(sp-nArgs+2);
|
28 | |
long access_id = YGetInteger(sp-nArgs+3);
|
|
138 |
- long access_id = YGetInteger(sp-nArgs+3);
|
29 | 139 |
- int status;
|
30 | 140 |
- status=H5Fopen(filename, (uint) flags, (hid_t) access_id);
|
31 | 141 |
- PushIntValue(status);
|
32 | |
+ hid_t fid;
|
33 | |
+ fid=H5Fopen(filename, (uint) flags, (hid_t) access_id);
|
34 | |
+ PushLongValue(fid);
|
|
142 |
+ hid_t access_id = ygets_hid_t(nArgs-3);
|
|
143 |
+ hid_t id;
|
|
144 |
+ id=H5Fopen(filename, (uint) flags, (hid_t) access_id);
|
|
145 |
+ ypush_hid_t(id);
|
35 | 146 |
}
|
36 | 147 |
|
37 | 148 |
void Y__H5Fclose(int nArgs)
|
38 | 149 |
{
|
39 | |
long file_id = YGetInteger(sp-nArgs+1);
|
|
150 |
- long file_id = YGetInteger(sp-nArgs+1);
|
40 | 151 |
- int status;
|
|
152 |
- H5Fflush((hid_t) file_id, H5F_SCOPE_LOCAL);
|
|
153 |
- status=H5Fclose((hid_t) file_id);
|
|
154 |
+ hid_t file_id = ygets_hid_t(nArgs-1);
|
41 | 155 |
+ herr_t status;
|
42 | |
H5Fflush((hid_t) file_id, H5F_SCOPE_LOCAL);
|
43 | |
status=H5Fclose((hid_t) file_id);
|
44 | |
- PushIntValue(status);
|
45 | |
+ PushLongValue(status);
|
46 | |
}
|
47 | |
|
48 | |
|
49 | |
@@ -145,7 +145,7 @@
|
|
156 |
+ H5Fflush(file_id, H5F_SCOPE_LOCAL);
|
|
157 |
+ status=H5Fclose(file_id);
|
|
158 |
+ yfree_hid_t(file_id);
|
|
159 |
PushIntValue(status);
|
|
160 |
}
|
|
161 |
|
|
162 |
|
|
163 |
void Y__H5Areads(int nArgs)
|
|
164 |
{
|
|
165 |
- long attid = YGetInteger(sp-nArgs+1);
|
|
166 |
+ hid_t attid = ygets_hid_t(nArgs-1);
|
|
167 |
Dimension *strdims = 0;
|
|
168 |
char **data= YGet_Q(sp-nArgs+2,0,&strdims);
|
|
169 |
long nelem = YGetInteger(sp-nArgs+3);
|
|
170 |
@@ -114,7 +214,7 @@
|
|
171 |
|
|
172 |
void Y__H5Dreads(int nArgs)
|
|
173 |
{
|
|
174 |
- long did = YGetInteger(sp-nArgs+1);
|
|
175 |
+ hid_t did = ygets_hid_t(nArgs-1);
|
|
176 |
Dimension *strdims = 0;
|
|
177 |
char **data= YGet_Q(sp-nArgs+2,0,&strdims);
|
|
178 |
long nelem = YGetInteger(sp-nArgs+3);
|
|
179 |
@@ -140,52 +240,54 @@
|
|
180 |
|
|
181 |
void Y__H5Gget_linkval(int nArgs)
|
|
182 |
{
|
|
183 |
- long loc_id = YGetInteger(sp-nArgs+1);
|
|
184 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
|
185 |
char *gname = YGetString(sp-nArgs+2);
|
50 | 186 |
long size = YGetInteger(sp-nArgs+3);
|
51 | 187 |
char *value = YGetString(sp-nArgs+4);
|
52 | 188 |
|
53 | 189 |
- PushIntValue((long)H5Gget_linkval((hid_t) loc_id, gname, (size_t)size, value));
|
54 | |
+ PushLongValue((long)H5Gget_linkval((hid_t) loc_id, gname, (size_t)size, value));
|
55 | |
PopTo(sp-nArgs-1);
|
56 | |
Drop(nArgs);
|
57 | |
}
|
58 | |
@@ -155,7 +155,7 @@
|
59 | |
long loc_id = YGetInteger(sp-nArgs+1);
|
|
190 |
+ PushIntValue((long)H5Gget_linkval(loc_id, gname, (size_t)size, value));
|
|
191 |
PopTo(sp-nArgs-1);
|
|
192 |
Drop(nArgs);
|
|
193 |
}
|
|
194 |
|
|
195 |
void Y__H5Gopen(nArgs)
|
|
196 |
{
|
|
197 |
- long loc_id = YGetInteger(sp-nArgs+1);
|
|
198 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
60 | 199 |
char *gname = YGetString(sp-nArgs+2);
|
61 | 200 |
|
62 | 201 |
- PushIntValue((long)H5Gopen((hid_t)loc_id, gname));
|
63 | |
+ PushLongValue((long)H5Gopen((hid_t)loc_id, gname));
|
64 | |
PopTo(sp-nArgs-1);
|
65 | |
Drop(nArgs);
|
66 | |
}
|
67 | |
@@ -164,7 +164,7 @@
|
68 | |
{
|
69 | |
long gid = YGetInteger(sp-nArgs+1);
|
|
202 |
+ ypush_hid_t(H5Gopen(loc_id, gname));
|
|
203 |
PopTo(sp-nArgs-1);
|
|
204 |
Drop(nArgs);
|
|
205 |
}
|
|
206 |
|
|
207 |
void Y__H5Gclose(nArgs)
|
|
208 |
{
|
|
209 |
- long gid = YGetInteger(sp-nArgs+1);
|
|
210 |
+ hid_t gid = ygets_hid_t(nArgs-1);
|
70 | 211 |
|
71 | 212 |
- PushIntValue((long)H5Gclose((hid_t)gid));
|
72 | |
+ PushLongValue((long)H5Gclose((hid_t)gid));
|
73 | |
PopTo(sp-nArgs-1);
|
74 | |
Drop(nArgs);
|
75 | |
}
|
76 | |
@@ -175,7 +175,7 @@
|
|
213 |
+ PushIntValue((long)H5Gclose(gid));
|
|
214 |
+ yfree_hid_t(gid);
|
|
215 |
PopTo(sp-nArgs-1);
|
|
216 |
Drop(nArgs);
|
|
217 |
}
|
|
218 |
|
|
219 |
void Y__H5Gcreate(nArgs)
|
|
220 |
{
|
|
221 |
- long loc_id = YGetInteger(sp-nArgs+1);
|
|
222 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
77 | 223 |
char *gname = YGetString(sp-nArgs+2);
|
78 | 224 |
long size_hint = YGetInteger(sp-nArgs+3);
|
|
225 |
+ hid_t result=H5Gcreate(loc_id, gname, (size_t)size_hint);
|
79 | 226 |
|
80 | 227 |
- PushIntValue((long)H5Gcreate((hid_t)loc_id, gname, (size_t)size_hint));
|
81 | |
+ PushLongValue((long)H5Gcreate((hid_t)loc_id, gname, (size_t)size_hint));
|
82 | |
PopTo(sp-nArgs-1);
|
83 | |
Drop(nArgs);
|
84 | |
}
|
85 | |
@@ -186,7 +186,7 @@
|
|
228 |
+ ypush_hid_t(result);
|
|
229 |
PopTo(sp-nArgs-1);
|
|
230 |
Drop(nArgs);
|
|
231 |
}
|
|
232 |
|
|
233 |
void Y__H5Gget_num_objs(nArgs)
|
|
234 |
{
|
|
235 |
- long gid = YGetInteger(sp-nArgs+1);
|
|
236 |
+ hid_t gid = ygets_hid_t(nArgs-1);
|
86 | 237 |
hsize_t num_obj=0;
|
87 | 238 |
|
88 | |
H5Gget_num_objs((hid_t)gid, &num_obj);
|
89 | |
- PushIntValue((long)num_obj);
|
90 | |
+ PushLongValue((long)num_obj);
|
91 | |
PopTo(sp-nArgs-1);
|
92 | |
Drop(nArgs);
|
93 | |
}
|
94 | |
@@ -208,7 +208,7 @@
|
95 | |
long loc_id = YGetInteger(sp-nArgs+1);
|
|
239 |
- H5Gget_num_objs((hid_t)gid, &num_obj);
|
|
240 |
+ H5Gget_num_objs(gid, &num_obj);
|
|
241 |
PushIntValue((long)num_obj);
|
|
242 |
PopTo(sp-nArgs-1);
|
|
243 |
Drop(nArgs);
|
|
244 |
@@ -193,36 +295,36 @@
|
|
245 |
|
|
246 |
void Y__H5Gget_objname_by_idx(int nArgs)
|
|
247 |
{
|
|
248 |
- long loc_id = YGetInteger(sp-nArgs+1);
|
|
249 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
96 | 250 |
long idx = YGetInteger(sp-nArgs+2);
|
|
251 |
char *name = YGetString(sp-nArgs+3);
|
|
252 |
long size = YGetInteger(sp-nArgs+4);
|
|
253 |
|
|
254 |
- H5Gget_objname_by_idx((hid_t)loc_id, (hsize_t)idx,name,(size_t)size);
|
|
255 |
+ H5Gget_objname_by_idx(loc_id, (hsize_t)idx,name,(size_t)size);
|
|
256 |
Drop(nArgs);
|
|
257 |
}
|
|
258 |
|
|
259 |
|
|
260 |
void Y__H5Gget_objtype_by_idx(int nArgs)
|
|
261 |
{
|
|
262 |
- long loc_id = YGetInteger(sp-nArgs+1);
|
|
263 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
|
264 |
long idx = YGetInteger(sp-nArgs+2);
|
97 | 265 |
|
98 | 266 |
- PushIntValue((long)H5Gget_objtype_by_idx((hid_t)loc_id, (hsize_t)idx));
|
99 | |
+ PushLongValue((long)H5Gget_objtype_by_idx((hid_t)loc_id, (hsize_t)idx));
|
100 | |
PopTo(sp-nArgs-1);
|
101 | |
Drop(nArgs);
|
102 | |
}
|
103 | |
@@ -227,7 +227,7 @@
|
|
267 |
+ PushIntValue((long)H5Gget_objtype_by_idx(loc_id, (hsize_t)idx));
|
|
268 |
PopTo(sp-nArgs-1);
|
|
269 |
Drop(nArgs);
|
|
270 |
}
|
|
271 |
|
|
272 |
void Y__H5Gget_objtype_by_name(int nArgs)
|
|
273 |
{
|
|
274 |
- long loc_id = YGetInteger(sp-nArgs+1);
|
|
275 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
|
276 |
char *name = YGetString(sp-nArgs+2);
|
|
277 |
Dimension *dims = 0;
|
|
278 |
long *objnum = YGet_L(sp-nArgs+3,0, &dims);
|
|
279 |
|
|
280 |
H5G_stat_t statbuf;
|
|
281 |
hbool_t followlink=0;
|
|
282 |
- H5Gget_objinfo((hid_t)loc_id,name,followlink,&statbuf);
|
|
283 |
+ H5Gget_objinfo(loc_id,name,followlink,&statbuf);
|
|
284 |
|
104 | 285 |
objnum[0] = statbuf.objno[0];
|
105 | 286 |
objnum[1] = statbuf.objno[1];
|
106 | |
|
107 | |
- PushIntValue((long)statbuf.type);
|
108 | |
+ PushLongValue((long)statbuf.type);
|
109 | |
PopTo(sp-nArgs-1);
|
110 | |
Drop(nArgs);
|
111 | |
}
|
112 | |
@@ -240,7 +240,7 @@
|
113 | |
long new_loc_id = YGetInteger(sp-nArgs+4);
|
|
287 |
@@ -234,14 +336,14 @@
|
|
288 |
|
|
289 |
void Y__H5Glink2(int nArgs)
|
|
290 |
{
|
|
291 |
- long curr_loc_id = YGetInteger(sp-nArgs+1);
|
|
292 |
+ hid_t curr_loc_id = ygets_hid_t(nArgs-1);
|
|
293 |
char *curname = YGetString(sp-nArgs+2);
|
|
294 |
long link_type = YGetInteger(sp-nArgs+3);
|
|
295 |
- long new_loc_id = YGetInteger(sp-nArgs+4);
|
|
296 |
+ hid_t new_loc_id = ygets_hid_t(nArgs-4);
|
114 | 297 |
char *newname = YGetString(sp-nArgs+5);
|
115 | 298 |
|
116 | 299 |
- PushIntValue((long)H5Glink2((hid_t)curr_loc_id, curname,
|
117 | |
+ PushLongValue((long)H5Glink2((hid_t)curr_loc_id, curname,
|
118 | |
(H5G_link_t)link_type, (hid_t)new_loc_id,
|
|
300 |
- (H5G_link_t)link_type, (hid_t)new_loc_id,
|
|
301 |
+ PushIntValue((long)H5Glink2(curr_loc_id, curname,
|
|
302 |
+ (H5G_link_t)link_type, new_loc_id,
|
119 | 303 |
newname));
|
120 | 304 |
PopTo(sp-nArgs-1);
|
121 | |
@@ -252,7 +252,7 @@
|
122 | |
long loc_id = YGetInteger(sp-nArgs+1);
|
|
305 |
Drop(nArgs);
|
|
306 |
@@ -249,29 +351,29 @@
|
|
307 |
|
|
308 |
void Y__H5Gunlink(int nArgs)
|
|
309 |
{
|
|
310 |
- long loc_id = YGetInteger(sp-nArgs+1);
|
|
311 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
123 | 312 |
char *name = YGetString(sp-nArgs+2);
|
124 | 313 |
|
125 | 314 |
- PushIntValue((long)H5Gunlink((hid_t)loc_id, name));
|
126 | |
+ PushLongValue((long)H5Gunlink((hid_t)loc_id, name));
|
127 | |
PopTo(sp-nArgs-1);
|
128 | |
Drop(nArgs);
|
129 | |
}
|
130 | |
@@ -261,7 +261,7 @@
|
131 | |
{
|
132 | |
long cls_id = YGetInteger(sp-nArgs+1);
|
|
315 |
+ PushIntValue((long)H5Gunlink(loc_id, name));
|
|
316 |
PopTo(sp-nArgs-1);
|
|
317 |
Drop(nArgs);
|
|
318 |
}
|
|
319 |
|
|
320 |
void Y__H5Pcreate(int nArgs)
|
|
321 |
{
|
|
322 |
- long cls_id = YGetInteger(sp-nArgs+1);
|
|
323 |
+ hid_t cls_id = ygets_hid_t(nArgs-1);
|
133 | 324 |
|
134 | 325 |
- PushIntValue((long)H5Pcreate((hid_t)cls_id));
|
135 | |
+ PushLongValue((long)H5Pcreate((hid_t)cls_id));
|
136 | |
PopTo(sp-nArgs-1);
|
137 | |
Drop(nArgs);
|
138 | |
}
|
139 | |
@@ -271,7 +271,7 @@
|
140 | |
long plist = YGetInteger(sp-nArgs+1);
|
|
326 |
+ ypush_hid_t(H5Pcreate(cls_id));
|
|
327 |
PopTo(sp-nArgs-1);
|
|
328 |
Drop(nArgs);
|
|
329 |
}
|
|
330 |
|
|
331 |
void Y__H5Pset_deflate(int nArgs)
|
|
332 |
{
|
|
333 |
- long plist = YGetInteger(sp-nArgs+1);
|
|
334 |
+ hid_t plist = ygets_hid_t(nArgs-1);
|
141 | 335 |
long level = YGetInteger(sp-nArgs+2);
|
142 | 336 |
|
143 | 337 |
- PushIntValue((long)H5Pset_deflate((hid_t)plist,(int)level));
|
144 | |
+ PushLongValue((long)H5Pset_deflate((hid_t)plist,(int)level));
|
145 | |
PopTo(sp-nArgs-1);
|
146 | |
Drop(nArgs);
|
147 | |
}
|
148 | |
@@ -289,13 +289,14 @@
|
149 | |
|
150 | |
hsize_t hdim[5];
|
|
338 |
+ PushIntValue((long)H5Pset_deflate(plist,(int)level));
|
|
339 |
PopTo(sp-nArgs-1);
|
|
340 |
Drop(nArgs);
|
|
341 |
}
|
|
342 |
@@ -282,7 +384,7 @@
|
|
343 |
|
|
344 |
void Y__H5Pset_chunk(int nArgs)
|
|
345 |
{
|
|
346 |
- long plist=YGetInteger(sp-nArgs+1);
|
|
347 |
+ hid_t plist = ygets_hid_t(nArgs-1);
|
|
348 |
long ndims=YGetInteger(sp-nArgs+2);
|
|
349 |
Dimension *tmpdims = 0;
|
|
350 |
long *dim=YGet_L(sp-nArgs+3,0,&tmpdims);
|
|
351 |
@@ -293,7 +395,7 @@
|
|
352 |
|
|
353 |
for (i=0;i<ndims;i++) hdim[i]=(hsize_t)dim[i];
|
|
354 |
|
|
355 |
- status=(long)H5Pset_chunk((hid_t)plist,(int)ndims, hdim);
|
|
356 |
+ status=(long)H5Pset_chunk(plist,(int)ndims, hdim);
|
|
357 |
|
|
358 |
PushIntValue(status);
|
|
359 |
PopTo(sp-nArgs-1);
|
|
360 |
@@ -303,18 +405,17 @@
|
|
361 |
//hid_t H5Acreate(hid_t loc_id, const char *name, hid_t type_id, hid_t space_id, hid_t create_plist)
|
|
362 |
void Y__H5Acreate(int nArgs)
|
|
363 |
{
|
|
364 |
- long loc_id=YGetInteger(sp-nArgs+1);
|
|
365 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
|
366 |
char *name=YGetString(sp-nArgs+2);
|
|
367 |
- long type_id=YGetInteger(sp-nArgs+3);
|
|
368 |
- long space_id=YGetInteger(sp-nArgs+4);
|
|
369 |
- long create_plist=YGetInteger(sp-nArgs+5);
|
|
370 |
+ hid_t type_id = ygets_hid_t(nArgs-3);
|
|
371 |
+ hid_t space_id = ygets_hid_t(nArgs-4);
|
|
372 |
+ hid_t create_plist = ygets_hid_t(nArgs-5);
|
|
373 |
|
|
374 |
- long status;
|
|
375 |
+ hid_t id;
|
|
376 |
|
|
377 |
- status=(long)H5Acreate((hid_t)loc_id, name, (hid_t)type_id,
|
|
378 |
- (hid_t)space_id,(hid_t)create_plist);
|
|
379 |
+ id=H5Acreate(loc_id, name, type_id, space_id,create_plist);
|
|
380 |
|
|
381 |
- PushIntValue(status);
|
|
382 |
+ ypush_hid_t(id);
|
|
383 |
PopTo(sp-nArgs-1);
|
|
384 |
Drop(nArgs);
|
|
385 |
}
|
|
386 |
@@ -323,7 +424,7 @@
|
|
387 |
|
|
388 |
void Y__H5Adelete(int nArgs)
|
|
389 |
{
|
|
390 |
- long loc_id=YGetInteger(sp-nArgs+1);
|
|
391 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
|
392 |
char *name=YGetString(sp-nArgs+2);
|
|
393 |
|
|
394 |
long status;
|
|
395 |
@@ -340,7 +441,7 @@
|
|
396 |
|
|
397 |
void Y__H5Aget_num_attrs(int nArgs)
|
|
398 |
{
|
|
399 |
- long loc_id=YGetInteger(sp-nArgs+1);
|
|
400 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
|
401 |
|
|
402 |
long status;
|
|
403 |
|
|
404 |
@@ -355,13 +456,13 @@
|
|
405 |
|
|
406 |
void Y__H5Aget_type(int nArgs)
|
|
407 |
{
|
|
408 |
- long attr_id=YGetInteger(sp-nArgs+1);
|
|
409 |
+ hid_t attr_id = ygets_hid_t(nArgs-1);
|
|
410 |
|
|
411 |
- long status;
|
|
412 |
+ hid_t id;
|
|
413 |
|
|
414 |
- status=(long)H5Aget_type((hid_t)attr_id);
|
|
415 |
+ id=H5Aget_type(attr_id);
|
|
416 |
|
|
417 |
- PushIntValue(status);
|
|
418 |
+ ypush_hid_t(id);
|
|
419 |
PopTo(sp-nArgs-1);
|
|
420 |
Drop(nArgs);
|
|
421 |
}
|
|
422 |
@@ -370,20 +471,20 @@
|
|
423 |
|
|
424 |
void Y__H5Aget_space(int nArgs)
|
|
425 |
{
|
|
426 |
- long attr_id=YGetInteger(sp-nArgs+1);
|
|
427 |
+ hid_t attr_id = ygets_hid_t(nArgs-1);
|
|
428 |
|
|
429 |
- long status;
|
|
430 |
+ hid_t id;
|
|
431 |
|
|
432 |
- status=(long)H5Aget_space((hid_t)attr_id);
|
|
433 |
+ id=H5Aget_space(attr_id);
|
|
434 |
|
|
435 |
- PushIntValue(status);
|
|
436 |
+ ypush_hid_t(id);
|
|
437 |
PopTo(sp-nArgs-1);
|
|
438 |
Drop(nArgs);
|
|
439 |
}
|
|
440 |
|
|
441 |
void Y__H5Aget_name(int nArgs)
|
|
442 |
{
|
|
443 |
- long attr_id=YGetInteger(sp-nArgs+1);
|
|
444 |
+ hid_t attr_id = ygets_hid_t(nArgs-1);
|
|
445 |
long buf_size=YGetInteger(sp-nArgs+2);
|
|
446 |
char *buf=YGetString(sp-nArgs+3);
|
|
447 |
|
|
448 |
@@ -391,7 +492,7 @@
|
|
449 |
|
|
450 |
status=(long)H5Aget_name((hid_t)attr_id, (size_t)buf_size, buf);
|
|
451 |
|
|
452 |
- PushIntValue(status);
|
|
453 |
+ PushLongValue(status);
|
|
454 |
PopTo(sp-nArgs-1);
|
|
455 |
Drop(nArgs);
|
|
456 |
}
|
|
457 |
@@ -400,14 +501,14 @@
|
|
458 |
|
|
459 |
void Y__H5Aopen_idx(int nArgs)
|
|
460 |
{
|
|
461 |
- long loc_id=YGetInteger(sp-nArgs+1);
|
|
462 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
|
463 |
long idx=YGetInteger(sp-nArgs+2);
|
|
464 |
|
|
465 |
- long status;
|
|
466 |
+ hid_t id;
|
|
467 |
|
|
468 |
- status=(long)H5Aopen_idx((hid_t)loc_id, (unsigned int)idx);
|
|
469 |
+ id=H5Aopen_idx(loc_id, (unsigned int)idx);
|
|
470 |
|
|
471 |
- PushIntValue(status);
|
|
472 |
+ ypush_hid_t(id);
|
|
473 |
PopTo(sp-nArgs-1);
|
|
474 |
Drop(nArgs);
|
|
475 |
}
|
|
476 |
@@ -416,14 +517,14 @@
|
|
477 |
|
|
478 |
void Y__H5Aopen_name(int nArgs)
|
|
479 |
{
|
|
480 |
- long loc_id=YGetInteger(sp-nArgs+1);
|
|
481 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
|
482 |
char *name=YGetString(sp-nArgs+2);
|
|
483 |
|
|
484 |
- long status;
|
|
485 |
+ hid_t id;
|
|
486 |
|
|
487 |
- status=(long)H5Aopen_name((hid_t)loc_id, name);
|
|
488 |
+ id=H5Aopen_name(loc_id, name);
|
|
489 |
|
|
490 |
- PushIntValue(status);
|
|
491 |
+ ypush_hid_t(id);
|
|
492 |
PopTo(sp-nArgs-1);
|
|
493 |
Drop(nArgs);
|
|
494 |
}
|
|
495 |
@@ -432,12 +533,12 @@
|
|
496 |
|
|
497 |
void Y__H5Aread(int nArgs)
|
|
498 |
{
|
|
499 |
- long attr_id=YGetInteger(sp-nArgs+1);
|
|
500 |
- long mem_type_id=YGetInteger(sp-nArgs+2);
|
|
501 |
+ hid_t attr_id = ygets_hid_t(nArgs-1);
|
|
502 |
+ hid_t mem_type_id = ygets_hid_t(nArgs-2);
|
|
503 |
|
|
504 |
long status;
|
|
505 |
|
|
506 |
- status=(long)H5Aread((hid_t)attr_id, (hid_t)mem_type_id, yarg_sp(0));
|
|
507 |
+ status=(long)H5Aread(attr_id, mem_type_id, yarg_sp(0));
|
|
508 |
|
|
509 |
PushIntValue(status);
|
|
510 |
PopTo(sp-nArgs-1);
|
|
511 |
@@ -446,12 +547,12 @@
|
|
512 |
|
|
513 |
void Y__H5Awrite(int nArgs)
|
|
514 |
{
|
|
515 |
- long attr_id=YGetInteger(sp-nArgs+1);
|
|
516 |
- long mem_type_id=YGetInteger(sp-nArgs+2);
|
|
517 |
+ hid_t attr_id = ygets_hid_t(nArgs-1);
|
|
518 |
+ hid_t mem_type_id = ygets_hid_t(nArgs-2);
|
|
519 |
|
|
520 |
long status;
|
|
521 |
|
|
522 |
- status=(long)H5Awrite((hid_t)attr_id, (hid_t)mem_type_id, yarg_sp(0));
|
|
523 |
+ status=(long)H5Awrite(attr_id, mem_type_id, yarg_sp(0));
|
|
524 |
|
|
525 |
PushIntValue(status);
|
|
526 |
PopTo(sp-nArgs-1);
|
|
527 |
@@ -462,11 +563,12 @@
|
|
528 |
|
|
529 |
void Y__H5Aclose(int nArgs)
|
|
530 |
{
|
|
531 |
- long attr_id=YGetInteger(sp-nArgs+1);
|
|
532 |
+ hid_t attr_id = ygets_hid_t(nArgs-1);
|
|
533 |
|
|
534 |
long status;
|
|
535 |
|
|
536 |
status=(long)H5Aclose((hid_t)attr_id);
|
|
537 |
+ yfree_hid_t(attr_id);
|
|
538 |
|
|
539 |
PushIntValue(status);
|
|
540 |
PopTo(sp-nArgs-1);
|
|
541 |
@@ -477,11 +579,12 @@
|
|
542 |
|
|
543 |
void Y__H5Dclose(int nArgs)
|
|
544 |
{
|
|
545 |
- long dataset_id=YGetInteger(sp-nArgs+1);
|
|
546 |
+ hid_t dataset_id = ygets_hid_t(nArgs-1);
|
|
547 |
|
|
548 |
long status;
|
|
549 |
|
|
550 |
status=(long)H5Dclose((hid_t)dataset_id);
|
|
551 |
+ yfree_hid_t(dataset_id);
|
|
552 |
|
|
553 |
PushIntValue(status);
|
|
554 |
PopTo(sp-nArgs-1);
|
|
555 |
@@ -493,18 +596,17 @@
|
|
556 |
|
|
557 |
void Y__H5Dcreate(int nArgs)
|
|
558 |
{
|
|
559 |
- long loc_id=YGetInteger(sp-nArgs+1);
|
|
560 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
|
561 |
char *name=YGetString(sp-nArgs+2);
|
|
562 |
- long type_id=YGetInteger(sp-nArgs+3);
|
|
563 |
- long space_id=YGetInteger(sp-nArgs+4);
|
|
564 |
- long create_plist_id=YGetInteger(sp-nArgs+5);
|
|
565 |
+ hid_t type_id = ygets_hid_t(nArgs-3);
|
|
566 |
+ hid_t space_id = ygets_hid_t(nArgs-4);
|
|
567 |
+ hid_t create_plist_id = ygets_hid_t(nArgs-5);
|
|
568 |
|
|
569 |
- long status;
|
|
570 |
+ hid_t id;
|
|
571 |
|
|
572 |
- status=(long)H5Dcreate((hid_t)loc_id, name, (hid_t)type_id,
|
|
573 |
- (hid_t)space_id,(hid_t)create_plist_id);
|
|
574 |
+ id=H5Dcreate(loc_id, name, type_id, space_id, create_plist_id);
|
|
575 |
|
|
576 |
- PushIntValue(status);
|
|
577 |
+ ypush_hid_t(id);
|
|
578 |
PopTo(sp-nArgs-1);
|
|
579 |
Drop(nArgs);
|
|
580 |
}
|
|
581 |
@@ -513,14 +615,14 @@
|
|
582 |
|
|
583 |
void Y__H5Dopen(int nArgs)
|
|
584 |
{
|
|
585 |
- long loc_id=YGetInteger(sp-nArgs+1);
|
|
586 |
+ hid_t loc_id = ygets_hid_t(nArgs-1);
|
|
587 |
char *name=YGetString(sp-nArgs+2);
|
|
588 |
|
|
589 |
- long status;
|
|
590 |
+ hid_t id;
|
|
591 |
|
|
592 |
- status=(long)H5Dopen((hid_t)loc_id, name);
|
|
593 |
+ id=H5Dopen(loc_id, name);
|
|
594 |
|
|
595 |
- PushIntValue(status);
|
|
596 |
+ ypush_hid_t(id);
|
|
597 |
PopTo(sp-nArgs-1);
|
|
598 |
Drop(nArgs);
|
|
599 |
}
|
|
600 |
@@ -529,13 +631,13 @@
|
|
601 |
|
|
602 |
void Y__H5Dget_space(int nArgs)
|
|
603 |
{
|
|
604 |
- long dataset_id=YGetInteger(sp-nArgs+1);
|
|
605 |
-
|
|
606 |
- long status;
|
|
607 |
+ hid_t dataset_id = ygets_hid_t(nArgs-1);
|
|
608 |
|
|
609 |
- status=(long)H5Dget_space((hid_t)dataset_id);
|
|
610 |
+ hid_t id;
|
|
611 |
|
|
612 |
- PushIntValue(status);
|
|
613 |
+ id=H5Dget_space(dataset_id);
|
|
614 |
+
|
|
615 |
+ ypush_hid_t(id);
|
|
616 |
PopTo(sp-nArgs-1);
|
|
617 |
Drop(nArgs);
|
|
618 |
}
|
|
619 |
@@ -544,13 +646,13 @@
|
|
620 |
|
|
621 |
void Y__H5Dget_type(int nArgs)
|
|
622 |
{
|
|
623 |
- long dataset_id=YGetInteger(sp-nArgs+1);
|
|
624 |
+ hid_t dataset_id = ygets_hid_t(nArgs-1);
|
|
625 |
|
|
626 |
- long status;
|
|
627 |
+ hid_t id;
|
|
628 |
|
|
629 |
- status=(long)H5Dget_type((hid_t)dataset_id);
|
|
630 |
+ id=H5Dget_type(dataset_id);
|
|
631 |
|
|
632 |
- PushIntValue(status);
|
|
633 |
+ ypush_hid_t(id);
|
|
634 |
PopTo(sp-nArgs-1);
|
|
635 |
Drop(nArgs);
|
|
636 |
}
|
|
637 |
@@ -560,11 +662,11 @@
|
|
638 |
|
|
639 |
void Y__H5Dread(int nArgs)
|
|
640 |
{
|
|
641 |
- long dataset_id=YGetInteger(sp-nArgs+1);
|
|
642 |
- long mem_type_id=YGetInteger(sp-nArgs+2);
|
|
643 |
- long mem_space_id=YGetInteger(sp-nArgs+3);
|
|
644 |
- long file_space_id=YGetInteger(sp-nArgs+4);
|
|
645 |
- long xfer_plist_id=YGetInteger(sp-nArgs+5);
|
|
646 |
+ hid_t dataset_id = ygets_hid_t(nArgs-1);
|
|
647 |
+ hid_t mem_type_id = ygets_hid_t(nArgs-2);
|
|
648 |
+ hid_t mem_space_id = ygets_hid_t(nArgs-3);
|
|
649 |
+ hid_t file_space_id = ygets_hid_t(nArgs-4);
|
|
650 |
+ hid_t xfer_plist_id = ygets_hid_t(nArgs-5);
|
|
651 |
|
|
652 |
long status;
|
|
653 |
|
|
654 |
@@ -582,11 +684,11 @@
|
|
655 |
|
|
656 |
void Y__H5Dwrite(int nArgs)
|
|
657 |
{
|
|
658 |
- long dataset_id=YGetInteger(sp-nArgs+1);
|
|
659 |
- long mem_type_id=YGetInteger(sp-nArgs+2);
|
|
660 |
- long mem_space_id=YGetInteger(sp-nArgs+3);
|
|
661 |
- long file_space_id=YGetInteger(sp-nArgs+4);
|
|
662 |
- long xfer_plist_id=YGetInteger(sp-nArgs+5);
|
|
663 |
+ hid_t dataset_id = ygets_hid_t(nArgs-1);
|
|
664 |
+ hid_t mem_type_id = ygets_hid_t(nArgs-2);
|
|
665 |
+ hid_t mem_space_id = ygets_hid_t(nArgs-3);
|
|
666 |
+ hid_t file_space_id = ygets_hid_t(nArgs-4);
|
|
667 |
+ hid_t xfer_plist_id = ygets_hid_t(nArgs-5);
|
|
668 |
|
|
669 |
long status;
|
|
670 |
|
|
671 |
@@ -603,11 +705,12 @@
|
|
672 |
|
|
673 |
void Y__H5Sclose(int nArgs)
|
|
674 |
{
|
|
675 |
- long space_id=YGetInteger(sp-nArgs+1);
|
|
676 |
+ hid_t space_id = ygets_hid_t(nArgs-1);
|
|
677 |
|
|
678 |
long status;
|
|
679 |
|
|
680 |
status=(long)H5Sclose((hid_t)space_id);
|
|
681 |
+ yfree_hid_t(space_id);
|
|
682 |
|
|
683 |
PushIntValue(status);
|
|
684 |
PopTo(sp-nArgs-1);
|
|
685 |
@@ -620,11 +723,11 @@
|
|
686 |
{
|
|
687 |
long type=YGetInteger(sp-nArgs+1);
|
|
688 |
|
|
689 |
- long status;
|
|
690 |
+ hid_t id;
|
|
691 |
|
|
692 |
- status=(long)H5Screate((H5S_class_t)type);
|
|
693 |
+ id=H5Screate((H5S_class_t)type);
|
|
694 |
|
|
695 |
- PushIntValue(status);
|
|
696 |
+ ypush_hid_t(id);
|
|
697 |
PopTo(sp-nArgs-1);
|
|
698 |
Drop(nArgs);
|
|
699 |
}
|
|
700 |
@@ -633,7 +736,7 @@
|
|
701 |
|
|
702 |
void Y__H5Sget_simple_extent_ndims(int nArgs)
|
|
703 |
{
|
|
704 |
- long space_id=YGetInteger(sp-nArgs+1);
|
|
705 |
+ hid_t space_id = ygets_hid_t(nArgs-1);
|
|
706 |
|
|
707 |
long status;
|
|
708 |
|
|
709 |
@@ -648,7 +751,7 @@
|
|
710 |
|
|
711 |
void Y__H5Sget_simple_extent_type(int nArgs)
|
|
712 |
{
|
|
713 |
- long space_id=YGetInteger(sp-nArgs+1);
|
|
714 |
+ hid_t space_id = ygets_hid_t(nArgs-1);
|
|
715 |
|
|
716 |
long status;
|
|
717 |
|
|
718 |
@@ -675,7 +778,8 @@
|
|
719 |
hsize_t hdims[5];
|
|
720 |
hsize_t hmaxdims[5];
|
151 | 721 |
|
152 | 722 |
- long status,i;
|
153 | 723 |
+ long i;
|
154 | |
+ herr_t status;
|
155 | |
|
156 | |
for (i=0;i<ndims;i++) hdim[i]=(hsize_t)dim[i];
|
157 | |
|
158 | |
status=(long)H5Pset_chunk((hid_t)plist,(int)ndims, hdim);
|
159 | |
|
160 | |
- PushIntValue(status);
|
161 | |
+ PushLongValue(status);
|
162 | |
PopTo(sp-nArgs-1);
|
163 | |
Drop(nArgs);
|
164 | |
}
|
165 | |
@@ -309,12 +310,12 @@
|
166 | |
long space_id=YGetInteger(sp-nArgs+4);
|
167 | |
long create_plist=YGetInteger(sp-nArgs+5);
|
|
724 |
+ hid_t id;
|
|
725 |
|
|
726 |
for (i=0;i<rank;i++) {
|
|
727 |
hdims[i] = (hsize_t)dims[i];
|
|
728 |
@@ -684,9 +788,9 @@
|
|
729 |
} else { hmaxdims[i] = (hsize_t)0; }
|
|
730 |
}
|
|
731 |
|
|
732 |
- status=(long)H5Screate_simple((int)rank, hdims, hmaxdims);
|
|
733 |
+ id=H5Screate_simple((int)rank, hdims, hmaxdims);
|
|
734 |
|
|
735 |
- PushIntValue(status);
|
|
736 |
+ ypush_hid_t(id);
|
|
737 |
PopTo(sp-nArgs-1);
|
|
738 |
Drop(nArgs);
|
|
739 |
}
|
|
740 |
@@ -697,7 +801,7 @@
|
|
741 |
|
|
742 |
void Y__H5Sget_simple_extent_dims(int nArgs)
|
|
743 |
{
|
|
744 |
- long space_id=YGetInteger(sp-nArgs+1);
|
|
745 |
+ hid_t space_id = ygets_hid_t(nArgs-1);
|
|
746 |
Dimension *dimsdims = 0;
|
|
747 |
long *dims=YGet_L(sp-nArgs+2,0,&dimsdims);
|
|
748 |
long ismaxdims = YNotNil(sp-nArgs+2);
|
|
749 |
@@ -734,13 +838,13 @@
|
|
750 |
|
|
751 |
void Y__H5Tcopy(int nArgs)
|
|
752 |
{
|
|
753 |
- long type_id=YGetInteger(sp-nArgs+1);
|
|
754 |
+ hid_t type_id = ygets_hid_t(nArgs-1);
|
168 | 755 |
|
169 | 756 |
- long status;
|
170 | 757 |
+ hid_t id;
|
171 | 758 |
|
172 | |
- status=(long)H5Acreate((hid_t)loc_id, name, (hid_t)type_id,
|
173 | |
+ id=H5Acreate((hid_t)loc_id, name, (hid_t)type_id,
|
174 | |
(hid_t)space_id,(hid_t)create_plist);
|
175 | |
|
176 | |
- PushIntValue(status);
|
177 | |
+ PushLongValue(id);
|
178 | |
PopTo(sp-nArgs-1);
|
179 | |
Drop(nArgs);
|
180 | |
}
|
181 | |
@@ -326,11 +327,11 @@
|
182 | |
long loc_id=YGetInteger(sp-nArgs+1);
|
183 | |
char *name=YGetString(sp-nArgs+2);
|
184 | |
|
185 | |
- long status;
|
186 | |
+ herr_t status;
|
187 | |
|
188 | |
- status=(long)H5Adelete((hid_t)loc_id, name);
|
189 | |
+ status=H5Adelete((hid_t)loc_id, name);
|
190 | |
|
191 | |
- PushIntValue(status);
|
192 | |
+ PushLongValue(status);
|
193 | |
PopTo(sp-nArgs-1);
|
194 | |
Drop(nArgs);
|
195 | |
}
|
196 | |
@@ -346,7 +347,7 @@
|
197 | |
|
198 | |
status=(long)H5Aget_num_attrs((hid_t)loc_id);
|
199 | |
|
200 | |
- PushIntValue(status);
|
201 | |
+ PushLongValue(status);
|
202 | |
PopTo(sp-nArgs-1);
|
203 | |
Drop(nArgs);
|
204 | |
}
|
205 | |
@@ -357,11 +358,11 @@
|
206 | |
{
|
207 | |
long attr_id=YGetInteger(sp-nArgs+1);
|
208 | |
|
209 | |
- long status;
|
210 | |
+ hid_t id;
|
211 | |
|
212 | |
- status=(long)H5Aget_type((hid_t)attr_id);
|
213 | |
+ id=H5Aget_type((hid_t)attr_id);
|
214 | |
|
215 | |
- PushIntValue(status);
|
216 | |
+ PushLongValue(id);
|
217 | |
PopTo(sp-nArgs-1);
|
218 | |
Drop(nArgs);
|
219 | |
}
|
220 | |
@@ -372,11 +373,11 @@
|
221 | |
{
|
222 | |
long attr_id=YGetInteger(sp-nArgs+1);
|
223 | |
|
224 | |
- long status;
|
225 | |
+ hid_t id;
|
226 | |
|
227 | |
- status=(long)H5Aget_space((hid_t)attr_id);
|
228 | |
+ id=H5Aget_space((hid_t)attr_id);
|
229 | |
|
230 | |
- PushIntValue(status);
|
231 | |
+ PushLongValue(id);
|
232 | |
PopTo(sp-nArgs-1);
|
233 | |
Drop(nArgs);
|
234 | |
}
|
235 | |
@@ -391,7 +392,7 @@
|
236 | |
|
237 | |
status=(long)H5Aget_name((hid_t)attr_id, (size_t)buf_size, buf);
|
238 | |
|
239 | |
- PushIntValue(status);
|
240 | |
+ PushLongValue(status);
|
241 | |
PopTo(sp-nArgs-1);
|
242 | |
Drop(nArgs);
|
243 | |
}
|
244 | |
@@ -407,7 +408,7 @@
|
245 | |
|
246 | |
status=(long)H5Aopen_idx((hid_t)loc_id, (unsigned int)idx);
|
247 | |
|
248 | |
- PushIntValue(status);
|
249 | |
+ PushLongValue(status);
|
250 | |
PopTo(sp-nArgs-1);
|
251 | |
Drop(nArgs);
|
252 | |
}
|
253 | |
@@ -423,7 +424,7 @@
|
254 | |
|
255 | |
status=(long)H5Aopen_name((hid_t)loc_id, name);
|
256 | |
|
257 | |
- PushIntValue(status);
|
258 | |
+ PushLongValue(status);
|
259 | |
PopTo(sp-nArgs-1);
|
260 | |
Drop(nArgs);
|
261 | |
}
|
262 | |
@@ -439,7 +440,7 @@
|
263 | |
|
264 | |
status=(long)H5Aread((hid_t)attr_id, (hid_t)mem_type_id, yarg_sp(0));
|
265 | |
|
266 | |
- PushIntValue(status);
|
267 | |
+ PushLongValue(status);
|
268 | |
PopTo(sp-nArgs-1);
|
269 | |
Drop(nArgs);
|
270 | |
}
|
271 | |
@@ -453,7 +454,7 @@
|
272 | |
|
273 | |
status=(long)H5Awrite((hid_t)attr_id, (hid_t)mem_type_id, yarg_sp(0));
|
274 | |
|
275 | |
- PushIntValue(status);
|
276 | |
+ PushLongValue(status);
|
277 | |
PopTo(sp-nArgs-1);
|
278 | |
Drop(nArgs);
|
279 | |
}
|
280 | |
@@ -468,7 +469,7 @@
|
281 | |
|
282 | |
status=(long)H5Aclose((hid_t)attr_id);
|
283 | |
|
284 | |
- PushIntValue(status);
|
285 | |
+ PushLongValue(status);
|
286 | |
PopTo(sp-nArgs-1);
|
287 | |
Drop(nArgs);
|
288 | |
}
|
289 | |
@@ -483,7 +484,7 @@
|
290 | |
|
291 | |
status=(long)H5Dclose((hid_t)dataset_id);
|
292 | |
|
293 | |
- PushIntValue(status);
|
294 | |
+ PushLongValue(status);
|
295 | |
PopTo(sp-nArgs-1);
|
296 | |
Drop(nArgs);
|
297 | |
}
|
298 | |
@@ -504,7 +505,7 @@
|
299 | |
status=(long)H5Dcreate((hid_t)loc_id, name, (hid_t)type_id,
|
300 | |
(hid_t)space_id,(hid_t)create_plist_id);
|
301 | |
|
302 | |
- PushIntValue(status);
|
303 | |
+ PushLongValue(status);
|
304 | |
PopTo(sp-nArgs-1);
|
305 | |
Drop(nArgs);
|
306 | |
}
|
307 | |
@@ -520,7 +521,7 @@
|
308 | |
|
309 | |
status=(long)H5Dopen((hid_t)loc_id, name);
|
310 | |
|
311 | |
- PushIntValue(status);
|
312 | |
+ PushLongValue(status);
|
313 | |
PopTo(sp-nArgs-1);
|
314 | |
Drop(nArgs);
|
315 | |
}
|
316 | |
@@ -535,7 +536,7 @@
|
317 | |
|
318 | |
status=(long)H5Dget_space((hid_t)dataset_id);
|
319 | |
|
320 | |
- PushIntValue(status);
|
321 | |
+ PushLongValue(status);
|
322 | |
PopTo(sp-nArgs-1);
|
323 | |
Drop(nArgs);
|
324 | |
}
|
325 | |
@@ -550,7 +551,7 @@
|
326 | |
|
327 | |
status=(long)H5Dget_type((hid_t)dataset_id);
|
328 | |
|
329 | |
- PushIntValue(status);
|
330 | |
+ PushLongValue(status);
|
331 | |
PopTo(sp-nArgs-1);
|
332 | |
Drop(nArgs);
|
333 | |
}
|
334 | |
@@ -572,7 +573,7 @@
|
335 | |
(hid_t)mem_space_id, (hid_t)file_space_id,
|
336 | |
(hid_t)xfer_plist_id, yarg_sp(0));
|
337 | |
|
338 | |
- PushIntValue(status);
|
339 | |
+ PushLongValue(status);
|
340 | |
PopTo(sp-nArgs-1);
|
341 | |
Drop(nArgs);
|
342 | |
}
|
343 | |
@@ -594,7 +595,7 @@
|
344 | |
(hid_t)mem_space_id, (hid_t)file_space_id,
|
345 | |
(hid_t)xfer_plist_id, yarg_sp(0));
|
346 | |
|
347 | |
- PushIntValue(status);
|
348 | |
+ PushLongValue(status);
|
349 | |
PopTo(sp-nArgs-1);
|
350 | |
Drop(nArgs);
|
351 | |
}
|
352 | |
@@ -609,7 +610,7 @@
|
353 | |
|
354 | |
status=(long)H5Sclose((hid_t)space_id);
|
355 | |
|
356 | |
- PushIntValue(status);
|
357 | |
+ PushLongValue(status);
|
358 | |
PopTo(sp-nArgs-1);
|
359 | |
Drop(nArgs);
|
360 | |
}
|
361 | |
@@ -624,7 +625,7 @@
|
362 | |
|
363 | |
status=(long)H5Screate((H5S_class_t)type);
|
364 | |
|
365 | |
- PushIntValue(status);
|
366 | |
+ PushLongValue(status);
|
367 | |
PopTo(sp-nArgs-1);
|
368 | |
Drop(nArgs);
|
369 | |
}
|
370 | |
@@ -639,7 +640,7 @@
|
371 | |
|
372 | |
status=(long)H5Sget_simple_extent_ndims((hid_t)space_id);
|
373 | |
|
374 | |
- PushIntValue(status);
|
375 | |
+ PushLongValue(status);
|
376 | |
PopTo(sp-nArgs-1);
|
377 | |
Drop(nArgs);
|
378 | |
}
|
379 | |
@@ -654,7 +655,7 @@
|
380 | |
|
381 | |
status=(long)H5Sget_simple_extent_type((hid_t)space_id);
|
382 | |
|
383 | |
- PushIntValue(status);
|
384 | |
+ PushLongValue(status);
|
385 | |
PopTo(sp-nArgs-1);
|
386 | |
Drop(nArgs);
|
387 | |
}
|
388 | |
@@ -686,7 +687,7 @@
|
389 | |
|
390 | |
status=(long)H5Screate_simple((int)rank, hdims, hmaxdims);
|
391 | |
|
392 | |
- PushIntValue(status);
|
393 | |
+ PushLongValue(status);
|
394 | |
PopTo(sp-nArgs-1);
|
395 | |
Drop(nArgs);
|
396 | |
}
|
397 | |
@@ -711,7 +712,7 @@
|
398 | |
rank=(long)H5Sget_simple_extent_ndims((hid_t)space_id);
|
399 | |
|
400 | |
if (rank<0) {
|
401 | |
- PushIntValue(rank);
|
402 | |
+ PushLongValue(rank);
|
403 | |
PopTo(sp-nArgs-1);
|
404 | |
Drop(nArgs);
|
405 | |
}
|
406 | |
@@ -725,7 +726,7 @@
|
407 | |
} else { maxdims[i] = (long)0; }
|
408 | |
}
|
409 | |
|
410 | |
- PushIntValue(status);
|
411 | |
+ PushLongValue(status);
|
412 | |
PopTo(sp-nArgs-1);
|
413 | |
Drop(nArgs);
|
414 | |
}
|
415 | |
@@ -740,7 +741,7 @@
|
416 | |
|
417 | |
status=(long)H5Tcopy((hid_t)type_id);
|
418 | |
|
419 | |
- PushIntValue(status);
|
420 | |
+ PushLongValue(status);
|
421 | |
PopTo(sp-nArgs-1);
|
422 | |
Drop(nArgs);
|
423 | |
}
|
424 | |
@@ -756,7 +757,7 @@
|
425 | |
|
426 | |
status=(long)H5Tget_class((hid_t)type_id);
|
427 | |
|
428 | |
- PushIntValue(status);
|
429 | |
+ PushLongValue(status);
|
430 | |
PopTo(sp-nArgs-1);
|
431 | |
Drop(nArgs);
|
432 | |
}
|
433 | |
@@ -771,7 +772,7 @@
|
434 | |
|
435 | |
status=(long)H5Tget_size((hid_t)type_id);
|
436 | |
|
437 | |
- PushIntValue(status);
|
438 | |
+ PushLongValue(status);
|
439 | |
PopTo(sp-nArgs-1);
|
440 | |
Drop(nArgs);
|
441 | |
}
|
442 | |
@@ -788,7 +789,7 @@
|
443 | |
|
444 | |
status=(long)H5Tset_cset((hid_t)type_id, (H5T_cset_t)cset);
|
445 | |
|
446 | |
- PushIntValue(status);
|
447 | |
+ PushLongValue(status);
|
448 | |
PopTo(sp-nArgs-1);
|
449 | |
Drop(nArgs);
|
450 | |
}
|
451 | |
@@ -804,7 +805,7 @@
|
452 | |
|
453 | |
status=(long)H5Tset_size((hid_t)type_id, (size_t)size);
|
454 | |
|
455 | |
- PushIntValue(status);
|
456 | |
+ PushLongValue(status);
|
457 | |
PopTo(sp-nArgs-1);
|
458 | |
Drop(nArgs);
|
459 | |
}
|
460 | |
@@ -820,7 +821,7 @@
|
461 | |
|
462 | |
status=(long)H5Tset_strpad((hid_t)type_id, (H5T_str_t)strpad);
|
463 | |
|
464 | |
- PushIntValue(status);
|
465 | |
+ PushLongValue(status);
|
466 | |
PopTo(sp-nArgs-1);
|
467 | |
Drop(nArgs);
|
468 | |
}
|
469 | |
@@ -830,401 +831,401 @@
|
|
759 |
- status=(long)H5Tcopy((hid_t)type_id);
|
|
760 |
+ id=H5Tcopy(type_id);
|
|
761 |
|
|
762 |
- PushIntValue(status);
|
|
763 |
+ ypush_hid_t(id);
|
|
764 |
PopTo(sp-nArgs-1);
|
|
765 |
Drop(nArgs);
|
|
766 |
}
|
|
767 |
@@ -750,7 +854,7 @@
|
|
768 |
|
|
769 |
void Y__H5Tget_class(int nArgs)
|
|
770 |
{
|
|
771 |
- long type_id=YGetInteger(sp-nArgs+1);
|
|
772 |
+ hid_t type_id = ygets_hid_t(nArgs-1);
|
|
773 |
|
|
774 |
long status;
|
|
775 |
|
|
776 |
@@ -765,7 +869,7 @@
|
|
777 |
|
|
778 |
void Y__H5Tget_size(int nArgs)
|
|
779 |
{
|
|
780 |
- long type_id=YGetInteger(sp-nArgs+1);
|
|
781 |
+ hid_t type_id = ygets_hid_t(nArgs-1);
|
|
782 |
|
|
783 |
long status;
|
|
784 |
|
|
785 |
@@ -781,7 +885,7 @@
|
|
786 |
|
|
787 |
void Y__H5Tset_cset(int nArgs)
|
|
788 |
{
|
|
789 |
- long type_id=YGetInteger(sp-nArgs+1);
|
|
790 |
+ hid_t type_id = ygets_hid_t(nArgs-1);
|
|
791 |
long cset=YGetInteger(sp-nArgs+2);
|
|
792 |
|
|
793 |
long status;
|
|
794 |
@@ -797,7 +901,7 @@
|
|
795 |
|
|
796 |
void Y__H5Tset_size(int nArgs)
|
|
797 |
{
|
|
798 |
- long type_id=YGetInteger(sp-nArgs+1);
|
|
799 |
+ hid_t type_id = ygets_hid_t(nArgs-1);
|
|
800 |
long size=YGetInteger(sp-nArgs+2);
|
|
801 |
|
|
802 |
long status;
|
|
803 |
@@ -813,7 +917,7 @@
|
|
804 |
|
|
805 |
void Y__H5Tset_strpad(int nArgs)
|
|
806 |
{
|
|
807 |
- long type_id=YGetInteger(sp-nArgs+1);
|
|
808 |
+ hid_t type_id = ygets_hid_t(nArgs-1);
|
|
809 |
long strpad=YGetInteger(sp-nArgs+2);
|
|
810 |
|
|
811 |
long status;
|
|
812 |
@@ -830,247 +934,247 @@
|
470 | 813 |
|
471 | 814 |
void Y__H5T_C_S1(int nArgs)
|
472 | 815 |
{
|
473 | 816 |
- PushIntValue((long)H5T_C_S1);
|
474 | |
+ PushLongValue((long)H5T_C_S1);
|
|
817 |
+ ypush_hid_t(H5T_C_S1);
|
475 | 818 |
PopTo(sp-nArgs-1);
|
476 | 819 |
Drop(nArgs);
|
477 | 820 |
}
|
478 | 821 |
void Y__H5T_NATIVE_CHAR(int nArgs)
|
479 | 822 |
{
|
480 | 823 |
- PushIntValue((long)H5T_NATIVE_CHAR);
|
481 | |
+ PushLongValue((long)H5T_NATIVE_CHAR);
|
|
824 |
+ ypush_hid_t(H5T_NATIVE_CHAR);
|
482 | 825 |
PopTo(sp-nArgs-1);
|
483 | 826 |
Drop(nArgs);
|
484 | 827 |
}
|
485 | 828 |
void Y__H5T_NATIVE_SHORT(int nArgs)
|
486 | 829 |
{
|
487 | 830 |
- PushIntValue((long)H5T_NATIVE_SHORT);
|
488 | |
+ PushLongValue((long)H5T_NATIVE_SHORT);
|
|
831 |
+ ypush_hid_t(H5T_NATIVE_SHORT);
|
489 | 832 |
PopTo(sp-nArgs-1);
|
490 | 833 |
Drop(nArgs);
|
491 | 834 |
}
|
492 | 835 |
void Y__H5T_NATIVE_INT(int nArgs)
|
493 | 836 |
{
|
494 | 837 |
- PushIntValue((long)H5T_NATIVE_INT);
|
495 | |
+ PushLongValue((long)H5T_NATIVE_INT);
|
|
838 |
+ ypush_hid_t(H5T_NATIVE_INT);
|
496 | 839 |
PopTo(sp-nArgs-1);
|
497 | 840 |
Drop(nArgs);
|
498 | 841 |
}
|
499 | 842 |
void Y__H5T_NATIVE_LONG(int nArgs)
|
500 | 843 |
{
|
501 | 844 |
- PushIntValue((long)H5T_NATIVE_LONG);
|
502 | |
+ PushLongValue((long)H5T_NATIVE_LONG);
|
|
845 |
+ ypush_hid_t(H5T_NATIVE_LONG);
|
503 | 846 |
PopTo(sp-nArgs-1);
|
504 | 847 |
Drop(nArgs);
|
505 | 848 |
}
|
506 | 849 |
void Y__H5T_NATIVE_FLOAT(int nArgs)
|
507 | 850 |
{
|
508 | 851 |
- PushIntValue((long)H5T_NATIVE_FLOAT);
|
509 | |
+ PushLongValue((long)H5T_NATIVE_FLOAT);
|
|
852 |
+ ypush_hid_t(H5T_NATIVE_FLOAT);
|
510 | 853 |
PopTo(sp-nArgs-1);
|
511 | 854 |
Drop(nArgs);
|
512 | 855 |
}
|
513 | 856 |
void Y__H5T_NATIVE_DOUBLE(int nArgs)
|
514 | 857 |
{
|
515 | 858 |
- PushIntValue((long)H5T_NATIVE_DOUBLE);
|
516 | |
+ PushLongValue((long)H5T_NATIVE_DOUBLE);
|
|
859 |
+ ypush_hid_t(H5T_NATIVE_DOUBLE);
|
517 | 860 |
PopTo(sp-nArgs-1);
|
518 | 861 |
Drop(nArgs);
|
519 | 862 |
}
|
520 | 863 |
void Y__H5T_IEEE_F32BE(int nArgs)
|
521 | 864 |
{
|
522 | 865 |
- PushIntValue((long)H5T_IEEE_F32BE);
|
523 | |
+ PushLongValue((long)H5T_IEEE_F32BE);
|
|
866 |
+ ypush_hid_t(H5T_IEEE_F32BE);
|
524 | 867 |
PopTo(sp-nArgs-1);
|
525 | 868 |
Drop(nArgs);
|
526 | 869 |
}
|
527 | 870 |
void Y__H5T_IEEE_F32LE(int nArgs)
|
528 | 871 |
{
|
529 | 872 |
- PushIntValue((long)H5T_IEEE_F32LE);
|
530 | |
+ PushLongValue((long)H5T_IEEE_F32LE);
|
|
873 |
+ ypush_hid_t(H5T_IEEE_F32LE);
|
531 | 874 |
PopTo(sp-nArgs-1);
|
532 | 875 |
Drop(nArgs);
|
533 | 876 |
}
|
534 | 877 |
void Y__H5T_IEEE_F64BE(int nArgs)
|
535 | 878 |
{
|
536 | 879 |
- PushIntValue((long)H5T_IEEE_F64BE);
|
537 | |
+ PushLongValue((long)H5T_IEEE_F64BE);
|
|
880 |
+ ypush_hid_t(H5T_IEEE_F64BE);
|
538 | 881 |
PopTo(sp-nArgs-1);
|
539 | 882 |
Drop(nArgs);
|
540 | 883 |
}
|
541 | 884 |
void Y__H5T_IEEE_F64LE(int nArgs)
|
542 | 885 |
{
|
543 | 886 |
- PushIntValue((long)H5T_IEEE_F64LE);
|
544 | |
+ PushLongValue((long)H5T_IEEE_F64LE);
|
|
887 |
+ ypush_hid_t(H5T_IEEE_F64LE);
|
545 | 888 |
PopTo(sp-nArgs-1);
|
546 | 889 |
Drop(nArgs);
|
547 | 890 |
}
|
548 | 891 |
void Y__H5T_STD_I8BE(int nArgs)
|
549 | 892 |
{
|
550 | 893 |
- PushIntValue((long)H5T_STD_I8BE);
|
551 | |
+ PushLongValue((long)H5T_STD_I8BE);
|
|
894 |
+ ypush_hid_t(H5T_STD_I8BE);
|
552 | 895 |
PopTo(sp-nArgs-1);
|
553 | 896 |
Drop(nArgs);
|
554 | 897 |
}
|
555 | 898 |
void Y__H5T_STD_I8LE(int nArgs)
|
556 | 899 |
{
|
557 | 900 |
- PushIntValue((long)H5T_STD_I8LE);
|
558 | |
+ PushLongValue((long)H5T_STD_I8LE);
|
|
901 |
+ ypush_hid_t(H5T_STD_I8LE);
|
559 | 902 |
PopTo(sp-nArgs-1);
|
560 | 903 |
Drop(nArgs);
|
561 | 904 |
}
|
562 | 905 |
void Y__H5T_STD_I16BE(int nArgs)
|
563 | 906 |
{
|
564 | 907 |
- PushIntValue((long)H5T_STD_I16BE);
|
565 | |
+ PushLongValue((long)H5T_STD_I16BE);
|
|
908 |
+ ypush_hid_t(H5T_STD_I16BE);
|
566 | 909 |
PopTo(sp-nArgs-1);
|
567 | 910 |
Drop(nArgs);
|
568 | 911 |
}
|
569 | 912 |
void Y__H5T_STD_I16LE(int nArgs)
|
570 | 913 |
{
|
571 | 914 |
- PushIntValue((long)H5T_STD_I16LE);
|
572 | |
+ PushLongValue((long)H5T_STD_I16LE);
|
|
915 |
+ ypush_hid_t(H5T_STD_I16LE);
|
573 | 916 |
PopTo(sp-nArgs-1);
|
574 | 917 |
Drop(nArgs);
|
575 | 918 |
}
|
576 | 919 |
void Y__H5T_STD_I32BE(int nArgs)
|
577 | 920 |
{
|
578 | 921 |
- PushIntValue((long)H5T_STD_I32BE);
|
579 | |
+ PushLongValue((long)H5T_STD_I32BE);
|
|
922 |
+ ypush_hid_t(H5T_STD_I32BE);
|
580 | 923 |
PopTo(sp-nArgs-1);
|
581 | 924 |
Drop(nArgs);
|
582 | 925 |
}
|
583 | 926 |
void Y__H5T_STD_I32LE(int nArgs)
|
584 | 927 |
{
|
585 | 928 |
- PushIntValue((long)H5T_STD_I32LE);
|
586 | |
+ PushLongValue((long)H5T_STD_I32LE);
|
|
929 |
+ ypush_hid_t(H5T_STD_I32LE);
|
587 | 930 |
PopTo(sp-nArgs-1);
|
588 | 931 |
Drop(nArgs);
|
589 | 932 |
}
|
590 | 933 |
void Y__H5T_STD_I64BE(int nArgs)
|
591 | 934 |
{
|
592 | 935 |
- PushIntValue((long)H5T_STD_I64BE);
|
593 | |
+ PushLongValue((long)H5T_STD_I64BE);
|
|
936 |
+ ypush_hid_t(H5T_STD_I64BE);
|
594 | 937 |
PopTo(sp-nArgs-1);
|
595 | 938 |
Drop(nArgs);
|
596 | 939 |
}
|
597 | 940 |
void Y__H5T_STD_I64LE(int nArgs)
|
598 | 941 |
{
|
599 | 942 |
- PushIntValue((long)H5T_STD_I64LE);
|
600 | |
+ PushLongValue((long)H5T_STD_I64LE);
|
|
943 |
+ ypush_hid_t(H5T_STD_I64LE);
|
601 | 944 |
PopTo(sp-nArgs-1);
|
602 | 945 |
Drop(nArgs);
|
603 | 946 |
}
|
604 | 947 |
void Y__H5T_STD_U8BE(int nArgs)
|
605 | 948 |
{
|
606 | 949 |
- PushIntValue((long)H5T_STD_U8BE);
|
607 | |
+ PushLongValue((long)H5T_STD_U8BE);
|
|
950 |
+ ypush_hid_t(H5T_STD_U8BE);
|
608 | 951 |
PopTo(sp-nArgs-1);
|
609 | 952 |
Drop(nArgs);
|
610 | 953 |
}
|
611 | 954 |
void Y__H5T_STD_U8LE(int nArgs)
|
612 | 955 |
{
|
613 | 956 |
- PushIntValue((long)H5T_STD_U8LE);
|
614 | |
+ PushLongValue((long)H5T_STD_U8LE);
|
|
957 |
+ ypush_hid_t(H5T_STD_U8LE);
|
615 | 958 |
PopTo(sp-nArgs-1);
|
616 | 959 |
Drop(nArgs);
|
617 | 960 |
}
|
618 | 961 |
void Y__H5T_STD_U16BE(int nArgs)
|
619 | 962 |
{
|
620 | 963 |
- PushIntValue((long)H5T_STD_U16BE);
|
621 | |
+ PushLongValue((long)H5T_STD_U16BE);
|
|
964 |
+ ypush_hid_t(H5T_STD_U16BE);
|
622 | 965 |
PopTo(sp-nArgs-1);
|
623 | 966 |
Drop(nArgs);
|
624 | 967 |
}
|
625 | 968 |
void Y__H5T_STD_U16LE(int nArgs)
|
626 | 969 |
{
|
627 | 970 |
- PushIntValue((long)H5T_STD_U16LE);
|
628 | |
+ PushLongValue((long)H5T_STD_U16LE);
|
|
971 |
+ ypush_hid_t(H5T_STD_U16LE);
|
629 | 972 |
PopTo(sp-nArgs-1);
|
630 | 973 |
Drop(nArgs);
|
631 | 974 |
}
|
632 | 975 |
void Y__H5T_STD_U32BE(int nArgs)
|
633 | 976 |
{
|
634 | 977 |
- PushIntValue((long)H5T_STD_U32BE);
|
635 | |
+ PushLongValue((long)H5T_STD_U32BE);
|
|
978 |
+ ypush_hid_t(H5T_STD_U32BE);
|
636 | 979 |
PopTo(sp-nArgs-1);
|
637 | 980 |
Drop(nArgs);
|
638 | 981 |
}
|
639 | 982 |
void Y__H5T_STD_U32LE(int nArgs)
|
640 | 983 |
{
|
641 | 984 |
- PushIntValue((long)H5T_STD_U32LE);
|
642 | |
+ PushLongValue((long)H5T_STD_U32LE);
|
|
985 |
+ ypush_hid_t(H5T_STD_U32LE);
|
643 | 986 |
PopTo(sp-nArgs-1);
|
644 | 987 |
Drop(nArgs);
|
645 | 988 |
}
|
646 | 989 |
void Y__H5T_STD_U64BE(int nArgs)
|
647 | 990 |
{
|
648 | 991 |
- PushIntValue((long)H5T_STD_U64BE);
|
649 | |
+ PushLongValue((long)H5T_STD_U64BE);
|
|
992 |
+ ypush_hid_t(H5T_STD_U64BE);
|
650 | 993 |
PopTo(sp-nArgs-1);
|
651 | 994 |
Drop(nArgs);
|
652 | 995 |
}
|
653 | 996 |
void Y__H5T_STD_U64LE(int nArgs)
|
654 | 997 |
{
|
655 | 998 |
- PushIntValue((long)H5T_STD_U64LE);
|
656 | |
+ PushLongValue((long)H5T_STD_U64LE);
|
|
999 |
+ ypush_hid_t(H5T_STD_U64LE);
|
657 | 1000 |
PopTo(sp-nArgs-1);
|
658 | 1001 |
Drop(nArgs);
|
659 | 1002 |
}
|
660 | 1003 |
void Y__H5T_STD_B8BE(int nArgs)
|
661 | 1004 |
{
|
662 | 1005 |
- PushIntValue((long)H5T_STD_B8BE);
|
663 | |
+ PushLongValue((long)H5T_STD_B8BE);
|
|
1006 |
+ ypush_hid_t(H5T_STD_B8BE);
|
664 | 1007 |
PopTo(sp-nArgs-1);
|
665 | 1008 |
Drop(nArgs);
|
666 | 1009 |
}
|
667 | 1010 |
void Y__H5T_STD_B8LE(int nArgs)
|
668 | 1011 |
{
|
669 | 1012 |
- PushIntValue((long)H5T_STD_B8LE);
|
670 | |
+ PushLongValue((long)H5T_STD_B8LE);
|
|
1013 |
+ ypush_hid_t(H5T_STD_B8LE);
|
671 | 1014 |
PopTo(sp-nArgs-1);
|
672 | 1015 |
Drop(nArgs);
|
673 | 1016 |
}
|
674 | 1017 |
void Y__H5T_STD_B16BE(int nArgs)
|
675 | 1018 |
{
|
676 | 1019 |
- PushIntValue((long)H5T_STD_B16BE);
|
677 | |
+ PushLongValue((long)H5T_STD_B16BE);
|
|
1020 |
+ ypush_hid_t(H5T_STD_B16BE);
|
678 | 1021 |
PopTo(sp-nArgs-1);
|
679 | 1022 |
Drop(nArgs);
|
680 | 1023 |
}
|
681 | 1024 |
void Y__H5T_STD_B16LE(int nArgs)
|
682 | 1025 |
{
|
683 | 1026 |
- PushIntValue((long)H5T_STD_B16LE);
|
684 | |
+ PushLongValue((long)H5T_STD_B16LE);
|
|
1027 |
+ ypush_hid_t(H5T_STD_B16LE);
|
685 | 1028 |
PopTo(sp-nArgs-1);
|
686 | 1029 |
Drop(nArgs);
|
687 | 1030 |
}
|
688 | 1031 |
void Y__H5T_STD_B32BE(int nArgs)
|
689 | 1032 |
{
|
690 | 1033 |
- PushIntValue((long)H5T_STD_B32BE);
|
691 | |
+ PushLongValue((long)H5T_STD_B32BE);
|
|
1034 |
+ ypush_hid_t(H5T_STD_B32BE);
|
692 | 1035 |
PopTo(sp-nArgs-1);
|
693 | 1036 |
Drop(nArgs);
|
694 | 1037 |
}
|
695 | 1038 |
void Y__H5T_STD_B32LE(int nArgs)
|
696 | 1039 |
{
|
697 | 1040 |
- PushIntValue((long)H5T_STD_B32LE);
|
698 | |
+ PushLongValue((long)H5T_STD_B32LE);
|
|
1041 |
+ ypush_hid_t(H5T_STD_B32LE);
|
699 | 1042 |
PopTo(sp-nArgs-1);
|
700 | 1043 |
Drop(nArgs);
|
701 | 1044 |
}
|
702 | 1045 |
void Y__H5T_STD_B64BE(int nArgs)
|
703 | 1046 |
{
|
704 | 1047 |
- PushIntValue((long)H5T_STD_B64BE);
|
705 | |
+ PushLongValue((long)H5T_STD_B64BE);
|
|
1048 |
+ ypush_hid_t(H5T_STD_B64BE);
|
706 | 1049 |
PopTo(sp-nArgs-1);
|
707 | 1050 |
Drop(nArgs);
|
708 | 1051 |
}
|
709 | 1052 |
void Y__H5T_STD_B64LE(int nArgs)
|
710 | 1053 |
{
|
711 | 1054 |
- PushIntValue((long)H5T_STD_B64LE);
|
712 | |
+ PushLongValue((long)H5T_STD_B64LE);
|
|
1055 |
+ ypush_hid_t(H5T_STD_B64LE);
|
713 | 1056 |
PopTo(sp-nArgs-1);
|
714 | 1057 |
Drop(nArgs);
|
715 | 1058 |
}
|
716 | 1059 |
void Y__H5T_STD_REF_OBJ(int nArgs)
|
717 | 1060 |
{
|
718 | 1061 |
- PushIntValue((long)H5T_STD_REF_OBJ);
|
719 | |
+ PushLongValue((long)H5T_STD_REF_OBJ);
|
|
1062 |
+ ypush_hid_t(H5T_STD_REF_OBJ);
|
720 | 1063 |
PopTo(sp-nArgs-1);
|
721 | 1064 |
Drop(nArgs);
|
722 | 1065 |
}
|
723 | 1066 |
void Y__H5T_UNIX_D32BE(int nArgs)
|
724 | 1067 |
{
|
725 | 1068 |
- PushIntValue((long)H5T_UNIX_D32BE);
|
726 | |
+ PushLongValue((long)H5T_UNIX_D32BE);
|
|
1069 |
+ ypush_hid_t(H5T_UNIX_D32BE);
|
727 | 1070 |
PopTo(sp-nArgs-1);
|
728 | 1071 |
Drop(nArgs);
|
729 | 1072 |
}
|
730 | 1073 |
void Y__H5T_UNIX_D32LE(int nArgs)
|
731 | 1074 |
{
|
732 | 1075 |
- PushIntValue((long)H5T_UNIX_D32LE);
|
733 | |
+ PushLongValue((long)H5T_UNIX_D32LE);
|
|
1076 |
+ ypush_hid_t(H5T_UNIX_D32LE);
|
734 | 1077 |
PopTo(sp-nArgs-1);
|
735 | 1078 |
Drop(nArgs);
|
736 | 1079 |
}
|
737 | 1080 |
void Y__H5T_UNIX_D64BE(int nArgs)
|
738 | 1081 |
{
|
739 | 1082 |
- PushIntValue((long)H5T_UNIX_D64BE);
|
740 | |
+ PushLongValue((long)H5T_UNIX_D64BE);
|
|
1083 |
+ ypush_hid_t(H5T_UNIX_D64BE);
|
741 | 1084 |
PopTo(sp-nArgs-1);
|
742 | 1085 |
Drop(nArgs);
|
743 | 1086 |
}
|
744 | 1087 |
void Y__H5T_UNIX_D64LE(int nArgs)
|
745 | 1088 |
{
|
746 | 1089 |
- PushIntValue((long)H5T_UNIX_D64LE);
|
747 | |
+ PushLongValue((long)H5T_UNIX_D64LE);
|
|
1090 |
+ ypush_hid_t(H5T_UNIX_D64LE);
|
748 | 1091 |
PopTo(sp-nArgs-1);
|
749 | 1092 |
Drop(nArgs);
|
750 | 1093 |
}
|
751 | 1094 |
void Y__H5P_DATASET_CREATE(int nArgs)
|
752 | 1095 |
{
|
753 | 1096 |
- PushIntValue((long)H5P_DATASET_CREATE);
|
754 | |
+ PushLongValue((long)H5P_DATASET_CREATE);
|
755 | |
PopTo(sp-nArgs-1);
|
756 | |
Drop(nArgs);
|
757 | |
}
|
758 | |
|
759 | |
void Y__H5T_NO_CLASS(int nArgs)
|
760 | |
{
|
761 | |
- PushIntValue((long)H5T_NO_CLASS);
|
762 | |
+ PushLongValue((long)H5T_NO_CLASS);
|
763 | |
PopTo(sp-nArgs-1);
|
764 | |
Drop(nArgs);
|
765 | |
}
|
766 | |
|
767 | |
void Y__H5T_INTEGER(int nArgs)
|
768 | |
{
|
769 | |
- PushIntValue((long)H5T_INTEGER);
|
770 | |
+ PushLongValue((long)H5T_INTEGER);
|
771 | |
PopTo(sp-nArgs-1);
|
772 | |
Drop(nArgs);
|
773 | |
}
|
774 | |
|
775 | |
void Y__H5T_FLOAT(int nArgs)
|
776 | |
{
|
777 | |
- PushIntValue((long)H5T_FLOAT);
|
778 | |
+ PushLongValue((long)H5T_FLOAT);
|
779 | |
PopTo(sp-nArgs-1);
|
780 | |
Drop(nArgs);
|
781 | |
}
|
782 | |
|
783 | |
void Y__H5T_TIME(int nArgs)
|
784 | |
{
|
785 | |
- PushIntValue((long)H5T_TIME);
|
786 | |
+ PushLongValue((long)H5T_TIME);
|
787 | |
PopTo(sp-nArgs-1);
|
788 | |
Drop(nArgs);
|
789 | |
}
|
790 | |
|
791 | |
void Y__H5T_STRING(int nArgs)
|
792 | |
{
|
793 | |
- PushIntValue((long)H5T_STRING);
|
794 | |
+ PushLongValue((long)H5T_STRING);
|
795 | |
PopTo(sp-nArgs-1);
|
796 | |
Drop(nArgs);
|
797 | |
}
|
798 | |
|
799 | |
void Y__H5T_BITFIELD(int nArgs)
|
800 | |
{
|
801 | |
- PushIntValue((long)H5T_BITFIELD);
|
802 | |
+ PushLongValue((long)H5T_BITFIELD);
|
803 | |
PopTo(sp-nArgs-1);
|
804 | |
Drop(nArgs);
|
805 | |
}
|
806 | |
|
807 | |
void Y__H5T_OPAQUE(int nArgs)
|
808 | |
{
|
809 | |
- PushIntValue((long)H5T_OPAQUE);
|
810 | |
+ PushLongValue((long)H5T_OPAQUE);
|
811 | |
PopTo(sp-nArgs-1);
|
812 | |
Drop(nArgs);
|
813 | |
}
|
814 | |
|
815 | |
void Y__H5T_COMPOUND(int nArgs)
|
816 | |
{
|
817 | |
- PushIntValue((long)H5T_COMPOUND);
|
818 | |
+ PushLongValue((long)H5T_COMPOUND);
|
819 | |
PopTo(sp-nArgs-1);
|
820 | |
Drop(nArgs);
|
821 | |
}
|
822 | |
|
823 | |
void Y__H5T_REFERENCE(int nArgs)
|
824 | |
{
|
825 | |
- PushIntValue((long)H5T_REFERENCE);
|
826 | |
+ PushLongValue((long)H5T_REFERENCE);
|
827 | |
PopTo(sp-nArgs-1);
|
828 | |
Drop(nArgs);
|
829 | |
}
|
830 | |
|
831 | |
void Y__H5T_ENUM(int nArgs)
|
832 | |
{
|
833 | |
- PushIntValue((long)H5T_ENUM);
|
834 | |
+ PushLongValue((long)H5T_ENUM);
|
835 | |
PopTo(sp-nArgs-1);
|
836 | |
Drop(nArgs);
|
837 | |
}
|
838 | |
|
839 | |
void Y__H5T_VLEN(int nArgs)
|
840 | |
{
|
841 | |
- PushIntValue((long)H5T_VLEN);
|
842 | |
+ PushLongValue((long)H5T_VLEN);
|
843 | |
PopTo(sp-nArgs-1);
|
844 | |
Drop(nArgs);
|
845 | |
}
|
846 | |
|
847 | |
void Y__H5T_ARRAY(int nArgs)
|
848 | |
{
|
849 | |
- PushIntValue((long)H5T_ARRAY);
|
850 | |
+ PushLongValue((long)H5T_ARRAY);
|
851 | |
PopTo(sp-nArgs-1);
|
852 | |
Drop(nArgs);
|
853 | |
}
|
854 | |
|
855 | |
void Y__H5G_UNKNOWN(int nArgs)
|
856 | |
{
|
857 | |
- PushIntValue((long)H5G_UNKNOWN);
|
858 | |
+ PushLongValue((long)H5G_UNKNOWN);
|
859 | |
PopTo(sp-nArgs-1);
|
860 | |
Drop(nArgs);
|
861 | |
}
|
862 | |
|
863 | |
void Y__H5G_GROUP(int nArgs)
|
864 | |
{
|
865 | |
- PushIntValue((long)H5G_GROUP);
|
866 | |
+ PushLongValue((long)H5G_GROUP);
|
867 | |
PopTo(sp-nArgs-1);
|
868 | |
Drop(nArgs);
|
869 | |
}
|
870 | |
|
871 | |
void Y__H5G_DATASET(int nArgs)
|
872 | |
{
|
873 | |
- PushIntValue((long)H5G_DATASET);
|
874 | |
+ PushLongValue((long)H5G_DATASET);
|
875 | |
PopTo(sp-nArgs-1);
|
876 | |
Drop(nArgs);
|
877 | |
}
|
878 | |
|
879 | |
void Y__H5G_TYPE(int nArgs)
|
880 | |
{
|
881 | |
- PushIntValue((long)H5G_TYPE);
|
882 | |
+ PushLongValue((long)H5G_TYPE);
|
883 | |
PopTo(sp-nArgs-1);
|
884 | |
Drop(nArgs);
|
885 | |
}
|
886 | |
|
887 | |
void Y__H5G_LINK(int nArgs)
|
888 | |
{
|
889 | |
- PushIntValue((long)H5G_LINK);
|
890 | |
+ PushLongValue((long)H5G_LINK);
|
891 | |
PopTo(sp-nArgs-1);
|
892 | |
Drop(nArgs);
|
893 | |
}
|
894 | |
|
895 | |
void Y__H5P_DEFAULT(int nArgs)
|
896 | |
{
|
897 | |
- PushIntValue((long)H5P_DEFAULT);
|
898 | |
+ PushLongValue((long)H5P_DEFAULT);
|
899 | |
PopTo(sp-nArgs-1);
|
900 | |
Drop(nArgs);
|
901 | |
}
|
902 | |
|
903 | |
/*void Y__H5T_DEFAULT(int nArgs)
|
904 | |
{
|
905 | |
- PushIntValue((long)H5T_DEFAULT);
|
906 | |
+ PushLongValue((long)H5T_DEFAULT);
|
907 | |
PopTo(sp-nArgs-1);
|
908 | |
Drop(nArgs);
|
909 | |
}*/
|
910 | |
|
911 | |
void Y__H5S_NO_CLASS(int nArgs)
|
912 | |
{
|
913 | |
- PushIntValue((long)H5S_NO_CLASS);
|
914 | |
+ PushLongValue((long)H5S_NO_CLASS);
|
915 | |
PopTo(sp-nArgs-1);
|
916 | |
Drop(nArgs);
|
917 | |
}
|
918 | |
|
919 | |
void Y__H5S_SCALAR(int nArgs)
|
920 | |
{
|
921 | |
- PushIntValue((long)H5S_SCALAR);
|
922 | |
+ PushLongValue((long)H5S_SCALAR);
|
923 | |
PopTo(sp-nArgs-1);
|
924 | |
Drop(nArgs);
|
925 | |
}
|
926 | |
|
927 | |
void Y__H5S_SIMPLE(int nArgs)
|
928 | |
{
|
929 | |
- PushIntValue((long)H5S_SIMPLE);
|
930 | |
+ PushLongValue((long)H5S_SIMPLE);
|
931 | |
PopTo(sp-nArgs-1);
|
932 | |
Drop(nArgs);
|
933 | |
}
|
|
1097 |
+ ypush_hid_t(H5P_DATASET_CREATE);
|
|
1098 |
PopTo(sp-nArgs-1);
|
|
1099 |
Drop(nArgs);
|
|
1100 |
}
|
|
1101 |
--- a/hdf5.i
|
|
1102 |
+++ b/hdf5.i
|
|
1103 |
@@ -778,11 +778,10 @@
|
|
1104 |
gid = _H5Gopen(file,g(1:i)(sum));
|
|
1105 |
if (gid<0) {
|
|
1106 |
gid = _H5Gcreate(file,g(1:i)(sum),0);
|
|
1107 |
- status=_H5Gclose(gid);
|
|
1108 |
- }
|
|
1109 |
- if (gid<0) {
|
|
1110 |
- if (has2bclose) h5close,file;
|
|
1111 |
- error,"Unable to create group";
|
|
1112 |
+ if (gid<0) {
|
|
1113 |
+ if (has2bclose) h5close,file;
|
|
1114 |
+ error,"Unable to create group";
|
|
1115 |
+ }
|
|
1116 |
}
|
|
1117 |
status=_H5Gclose(gid);
|
|
1118 |
}
|