-
Notifications
You must be signed in to change notification settings - Fork 1
/
xnd_structinfo.c
2589 lines (2575 loc) · 183 KB
/
xnd_structinfo.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/* This file is generated using structinfo_generator from the xndtools project */
#include "pyndtypes.h"
#include "pyxnd.h"
#include "pygumath.h"
extern PyObject* ndt_from_type(ndt_t* val) { return Ndt_FromType(val); }
extern PyObject* xnd_from_type_xnd(PyTypeObject* t, xnd_t* val) { return Xnd_FromXnd(t, val); };
extern PyObject* xnd_view_move_ndt(const PyObject *v, ndt_t *t) { return Xnd_ViewMoveNdt(v, t); };
extern PyObject* xnd_from_xnd_view(xnd_view_t *v) {return Xnd_FromXndView(v); };
//extern PyObject* xnd_from_xndonly(xnd_t *val) { return Xnd_FromXndOnly(val); };
extern void print_bytes(const void *object, size_t size)
{
// This is for C++; in C just drop the static_cast<>() and assign.
const unsigned char *const bytes = object;
size_t i;
printf("Bytes: [ ");
for (i = 0; i < size; i++)
{
printf("%lld ", (int64_t)bytes[i]);
}
printf("]\n");
const int64_t *bytes2 = object;
size_t i2;
printf("Ints: [ ");
for (i2 = 0; i2 < (size / 8); i2++)
{
printf("%lld ", bytes2[i2]);
}
printf("]\n\n");
}
extern size_t sizeof_char_opt_t(void){ return sizeof(char_opt_t); }
extern /* pointer to `enum ndt_option` */ void * get_char_opt_t_tag(void* ptr){ return &(((char_opt_t*)ptr)->tag); }
extern size_t offsetof_char_opt_t_tag(void){ return offsetof(char_opt_t, tag); }
extern /* pointer to `char` */ void * get_char_opt_t_Some(void* ptr){ return &(((char_opt_t*)ptr)->Some); }
extern size_t offsetof_char_opt_t_Some(void){ return offsetof(char_opt_t, Some); }
extern size_t sizeof_int64_opt_t(void){ return sizeof(int64_opt_t); }
extern /* pointer to `enum ndt_option` */ void * get_int64_opt_t_tag(void* ptr){ return &(((int64_opt_t*)ptr)->tag); }
extern size_t offsetof_int64_opt_t_tag(void){ return offsetof(int64_opt_t, tag); }
extern /* pointer to `int64_t` */ void * get_int64_opt_t_Some(void* ptr){ return &(((int64_opt_t*)ptr)->Some); }
extern size_t offsetof_int64_opt_t_Some(void){ return offsetof(int64_opt_t, Some); }
extern size_t sizeof_uint16_opt_t(void){ return sizeof(uint16_opt_t); }
extern /* pointer to `enum ndt_option` */ void * get_uint16_opt_t_tag(void* ptr){ return &(((uint16_opt_t*)ptr)->tag); }
extern size_t offsetof_uint16_opt_t_tag(void){ return offsetof(uint16_opt_t, tag); }
extern /* pointer to `uint16_t` */ void * get_uint16_opt_t_Some(void* ptr){ return &(((uint16_opt_t*)ptr)->Some); }
extern size_t offsetof_uint16_opt_t_Some(void){ return offsetof(uint16_opt_t, Some); }
extern size_t sizeof_ndt_meta_t(void){ return sizeof(ndt_meta_t); }
extern /* pointer to `int` */ void * get_ndt_meta_t_ndims(void* ptr){ return &(((ndt_meta_t*)ptr)->ndims); }
extern size_t offsetof_ndt_meta_t_ndims(void){ return offsetof(ndt_meta_t, ndims); }
extern /* pointer to `int32_t*` */ void * get_ndt_meta_t_noffsets(void* ptr){ return &(((ndt_meta_t*)ptr)->noffsets); }
extern size_t offsetof_ndt_meta_t_noffsets(void){ return offsetof(ndt_meta_t, noffsets); }
extern /* pointer to `int32_t**` */ void * get_ndt_meta_t_offsets(void* ptr){ return &(((ndt_meta_t*)ptr)->offsets); }
extern size_t offsetof_ndt_meta_t_offsets(void){ return offsetof(ndt_meta_t, offsets); }
extern size_t sizeof_ndt_field_t(void){ return sizeof(ndt_field_t); }
extern /* pointer to `enum ndt_access` */ void * get_ndt_field_t_access(void* ptr){ return &(((ndt_field_t*)ptr)->access); }
extern size_t offsetof_ndt_field_t_access(void){ return offsetof(ndt_field_t, access); }
extern /* pointer to `char*` */ void * get_ndt_field_t_name(void* ptr){ return &(((ndt_field_t*)ptr)->name); }
extern size_t offsetof_ndt_field_t_name(void){ return offsetof(ndt_field_t, name); }
extern /* pointer to `ndt_t*` */ void * get_ndt_field_t_type(void* ptr){ return &(((ndt_field_t*)ptr)->type); }
extern size_t offsetof_ndt_field_t_type(void){ return offsetof(ndt_field_t, type); }
extern /* pointer to `uint16_t` */ void * get_ndt_field_t_Concrete_align(void* ptr){ return &(((ndt_field_t*)ptr)->Concrete.align); }
extern size_t offsetof_ndt_field_t_Concrete_align(void){ return offsetof(ndt_field_t, Concrete.align); }
extern /* pointer to `bool` */ void * get_ndt_field_t_Concrete_explicit_align(void* ptr){ return &(((ndt_field_t*)ptr)->Concrete.explicit_align); }
extern size_t offsetof_ndt_field_t_Concrete_explicit_align(void){ return offsetof(ndt_field_t, Concrete.explicit_align); }
extern /* pointer to `uint16_t` */ void * get_ndt_field_t_Concrete_pad(void* ptr){ return &(((ndt_field_t*)ptr)->Concrete.pad); }
extern size_t offsetof_ndt_field_t_Concrete_pad(void){ return offsetof(ndt_field_t, Concrete.pad); }
extern /* pointer to `bool` */ void * get_ndt_field_t_Concrete_explicit_pad(void* ptr){ return &(((ndt_field_t*)ptr)->Concrete.explicit_pad); }
extern size_t offsetof_ndt_field_t_Concrete_explicit_pad(void){ return offsetof(ndt_field_t, Concrete.explicit_pad); }
extern size_t sizeof_ndt_value_t(void){ return sizeof(ndt_value_t); }
extern /* pointer to `enum ndt_value` */ void * get_ndt_value_t_tag(void* ptr){ return &(((ndt_value_t*)ptr)->tag); }
extern size_t offsetof_ndt_value_t_tag(void){ return offsetof(ndt_value_t, tag); }
extern /* pointer to `bool` */ void * get_ndt_value_t_ValBool(void* ptr){ return &(((ndt_value_t*)ptr)->ValBool); }
extern size_t offsetof_ndt_value_t_ValBool(void){ return offsetof(ndt_value_t, ValBool); }
extern /* pointer to `int64_t` */ void * get_ndt_value_t_ValInt64(void* ptr){ return &(((ndt_value_t*)ptr)->ValInt64); }
extern size_t offsetof_ndt_value_t_ValInt64(void){ return offsetof(ndt_value_t, ValInt64); }
extern /* pointer to `double` */ void * get_ndt_value_t_ValFloat64(void* ptr){ return &(((ndt_value_t*)ptr)->ValFloat64); }
extern size_t offsetof_ndt_value_t_ValFloat64(void){ return offsetof(ndt_value_t, ValFloat64); }
extern /* pointer to `char*` */ void * get_ndt_value_t_ValString(void* ptr){ return &(((ndt_value_t*)ptr)->ValString); }
extern size_t offsetof_ndt_value_t_ValString(void){ return offsetof(ndt_value_t, ValString); }
extern size_t sizeof_ndt_slice_t(void){ return sizeof(ndt_slice_t); }
extern /* pointer to `int64_t` */ void * get_ndt_slice_t_start(void* ptr){ return &(((ndt_slice_t*)ptr)->start); }
extern size_t offsetof_ndt_slice_t_start(void){ return offsetof(ndt_slice_t, start); }
extern /* pointer to `int64_t` */ void * get_ndt_slice_t_stop(void* ptr){ return &(((ndt_slice_t*)ptr)->stop); }
extern size_t offsetof_ndt_slice_t_stop(void){ return offsetof(ndt_slice_t, stop); }
extern /* pointer to `int64_t` */ void * get_ndt_slice_t_step(void* ptr){ return &(((ndt_slice_t*)ptr)->step); }
extern size_t offsetof_ndt_slice_t_step(void){ return offsetof(ndt_slice_t, step); }
extern size_t sizeof_ndt_constraint_t(void){ return sizeof(ndt_constraint_t); }
extern /* pointer to `ndt_func_constraint_t` */ void * get_ndt_constraint_t_f(void* ptr){ return &(((ndt_constraint_t*)ptr)->f); }
extern size_t offsetof_ndt_constraint_t_f(void){ return offsetof(ndt_constraint_t, f); }
extern /* pointer to `int` */ void * get_ndt_constraint_t_nin(void* ptr){ return &(((ndt_constraint_t*)ptr)->nin); }
extern size_t offsetof_ndt_constraint_t_nin(void){ return offsetof(ndt_constraint_t, nin); }
extern /* pointer to `int` */ void * get_ndt_constraint_t_nout(void* ptr){ return &(((ndt_constraint_t*)ptr)->nout); }
extern size_t offsetof_ndt_constraint_t_nout(void){ return offsetof(ndt_constraint_t, nout); }
extern /* pointer to `const char**` */ void * get_ndt_constraint_t_symbols(void* ptr){ return &(((ndt_constraint_t*)ptr)->symbols); }
extern size_t offsetof_ndt_constraint_t_symbols(void){ return offsetof(ndt_constraint_t, symbols); }
extern size_t sizeof_ndt_methods_t(void){ return sizeof(ndt_methods_t); }
extern /* pointer to `ndt_init_t` */ void * get_ndt_methods_t_init(void* ptr){ return &(((ndt_methods_t*)ptr)->init); }
extern size_t offsetof_ndt_methods_t_init(void){ return offsetof(ndt_methods_t, init); }
extern /* pointer to `ndt_tdef_constraint_t` */ void * get_ndt_methods_t_constraint(void* ptr){ return &(((ndt_methods_t*)ptr)->constraint); }
extern size_t offsetof_ndt_methods_t_constraint(void){ return offsetof(ndt_methods_t, constraint); }
extern /* pointer to `ndt_repr_t` */ void * get_ndt_methods_t_repr(void* ptr){ return &(((ndt_methods_t*)ptr)->repr); }
extern size_t offsetof_ndt_methods_t_repr(void){ return offsetof(ndt_methods_t, repr); }
extern size_t sizeof_ndt_t(void){ return sizeof(ndt_t); }
extern /* pointer to `enum ndt` */ void * get_ndt_t_tag(void* ptr){ return &(((ndt_t*)ptr)->tag); }
extern size_t offsetof_ndt_t_tag(void){ return offsetof(ndt_t, tag); }
extern /* pointer to `enum ndt_access` */ void * get_ndt_t_access(void* ptr){ return &(((ndt_t*)ptr)->access); }
extern size_t offsetof_ndt_t_access(void){ return offsetof(ndt_t, access); }
extern /* pointer to `uint32_t` */ void * get_ndt_t_flags(void* ptr){ return &(((ndt_t*)ptr)->flags); }
extern size_t offsetof_ndt_t_flags(void){ return offsetof(ndt_t, flags); }
extern /* pointer to `int` */ void * get_ndt_t_ndim(void* ptr){ return &(((ndt_t*)ptr)->ndim); }
extern size_t offsetof_ndt_t_ndim(void){ return offsetof(ndt_t, ndim); }
extern /* pointer to `int64_t` */ void * get_ndt_t_datasize(void* ptr){ return &(((ndt_t*)ptr)->datasize); }
extern size_t offsetof_ndt_t_datasize(void){ return offsetof(ndt_t, datasize); }
extern /* pointer to `uint16_t` */ void * get_ndt_t_align(void* ptr){ return &(((ndt_t*)ptr)->align); }
extern size_t offsetof_ndt_t_align(void){ return offsetof(ndt_t, align); }
extern /* pointer to `char*` */ void * get_ndt_t_Module_name(void* ptr){ return &(((ndt_t*)ptr)->Module.name); }
extern size_t offsetof_ndt_t_Module_name(void){ return offsetof(ndt_t, Module.name); }
extern /* pointer to `ndt_t*` */ void * get_ndt_t_Module_type(void* ptr){ return &(((ndt_t*)ptr)->Module.type); }
extern size_t offsetof_ndt_t_Module_type(void){ return offsetof(ndt_t, Module.type); }
extern /* pointer to `bool` */ void * get_ndt_t_Function_elemwise(void* ptr){ return &(((ndt_t*)ptr)->Function.elemwise); }
extern size_t offsetof_ndt_t_Function_elemwise(void){ return offsetof(ndt_t, Function.elemwise); }
extern /* pointer to `int64_t` */ void * get_ndt_t_Function_nin(void* ptr){ return &(((ndt_t*)ptr)->Function.nin); }
extern size_t offsetof_ndt_t_Function_nin(void){ return offsetof(ndt_t, Function.nin); }
extern /* pointer to `int64_t` */ void * get_ndt_t_Function_nout(void* ptr){ return &(((ndt_t*)ptr)->Function.nout); }
extern size_t offsetof_ndt_t_Function_nout(void){ return offsetof(ndt_t, Function.nout); }
extern /* pointer to `int64_t` */ void * get_ndt_t_Function_nargs(void* ptr){ return &(((ndt_t*)ptr)->Function.nargs); }
extern size_t offsetof_ndt_t_Function_nargs(void){ return offsetof(ndt_t, Function.nargs); }
extern /* pointer to `ndt_t**` */ void * get_ndt_t_Function_types(void* ptr){ return &(((ndt_t*)ptr)->Function.types); }
extern size_t offsetof_ndt_t_Function_types(void){ return offsetof(ndt_t, Function.types); }
extern /* pointer to `int64_t` */ void * get_ndt_t_FixedDim_shape(void* ptr){ return &(((ndt_t*)ptr)->FixedDim.shape); }
extern size_t offsetof_ndt_t_FixedDim_shape(void){ return offsetof(ndt_t, FixedDim.shape); }
extern /* pointer to `ndt_t*` */ void * get_ndt_t_FixedDim_type(void* ptr){ return &(((ndt_t*)ptr)->FixedDim.type); }
extern size_t offsetof_ndt_t_FixedDim_type(void){ return offsetof(ndt_t, FixedDim.type); }
extern /* pointer to `ndt_t*` */ void * get_ndt_t_VarDim_type(void* ptr){ return &(((ndt_t*)ptr)->VarDim.type); }
extern size_t offsetof_ndt_t_VarDim_type(void){ return offsetof(ndt_t, VarDim.type); }
extern /* pointer to `char*` */ void * get_ndt_t_SymbolicDim_name(void* ptr){ return &(((ndt_t*)ptr)->SymbolicDim.name); }
extern size_t offsetof_ndt_t_SymbolicDim_name(void){ return offsetof(ndt_t, SymbolicDim.name); }
extern /* pointer to `ndt_t*` */ void * get_ndt_t_SymbolicDim_type(void* ptr){ return &(((ndt_t*)ptr)->SymbolicDim.type); }
extern size_t offsetof_ndt_t_SymbolicDim_type(void){ return offsetof(ndt_t, SymbolicDim.type); }
extern /* pointer to `char*` */ void * get_ndt_t_EllipsisDim_name(void* ptr){ return &(((ndt_t*)ptr)->EllipsisDim.name); }
extern size_t offsetof_ndt_t_EllipsisDim_name(void){ return offsetof(ndt_t, EllipsisDim.name); }
extern /* pointer to `ndt_t*` */ void * get_ndt_t_EllipsisDim_type(void* ptr){ return &(((ndt_t*)ptr)->EllipsisDim.type); }
extern size_t offsetof_ndt_t_EllipsisDim_type(void){ return offsetof(ndt_t, EllipsisDim.type); }
extern /* pointer to `enum ndt_variadic` */ void * get_ndt_t_Tuple_flag(void* ptr){ return &(((ndt_t*)ptr)->Tuple.flag); }
extern size_t offsetof_ndt_t_Tuple_flag(void){ return offsetof(ndt_t, Tuple.flag); }
extern /* pointer to `int64_t` */ void * get_ndt_t_Tuple_shape(void* ptr){ return &(((ndt_t*)ptr)->Tuple.shape); }
extern size_t offsetof_ndt_t_Tuple_shape(void){ return offsetof(ndt_t, Tuple.shape); }
extern /* pointer to `ndt_t**` */ void * get_ndt_t_Tuple_types(void* ptr){ return &(((ndt_t*)ptr)->Tuple.types); }
extern size_t offsetof_ndt_t_Tuple_types(void){ return offsetof(ndt_t, Tuple.types); }
extern /* pointer to `enum ndt_variadic` */ void * get_ndt_t_Record_flag(void* ptr){ return &(((ndt_t*)ptr)->Record.flag); }
extern size_t offsetof_ndt_t_Record_flag(void){ return offsetof(ndt_t, Record.flag); }
extern /* pointer to `int64_t` */ void * get_ndt_t_Record_shape(void* ptr){ return &(((ndt_t*)ptr)->Record.shape); }
extern size_t offsetof_ndt_t_Record_shape(void){ return offsetof(ndt_t, Record.shape); }
extern /* pointer to `char**` */ void * get_ndt_t_Record_names(void* ptr){ return &(((ndt_t*)ptr)->Record.names); }
extern size_t offsetof_ndt_t_Record_names(void){ return offsetof(ndt_t, Record.names); }
extern /* pointer to `ndt_t**` */ void * get_ndt_t_Record_types(void* ptr){ return &(((ndt_t*)ptr)->Record.types); }
extern size_t offsetof_ndt_t_Record_types(void){ return offsetof(ndt_t, Record.types); }
extern /* pointer to `ndt_t*` */ void * get_ndt_t_Ref_type(void* ptr){ return &(((ndt_t*)ptr)->Ref.type); }
extern size_t offsetof_ndt_t_Ref_type(void){ return offsetof(ndt_t, Ref.type); }
extern /* pointer to `char*` */ void * get_ndt_t_Constr_name(void* ptr){ return &(((ndt_t*)ptr)->Constr.name); }
extern size_t offsetof_ndt_t_Constr_name(void){ return offsetof(ndt_t, Constr.name); }
extern /* pointer to `ndt_t*` */ void * get_ndt_t_Constr_type(void* ptr){ return &(((ndt_t*)ptr)->Constr.type); }
extern size_t offsetof_ndt_t_Constr_type(void){ return offsetof(ndt_t, Constr.type); }
extern /* pointer to `char*` */ void * get_ndt_t_Nominal_name(void* ptr){ return &(((ndt_t*)ptr)->Nominal.name); }
extern size_t offsetof_ndt_t_Nominal_name(void){ return offsetof(ndt_t, Nominal.name); }
extern /* pointer to `ndt_t*` */ void * get_ndt_t_Nominal_type(void* ptr){ return &(((ndt_t*)ptr)->Nominal.type); }
extern size_t offsetof_ndt_t_Nominal_type(void){ return offsetof(ndt_t, Nominal.type); }
extern /* pointer to `const ndt_methods_t*` */ void * get_ndt_t_Nominal_meth(void* ptr){ return &(((ndt_t*)ptr)->Nominal.meth); }
extern size_t offsetof_ndt_t_Nominal_meth(void){ return offsetof(ndt_t, Nominal.meth); }
extern /* pointer to `int64_t` */ void * get_ndt_t_Categorical_ntypes(void* ptr){ return &(((ndt_t*)ptr)->Categorical.ntypes); }
extern size_t offsetof_ndt_t_Categorical_ntypes(void){ return offsetof(ndt_t, Categorical.ntypes); }
extern /* pointer to `ndt_value_t*` */ void * get_ndt_t_Categorical_types(void* ptr){ return &(((ndt_t*)ptr)->Categorical.types); }
extern size_t offsetof_ndt_t_Categorical_types(void){ return offsetof(ndt_t, Categorical.types); }
extern /* pointer to `int64_t` */ void * get_ndt_t_FixedString_size(void* ptr){ return &(((ndt_t*)ptr)->FixedString.size); }
extern size_t offsetof_ndt_t_FixedString_size(void){ return offsetof(ndt_t, FixedString.size); }
extern /* pointer to `enum ndt_encoding` */ void * get_ndt_t_FixedString_encoding(void* ptr){ return &(((ndt_t*)ptr)->FixedString.encoding); }
extern size_t offsetof_ndt_t_FixedString_encoding(void){ return offsetof(ndt_t, FixedString.encoding); }
extern /* pointer to `int64_t` */ void * get_ndt_t_FixedBytes_size(void* ptr){ return &(((ndt_t*)ptr)->FixedBytes.size); }
extern size_t offsetof_ndt_t_FixedBytes_size(void){ return offsetof(ndt_t, FixedBytes.size); }
extern /* pointer to `uint16_t` */ void * get_ndt_t_FixedBytes_align(void* ptr){ return &(((ndt_t*)ptr)->FixedBytes.align); }
extern size_t offsetof_ndt_t_FixedBytes_align(void){ return offsetof(ndt_t, FixedBytes.align); }
extern /* pointer to `uint16_t` */ void * get_ndt_t_Bytes_target_align(void* ptr){ return &(((ndt_t*)ptr)->Bytes.target_align); }
extern size_t offsetof_ndt_t_Bytes_target_align(void){ return offsetof(ndt_t, Bytes.target_align); }
extern /* pointer to `enum ndt_encoding` */ void * get_ndt_t_Char_encoding(void* ptr){ return &(((ndt_t*)ptr)->Char.encoding); }
extern size_t offsetof_ndt_t_Char_encoding(void){ return offsetof(ndt_t, Char.encoding); }
extern /* pointer to `char*` */ void * get_ndt_t_Typevar_name(void* ptr){ return &(((ndt_t*)ptr)->Typevar.name); }
extern size_t offsetof_ndt_t_Typevar_name(void){ return offsetof(ndt_t, Typevar.name); }
extern /* pointer to `int64_t` */ void * get_ndt_t_Concrete_FixedDim_itemsize(void* ptr){ return &(((ndt_t*)ptr)->Concrete.FixedDim.itemsize); }
extern size_t offsetof_ndt_t_Concrete_FixedDim_itemsize(void){ return offsetof(ndt_t, Concrete.FixedDim.itemsize); }
extern /* pointer to `int64_t` */ void * get_ndt_t_Concrete_FixedDim_step(void* ptr){ return &(((ndt_t*)ptr)->Concrete.FixedDim.step); }
extern size_t offsetof_ndt_t_Concrete_FixedDim_step(void){ return offsetof(ndt_t, Concrete.FixedDim.step); }
extern /* pointer to `enum ndt_offsets` */ void * get_ndt_t_Concrete_VarDim_flag(void* ptr){ return &(((ndt_t*)ptr)->Concrete.VarDim.flag); }
extern size_t offsetof_ndt_t_Concrete_VarDim_flag(void){ return offsetof(ndt_t, Concrete.VarDim.flag); }
extern /* pointer to `int64_t` */ void * get_ndt_t_Concrete_VarDim_itemsize(void* ptr){ return &(((ndt_t*)ptr)->Concrete.VarDim.itemsize); }
extern size_t offsetof_ndt_t_Concrete_VarDim_itemsize(void){ return offsetof(ndt_t, Concrete.VarDim.itemsize); }
extern /* pointer to `int32_t` */ void * get_ndt_t_Concrete_VarDim_noffsets(void* ptr){ return &(((ndt_t*)ptr)->Concrete.VarDim.noffsets); }
extern size_t offsetof_ndt_t_Concrete_VarDim_noffsets(void){ return offsetof(ndt_t, Concrete.VarDim.noffsets); }
extern /* pointer to `const int32_t*` */ void * get_ndt_t_Concrete_VarDim_offsets(void* ptr){ return &(((ndt_t*)ptr)->Concrete.VarDim.offsets); }
extern size_t offsetof_ndt_t_Concrete_VarDim_offsets(void){ return offsetof(ndt_t, Concrete.VarDim.offsets); }
extern /* pointer to `int` */ void * get_ndt_t_Concrete_VarDim_nslices(void* ptr){ return &(((ndt_t*)ptr)->Concrete.VarDim.nslices); }
extern size_t offsetof_ndt_t_Concrete_VarDim_nslices(void){ return offsetof(ndt_t, Concrete.VarDim.nslices); }
extern /* pointer to `ndt_slice_t*` */ void * get_ndt_t_Concrete_VarDim_slices(void* ptr){ return &(((ndt_t*)ptr)->Concrete.VarDim.slices); }
extern size_t offsetof_ndt_t_Concrete_VarDim_slices(void){ return offsetof(ndt_t, Concrete.VarDim.slices); }
extern /* pointer to `int64_t*` */ void * get_ndt_t_Concrete_Tuple_offset(void* ptr){ return &(((ndt_t*)ptr)->Concrete.Tuple.offset); }
extern size_t offsetof_ndt_t_Concrete_Tuple_offset(void){ return offsetof(ndt_t, Concrete.Tuple.offset); }
extern /* pointer to `uint16_t*` */ void * get_ndt_t_Concrete_Tuple_align(void* ptr){ return &(((ndt_t*)ptr)->Concrete.Tuple.align); }
extern size_t offsetof_ndt_t_Concrete_Tuple_align(void){ return offsetof(ndt_t, Concrete.Tuple.align); }
extern /* pointer to `uint16_t*` */ void * get_ndt_t_Concrete_Tuple_pad(void* ptr){ return &(((ndt_t*)ptr)->Concrete.Tuple.pad); }
extern size_t offsetof_ndt_t_Concrete_Tuple_pad(void){ return offsetof(ndt_t, Concrete.Tuple.pad); }
extern /* pointer to `int64_t*` */ void * get_ndt_t_Concrete_Record_offset(void* ptr){ return &(((ndt_t*)ptr)->Concrete.Record.offset); }
extern size_t offsetof_ndt_t_Concrete_Record_offset(void){ return offsetof(ndt_t, Concrete.Record.offset); }
extern /* pointer to `uint16_t*` */ void * get_ndt_t_Concrete_Record_align(void* ptr){ return &(((ndt_t*)ptr)->Concrete.Record.align); }
extern size_t offsetof_ndt_t_Concrete_Record_align(void){ return offsetof(ndt_t, Concrete.Record.align); }
extern /* pointer to `uint16_t*` */ void * get_ndt_t_Concrete_Record_pad(void* ptr){ return &(((ndt_t*)ptr)->Concrete.Record.pad); }
extern size_t offsetof_ndt_t_Concrete_Record_pad(void){ return offsetof(ndt_t, Concrete.Record.pad); }
extern /* pointer to `char*` */ void * get_ndt_t_extra(void* ptr){ return &(((ndt_t*)ptr)->extra); }
extern size_t offsetof_ndt_t_extra(void){ return offsetof(ndt_t, extra); }
extern size_t sizeof_ndt_context_t(void){ return sizeof(ndt_context_t); }
extern /* pointer to `uint32_t` */ void * get_ndt_context_t_flags(void* ptr){ return &(((ndt_context_t*)ptr)->flags); }
extern size_t offsetof_ndt_context_t_flags(void){ return offsetof(ndt_context_t, flags); }
extern /* pointer to `enum ndt_error` */ void * get_ndt_context_t_err(void* ptr){ return &(((ndt_context_t*)ptr)->err); }
extern size_t offsetof_ndt_context_t_err(void){ return offsetof(ndt_context_t, err); }
extern /* pointer to `enum ndt_msg` */ void * get_ndt_context_t_msg(void* ptr){ return &(((ndt_context_t*)ptr)->msg); }
extern size_t offsetof_ndt_context_t_msg(void){ return offsetof(ndt_context_t, msg); }
extern /* pointer to `const char*` */ void * get_ndt_context_t_ConstMsg(void* ptr){ return &(((ndt_context_t*)ptr)->ConstMsg); }
extern size_t offsetof_ndt_context_t_ConstMsg(void){ return offsetof(ndt_context_t, ConstMsg); }
extern /* pointer to `char*` */ void * get_ndt_context_t_DynamicMsg(void* ptr){ return &(((ndt_context_t*)ptr)->DynamicMsg); }
extern size_t offsetof_ndt_context_t_DynamicMsg(void){ return offsetof(ndt_context_t, DynamicMsg); }
extern size_t sizeof_ndt_ndarray_t(void){ return sizeof(ndt_ndarray_t); }
extern /* pointer to `int` */ void * get_ndt_ndarray_t_ndim(void* ptr){ return &(((ndt_ndarray_t*)ptr)->ndim); }
extern size_t offsetof_ndt_ndarray_t_ndim(void){ return offsetof(ndt_ndarray_t, ndim); }
extern /* pointer to `int64_t` */ void * get_ndt_ndarray_t_itemsize(void* ptr){ return &(((ndt_ndarray_t*)ptr)->itemsize); }
extern size_t offsetof_ndt_ndarray_t_itemsize(void){ return offsetof(ndt_ndarray_t, itemsize); }
extern /* pointer to `int64_t*` */ void * get_ndt_ndarray_t_shape(void* ptr){ return &(((ndt_ndarray_t*)ptr)->shape); }
extern size_t offsetof_ndt_ndarray_t_shape(void){ return offsetof(ndt_ndarray_t, shape); }
extern /* pointer to `int64_t*` */ void * get_ndt_ndarray_t_strides(void* ptr){ return &(((ndt_ndarray_t*)ptr)->strides); }
extern size_t offsetof_ndt_ndarray_t_strides(void){ return offsetof(ndt_ndarray_t, strides); }
extern /* pointer to `int64_t*` */ void * get_ndt_ndarray_t_steps(void* ptr){ return &(((ndt_ndarray_t*)ptr)->steps); }
extern size_t offsetof_ndt_ndarray_t_steps(void){ return offsetof(ndt_ndarray_t, steps); }
extern size_t sizeof_ndt_apply_spec_t(void){ return sizeof(ndt_apply_spec_t); }
extern /* pointer to `uint32_t` */ void * get_ndt_apply_spec_t_flags(void* ptr){ return &(((ndt_apply_spec_t*)ptr)->flags); }
extern size_t offsetof_ndt_apply_spec_t_flags(void){ return offsetof(ndt_apply_spec_t, flags); }
extern /* pointer to `int` */ void * get_ndt_apply_spec_t_nout(void* ptr){ return &(((ndt_apply_spec_t*)ptr)->nout); }
extern size_t offsetof_ndt_apply_spec_t_nout(void){ return offsetof(ndt_apply_spec_t, nout); }
extern /* pointer to `int` */ void * get_ndt_apply_spec_t_nbroadcast(void* ptr){ return &(((ndt_apply_spec_t*)ptr)->nbroadcast); }
extern size_t offsetof_ndt_apply_spec_t_nbroadcast(void){ return offsetof(ndt_apply_spec_t, nbroadcast); }
extern /* pointer to `int` */ void * get_ndt_apply_spec_t_outer_dims(void* ptr){ return &(((ndt_apply_spec_t*)ptr)->outer_dims); }
extern size_t offsetof_ndt_apply_spec_t_outer_dims(void){ return offsetof(ndt_apply_spec_t, outer_dims); }
extern /* pointer to `ndt_t**` */ void * get_ndt_apply_spec_t_out(void* ptr){ return &(((ndt_apply_spec_t*)ptr)->out); }
extern size_t offsetof_ndt_apply_spec_t_out(void){ return offsetof(ndt_apply_spec_t, out); }
extern /* pointer to `ndt_t**` */ void * get_ndt_apply_spec_t_broadcast(void* ptr){ return &(((ndt_apply_spec_t*)ptr)->broadcast); }
extern size_t offsetof_ndt_apply_spec_t_broadcast(void){ return offsetof(ndt_apply_spec_t, broadcast); }
extern size_t sizeof_ndt_typedef_t(void){ return sizeof(ndt_typedef_t); }
extern /* pointer to `const ndt_t*` */ void * get_ndt_typedef_t_type(void* ptr){ return &(((ndt_typedef_t*)ptr)->type); }
extern size_t offsetof_ndt_typedef_t_type(void){ return offsetof(ndt_typedef_t, type); }
extern /* pointer to `ndt_methods_t` */ void * get_ndt_typedef_t_meth(void* ptr){ return &(((ndt_typedef_t*)ptr)->meth); }
extern size_t offsetof_ndt_typedef_t_meth(void){ return offsetof(ndt_typedef_t, meth); }
extern size_t sizeof_ndt_bytes_t(void){ return sizeof(ndt_bytes_t); }
extern /* pointer to `int64_t` */ void * get_ndt_bytes_t_size(void* ptr){ return &(((ndt_bytes_t*)ptr)->size); }
extern size_t offsetof_ndt_bytes_t_size(void){ return offsetof(ndt_bytes_t, size); }
extern /* pointer to `uint8_t*` */ void * get_ndt_bytes_t_data(void* ptr){ return &(((ndt_bytes_t*)ptr)->data); }
extern size_t offsetof_ndt_bytes_t_data(void){ return offsetof(ndt_bytes_t, data); }
extern size_t sizeof_NdtObject(void){ return sizeof(NdtObject); }
extern /* pointer to `PyObject*` */ void * get_NdtObject_rbuf(void* ptr){ return &(((NdtObject*)ptr)->rbuf); }
extern size_t offsetof_NdtObject_rbuf(void){ return offsetof(NdtObject, rbuf); }
extern /* pointer to `ndt_t*` */ void * get_NdtObject_ndt(void* ptr){ return &(((NdtObject*)ptr)->ndt); }
extern size_t offsetof_NdtObject_ndt(void){ return offsetof(NdtObject, ndt); }
extern size_t sizeof_xnd_bitmap_t(void){ return sizeof(xnd_bitmap_t); }
extern /* pointer to `uint8_t*` */ void * get_xnd_bitmap_t_data(void* ptr){ return &(((xnd_bitmap_t*)ptr)->data); }
extern size_t offsetof_xnd_bitmap_t_data(void){ return offsetof(xnd_bitmap_t, data); }
extern /* pointer to `int64_t` */ void * get_xnd_bitmap_t_size(void* ptr){ return &(((xnd_bitmap_t*)ptr)->size); }
extern size_t offsetof_xnd_bitmap_t_size(void){ return offsetof(xnd_bitmap_t, size); }
extern /* pointer to `xnd_bitmap_t*` */ void * get_xnd_bitmap_t_next(void* ptr){ return &(((xnd_bitmap_t*)ptr)->next); }
extern size_t offsetof_xnd_bitmap_t_next(void){ return offsetof(xnd_bitmap_t, next); }
extern size_t sizeof_xnd_t(void){ return sizeof(xnd_t); }
extern /* pointer to `xnd_bitmap_t` */ void * get_xnd_t_bitmap(void* ptr){ return &(((xnd_t*)ptr)->bitmap); }
extern size_t offsetof_xnd_t_bitmap(void){ return offsetof(xnd_t, bitmap); }
extern /* pointer to `int64_t` */ void * get_xnd_t_index(void* ptr){ return &(((xnd_t*)ptr)->index); }
extern size_t offsetof_xnd_t_index(void){ return offsetof(xnd_t, index); }
extern /* pointer to `const ndt_t*` */ void * get_xnd_t_type(void* ptr){ return &(((xnd_t*)ptr)->type); }
extern size_t offsetof_xnd_t_type(void){ return offsetof(xnd_t, type); }
extern /* pointer to `char*` */ void * get_xnd_t_ptr(void* ptr){ return &(((xnd_t*)ptr)->ptr); }
extern size_t offsetof_xnd_t_ptr(void){ return offsetof(xnd_t, ptr); }
extern size_t sizeof_xnd_master_t(void){ return sizeof(xnd_master_t); }
extern /* pointer to `uint32_t` */ void * get_xnd_master_t_flags(void* ptr){ return &(((xnd_master_t*)ptr)->flags); }
extern size_t offsetof_xnd_master_t_flags(void){ return offsetof(xnd_master_t, flags); }
extern /* pointer to `xnd_t` */ void * get_xnd_master_t_master(void* ptr){ return &(((xnd_master_t*)ptr)->master); }
extern size_t offsetof_xnd_master_t_master(void){ return offsetof(xnd_master_t, master); }
extern size_t sizeof_xnd_index_t(void){ return sizeof(xnd_index_t); }
extern /* pointer to `enum xnd_key` */ void * get_xnd_index_t_tag(void* ptr){ return &(((xnd_index_t*)ptr)->tag); }
extern size_t offsetof_xnd_index_t_tag(void){ return offsetof(xnd_index_t, tag); }
extern /* pointer to `int64_t` */ void * get_xnd_index_t_Index(void* ptr){ return &(((xnd_index_t*)ptr)->Index); }
extern size_t offsetof_xnd_index_t_Index(void){ return offsetof(xnd_index_t, Index); }
extern /* pointer to `const char*` */ void * get_xnd_index_t_FieldName(void* ptr){ return &(((xnd_index_t*)ptr)->FieldName); }
extern size_t offsetof_xnd_index_t_FieldName(void){ return offsetof(xnd_index_t, FieldName); }
extern /* pointer to `ndt_slice_t` */ void * get_xnd_index_t_Slice(void* ptr){ return &(((xnd_index_t*)ptr)->Slice); }
extern size_t offsetof_xnd_index_t_Slice(void){ return offsetof(xnd_index_t, Slice); }
extern size_t sizeof_xnd_view_t(void){ return sizeof(xnd_view_t); }
extern /* pointer to `uint32_t` */ void * get_xnd_view_t_flags(void* ptr){ return &(((xnd_view_t*)ptr)->flags); }
extern size_t offsetof_xnd_view_t_flags(void){ return offsetof(xnd_view_t, flags); }
extern /* pointer to `const void*` */ void * get_xnd_view_t_obj(void* ptr){ return &(((xnd_view_t*)ptr)->obj); }
extern size_t offsetof_xnd_view_t_obj(void){ return offsetof(xnd_view_t, obj); }
extern /* pointer to `xnd_t` */ void * get_xnd_view_t_view(void* ptr){ return &(((xnd_view_t*)ptr)->view); }
extern size_t offsetof_xnd_view_t_view(void){ return offsetof(xnd_view_t, view); }
extern size_t sizeof_MemoryBlockObject(void){ return sizeof(MemoryBlockObject); }
extern /* pointer to `PyObject*` */ void * get_MemoryBlockObject_type(void* ptr){ return &(((MemoryBlockObject*)ptr)->type); }
extern size_t offsetof_MemoryBlockObject_type(void){ return offsetof(MemoryBlockObject, type); }
extern /* pointer to `xnd_master_t*` */ void * get_MemoryBlockObject_xnd(void* ptr){ return &(((MemoryBlockObject*)ptr)->xnd); }
extern size_t offsetof_MemoryBlockObject_xnd(void){ return offsetof(MemoryBlockObject, xnd); }
extern /* pointer to `Py_buffer*` */ void * get_MemoryBlockObject_view(void* ptr){ return &(((MemoryBlockObject*)ptr)->view); }
extern size_t offsetof_MemoryBlockObject_view(void){ return offsetof(MemoryBlockObject, view); }
extern size_t sizeof_XndObject(void){ return sizeof(XndObject); }
extern /* pointer to `MemoryBlockObject*` */ void * get_XndObject_mblock(void* ptr){ return &(((XndObject*)ptr)->mblock); }
extern size_t offsetof_XndObject_mblock(void){ return offsetof(XndObject, mblock); }
extern /* pointer to `PyObject*` */ void * get_XndObject_type(void* ptr){ return &(((XndObject*)ptr)->type); }
extern size_t offsetof_XndObject_type(void){ return offsetof(XndObject, type); }
extern /* pointer to `xnd_t` */ void * get_XndObject_xnd(void* ptr){ return &(((XndObject*)ptr)->xnd); }
extern size_t offsetof_XndObject_xnd(void){ return offsetof(XndObject, xnd); }
extern size_t sizeof_gm_kernel_set_t(void){ return sizeof(gm_kernel_set_t); }
extern /* pointer to `ndt_t*` */ void * get_gm_kernel_set_t_sig(void* ptr){ return &(((gm_kernel_set_t*)ptr)->sig); }
extern size_t offsetof_gm_kernel_set_t_sig(void){ return offsetof(gm_kernel_set_t, sig); }
extern /* pointer to `const ndt_constraint_t*` */ void * get_gm_kernel_set_t_constraint(void* ptr){ return &(((gm_kernel_set_t*)ptr)->constraint); }
extern size_t offsetof_gm_kernel_set_t_constraint(void){ return offsetof(gm_kernel_set_t, constraint); }
extern /* pointer to `gm_xnd_kernel_t` */ void * get_gm_kernel_set_t_Opt(void* ptr){ return &(((gm_kernel_set_t*)ptr)->Opt); }
extern size_t offsetof_gm_kernel_set_t_Opt(void){ return offsetof(gm_kernel_set_t, Opt); }
extern /* pointer to `gm_xnd_kernel_t` */ void * get_gm_kernel_set_t_C(void* ptr){ return &(((gm_kernel_set_t*)ptr)->C); }
extern size_t offsetof_gm_kernel_set_t_C(void){ return offsetof(gm_kernel_set_t, C); }
extern /* pointer to `gm_xnd_kernel_t` */ void * get_gm_kernel_set_t_Fortran(void* ptr){ return &(((gm_kernel_set_t*)ptr)->Fortran); }
extern size_t offsetof_gm_kernel_set_t_Fortran(void){ return offsetof(gm_kernel_set_t, Fortran); }
extern /* pointer to `gm_xnd_kernel_t` */ void * get_gm_kernel_set_t_Xnd(void* ptr){ return &(((gm_kernel_set_t*)ptr)->Xnd); }
extern size_t offsetof_gm_kernel_set_t_Xnd(void){ return offsetof(gm_kernel_set_t, Xnd); }
extern /* pointer to `gm_strided_kernel_t` */ void * get_gm_kernel_set_t_Strided(void* ptr){ return &(((gm_kernel_set_t*)ptr)->Strided); }
extern size_t offsetof_gm_kernel_set_t_Strided(void){ return offsetof(gm_kernel_set_t, Strided); }
extern size_t sizeof_gm_typedef_init_t(void){ return sizeof(gm_typedef_init_t); }
extern /* pointer to `const char*` */ void * get_gm_typedef_init_t_name(void* ptr){ return &(((gm_typedef_init_t*)ptr)->name); }
extern size_t offsetof_gm_typedef_init_t_name(void){ return offsetof(gm_typedef_init_t, name); }
extern /* pointer to `const char*` */ void * get_gm_typedef_init_t_type(void* ptr){ return &(((gm_typedef_init_t*)ptr)->type); }
extern size_t offsetof_gm_typedef_init_t_type(void){ return offsetof(gm_typedef_init_t, type); }
extern /* pointer to `const ndt_methods_t*` */ void * get_gm_typedef_init_t_meth(void* ptr){ return &(((gm_typedef_init_t*)ptr)->meth); }
extern size_t offsetof_gm_typedef_init_t_meth(void){ return offsetof(gm_typedef_init_t, meth); }
extern size_t sizeof_gm_kernel_init_t(void){ return sizeof(gm_kernel_init_t); }
extern /* pointer to `const char*` */ void * get_gm_kernel_init_t_name(void* ptr){ return &(((gm_kernel_init_t*)ptr)->name); }
extern size_t offsetof_gm_kernel_init_t_name(void){ return offsetof(gm_kernel_init_t, name); }
extern /* pointer to `const char*` */ void * get_gm_kernel_init_t_sig(void* ptr){ return &(((gm_kernel_init_t*)ptr)->sig); }
extern size_t offsetof_gm_kernel_init_t_sig(void){ return offsetof(gm_kernel_init_t, sig); }
extern /* pointer to `const ndt_constraint_t*` */ void * get_gm_kernel_init_t_constraint(void* ptr){ return &(((gm_kernel_init_t*)ptr)->constraint); }
extern size_t offsetof_gm_kernel_init_t_constraint(void){ return offsetof(gm_kernel_init_t, constraint); }
extern /* pointer to `gm_xnd_kernel_t` */ void * get_gm_kernel_init_t_Opt(void* ptr){ return &(((gm_kernel_init_t*)ptr)->Opt); }
extern size_t offsetof_gm_kernel_init_t_Opt(void){ return offsetof(gm_kernel_init_t, Opt); }
extern /* pointer to `gm_xnd_kernel_t` */ void * get_gm_kernel_init_t_C(void* ptr){ return &(((gm_kernel_init_t*)ptr)->C); }
extern size_t offsetof_gm_kernel_init_t_C(void){ return offsetof(gm_kernel_init_t, C); }
extern /* pointer to `gm_xnd_kernel_t` */ void * get_gm_kernel_init_t_Fortran(void* ptr){ return &(((gm_kernel_init_t*)ptr)->Fortran); }
extern size_t offsetof_gm_kernel_init_t_Fortran(void){ return offsetof(gm_kernel_init_t, Fortran); }
extern /* pointer to `gm_xnd_kernel_t` */ void * get_gm_kernel_init_t_Xnd(void* ptr){ return &(((gm_kernel_init_t*)ptr)->Xnd); }
extern size_t offsetof_gm_kernel_init_t_Xnd(void){ return offsetof(gm_kernel_init_t, Xnd); }
extern /* pointer to `gm_strided_kernel_t` */ void * get_gm_kernel_init_t_Strided(void* ptr){ return &(((gm_kernel_init_t*)ptr)->Strided); }
extern size_t offsetof_gm_kernel_init_t_Strided(void){ return offsetof(gm_kernel_init_t, Strided); }
extern size_t sizeof_gm_kernel_t(void){ return sizeof(gm_kernel_t); }
extern /* pointer to `uint32_t` */ void * get_gm_kernel_t_flag(void* ptr){ return &(((gm_kernel_t*)ptr)->flag); }
extern size_t offsetof_gm_kernel_t_flag(void){ return offsetof(gm_kernel_t, flag); }
extern /* pointer to `const gm_kernel_set_t*` */ void * get_gm_kernel_t_set(void* ptr){ return &(((gm_kernel_t*)ptr)->set); }
extern size_t offsetof_gm_kernel_t_set(void){ return offsetof(gm_kernel_t, set); }
extern size_t sizeof_gm_func_t(void){ return sizeof(gm_func_t); }
extern /* pointer to `char*` */ void * get_gm_func_t_name(void* ptr){ return &(((gm_func_t*)ptr)->name); }
extern size_t offsetof_gm_func_t_name(void){ return offsetof(gm_func_t, name); }
extern /* pointer to `gm_typecheck_t` */ void * get_gm_func_t_typecheck(void* ptr){ return &(((gm_func_t*)ptr)->typecheck); }
extern size_t offsetof_gm_func_t_typecheck(void){ return offsetof(gm_func_t, typecheck); }
extern /* pointer to `int` */ void * get_gm_func_t_nkernels(void* ptr){ return &(((gm_func_t*)ptr)->nkernels); }
extern size_t offsetof_gm_func_t_nkernels(void){ return offsetof(gm_func_t, nkernels); }
extern /* pointer to `gm_kernel_set_t*` */ void * get_gm_func_t_kernels(void* ptr){ return &(((gm_func_t*)ptr)->kernels); }
extern size_t offsetof_gm_func_t_kernels(void){ return offsetof(gm_func_t, kernels); }
extern size_t sizeof_GufuncObject(void){ return sizeof(GufuncObject); }
extern /* pointer to `const gm_tbl_t*` */ void * get_GufuncObject_tbl(void* ptr){ return &(((GufuncObject*)ptr)->tbl); }
extern size_t offsetof_GufuncObject_tbl(void){ return offsetof(GufuncObject, tbl); }
extern /* pointer to `char*` */ void * get_GufuncObject_name(void* ptr){ return &(((GufuncObject*)ptr)->name); }
extern size_t offsetof_GufuncObject_name(void){ return offsetof(GufuncObject, name); }
#ifdef PYTHON_MODULE
#include "Python.h"
static PyObject *pyc_sizeof_char_opt_t(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(sizeof_char_opt_t())); }
static PyObject *pyc_get_char_opt_t_tag(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "char_opt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_char_opt_t_tag(PyCapsule_GetPointer(ptr, "char_opt_t*")), "enum ndt_option", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted char_opt_t");
return NULL;
}
static PyObject *pyc_offsetof_char_opt_t_tag(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_char_opt_t_tag())); }
static PyObject *pyc_get_char_opt_t_Some(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "char_opt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_char_opt_t_Some(PyCapsule_GetPointer(ptr, "char_opt_t*")), "char", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted char_opt_t");
return NULL;
}
static PyObject *pyc_offsetof_char_opt_t_Some(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_char_opt_t_Some())); }
static PyObject *pyc_sizeof_int64_opt_t(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(sizeof_int64_opt_t())); }
static PyObject *pyc_get_int64_opt_t_tag(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "int64_opt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_int64_opt_t_tag(PyCapsule_GetPointer(ptr, "int64_opt_t*")), "enum ndt_option", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted int64_opt_t");
return NULL;
}
static PyObject *pyc_offsetof_int64_opt_t_tag(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_int64_opt_t_tag())); }
static PyObject *pyc_get_int64_opt_t_Some(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "int64_opt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_int64_opt_t_Some(PyCapsule_GetPointer(ptr, "int64_opt_t*")), "int64_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted int64_opt_t");
return NULL;
}
static PyObject *pyc_offsetof_int64_opt_t_Some(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_int64_opt_t_Some())); }
static PyObject *pyc_sizeof_uint16_opt_t(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(sizeof_uint16_opt_t())); }
static PyObject *pyc_get_uint16_opt_t_tag(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "uint16_opt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_uint16_opt_t_tag(PyCapsule_GetPointer(ptr, "uint16_opt_t*")), "enum ndt_option", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted uint16_opt_t");
return NULL;
}
static PyObject *pyc_offsetof_uint16_opt_t_tag(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_uint16_opt_t_tag())); }
static PyObject *pyc_get_uint16_opt_t_Some(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "uint16_opt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_uint16_opt_t_Some(PyCapsule_GetPointer(ptr, "uint16_opt_t*")), "uint16_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted uint16_opt_t");
return NULL;
}
static PyObject *pyc_offsetof_uint16_opt_t_Some(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_uint16_opt_t_Some())); }
static PyObject *pyc_sizeof_ndt_meta_t(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(sizeof_ndt_meta_t())); }
static PyObject *pyc_get_ndt_meta_t_ndims(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_meta_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_meta_t_ndims(PyCapsule_GetPointer(ptr, "ndt_meta_t*")), "int", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_meta_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_meta_t_ndims(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_meta_t_ndims())); }
static PyObject *pyc_get_ndt_meta_t_noffsets(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_meta_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_meta_t_noffsets(PyCapsule_GetPointer(ptr, "ndt_meta_t*")), "int32_t*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_meta_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_meta_t_noffsets(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_meta_t_noffsets())); }
static PyObject *pyc_get_ndt_meta_t_offsets(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_meta_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_meta_t_offsets(PyCapsule_GetPointer(ptr, "ndt_meta_t*")), "int32_t**", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_meta_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_meta_t_offsets(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_meta_t_offsets())); }
static PyObject *pyc_sizeof_ndt_field_t(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(sizeof_ndt_field_t())); }
static PyObject *pyc_get_ndt_field_t_access(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_field_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_field_t_access(PyCapsule_GetPointer(ptr, "ndt_field_t*")), "enum ndt_access", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_field_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_field_t_access(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_field_t_access())); }
static PyObject *pyc_get_ndt_field_t_name(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_field_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_field_t_name(PyCapsule_GetPointer(ptr, "ndt_field_t*")), "char*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_field_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_field_t_name(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_field_t_name())); }
static PyObject *pyc_get_ndt_field_t_type(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_field_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_field_t_type(PyCapsule_GetPointer(ptr, "ndt_field_t*")), "ndt_t*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_field_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_field_t_type(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_field_t_type())); }
static PyObject *pyc_get_ndt_field_t_Concrete_align(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_field_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_field_t_Concrete_align(PyCapsule_GetPointer(ptr, "ndt_field_t*")), "uint16_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_field_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_field_t_Concrete_align(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_field_t_Concrete_align())); }
static PyObject *pyc_get_ndt_field_t_Concrete_explicit_align(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_field_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_field_t_Concrete_explicit_align(PyCapsule_GetPointer(ptr, "ndt_field_t*")), "bool", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_field_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_field_t_Concrete_explicit_align(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_field_t_Concrete_explicit_align())); }
static PyObject *pyc_get_ndt_field_t_Concrete_pad(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_field_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_field_t_Concrete_pad(PyCapsule_GetPointer(ptr, "ndt_field_t*")), "uint16_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_field_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_field_t_Concrete_pad(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_field_t_Concrete_pad())); }
static PyObject *pyc_get_ndt_field_t_Concrete_explicit_pad(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_field_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_field_t_Concrete_explicit_pad(PyCapsule_GetPointer(ptr, "ndt_field_t*")), "bool", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_field_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_field_t_Concrete_explicit_pad(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_field_t_Concrete_explicit_pad())); }
static PyObject *pyc_sizeof_ndt_value_t(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(sizeof_ndt_value_t())); }
static PyObject *pyc_get_ndt_value_t_tag(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_value_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_value_t_tag(PyCapsule_GetPointer(ptr, "ndt_value_t*")), "enum ndt_value", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_value_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_value_t_tag(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_value_t_tag())); }
static PyObject *pyc_get_ndt_value_t_ValBool(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_value_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_value_t_ValBool(PyCapsule_GetPointer(ptr, "ndt_value_t*")), "bool", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_value_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_value_t_ValBool(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_value_t_ValBool())); }
static PyObject *pyc_get_ndt_value_t_ValInt64(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_value_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_value_t_ValInt64(PyCapsule_GetPointer(ptr, "ndt_value_t*")), "int64_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_value_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_value_t_ValInt64(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_value_t_ValInt64())); }
static PyObject *pyc_get_ndt_value_t_ValFloat64(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_value_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_value_t_ValFloat64(PyCapsule_GetPointer(ptr, "ndt_value_t*")), "double", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_value_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_value_t_ValFloat64(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_value_t_ValFloat64())); }
static PyObject *pyc_get_ndt_value_t_ValString(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_value_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_value_t_ValString(PyCapsule_GetPointer(ptr, "ndt_value_t*")), "char*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_value_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_value_t_ValString(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_value_t_ValString())); }
static PyObject *pyc_sizeof_ndt_slice_t(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(sizeof_ndt_slice_t())); }
static PyObject *pyc_get_ndt_slice_t_start(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_slice_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_slice_t_start(PyCapsule_GetPointer(ptr, "ndt_slice_t*")), "int64_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_slice_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_slice_t_start(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_slice_t_start())); }
static PyObject *pyc_get_ndt_slice_t_stop(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_slice_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_slice_t_stop(PyCapsule_GetPointer(ptr, "ndt_slice_t*")), "int64_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_slice_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_slice_t_stop(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_slice_t_stop())); }
static PyObject *pyc_get_ndt_slice_t_step(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_slice_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_slice_t_step(PyCapsule_GetPointer(ptr, "ndt_slice_t*")), "int64_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_slice_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_slice_t_step(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_slice_t_step())); }
static PyObject *pyc_sizeof_ndt_constraint_t(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(sizeof_ndt_constraint_t())); }
static PyObject *pyc_get_ndt_constraint_t_f(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_constraint_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_constraint_t_f(PyCapsule_GetPointer(ptr, "ndt_constraint_t*")), "ndt_func_constraint_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_constraint_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_constraint_t_f(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_constraint_t_f())); }
static PyObject *pyc_get_ndt_constraint_t_nin(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_constraint_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_constraint_t_nin(PyCapsule_GetPointer(ptr, "ndt_constraint_t*")), "int", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_constraint_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_constraint_t_nin(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_constraint_t_nin())); }
static PyObject *pyc_get_ndt_constraint_t_nout(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_constraint_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_constraint_t_nout(PyCapsule_GetPointer(ptr, "ndt_constraint_t*")), "int", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_constraint_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_constraint_t_nout(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_constraint_t_nout())); }
static PyObject *pyc_get_ndt_constraint_t_symbols(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_constraint_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_constraint_t_symbols(PyCapsule_GetPointer(ptr, "ndt_constraint_t*")), "const char**", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_constraint_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_constraint_t_symbols(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_constraint_t_symbols())); }
static PyObject *pyc_sizeof_ndt_methods_t(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(sizeof_ndt_methods_t())); }
static PyObject *pyc_get_ndt_methods_t_init(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_methods_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_methods_t_init(PyCapsule_GetPointer(ptr, "ndt_methods_t*")), "ndt_init_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_methods_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_methods_t_init(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_methods_t_init())); }
static PyObject *pyc_get_ndt_methods_t_constraint(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_methods_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_methods_t_constraint(PyCapsule_GetPointer(ptr, "ndt_methods_t*")), "ndt_tdef_constraint_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_methods_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_methods_t_constraint(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_methods_t_constraint())); }
static PyObject *pyc_get_ndt_methods_t_repr(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_methods_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_methods_t_repr(PyCapsule_GetPointer(ptr, "ndt_methods_t*")), "ndt_repr_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_methods_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_methods_t_repr(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_methods_t_repr())); }
static PyObject *pyc_sizeof_ndt_t(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(sizeof_ndt_t())); }
static PyObject *pyc_get_ndt_t_tag(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_tag(PyCapsule_GetPointer(ptr, "ndt_t*")), "enum ndt", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_tag(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_tag())); }
static PyObject *pyc_get_ndt_t_access(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_access(PyCapsule_GetPointer(ptr, "ndt_t*")), "enum ndt_access", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_access(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_access())); }
static PyObject *pyc_get_ndt_t_flags(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_flags(PyCapsule_GetPointer(ptr, "ndt_t*")), "uint32_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_flags(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_flags())); }
static PyObject *pyc_get_ndt_t_ndim(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_ndim(PyCapsule_GetPointer(ptr, "ndt_t*")), "int", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_ndim(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_ndim())); }
static PyObject *pyc_get_ndt_t_datasize(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_datasize(PyCapsule_GetPointer(ptr, "ndt_t*")), "int64_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_datasize(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_datasize())); }
static PyObject *pyc_get_ndt_t_align(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_align(PyCapsule_GetPointer(ptr, "ndt_t*")), "uint16_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_align(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_align())); }
static PyObject *pyc_get_ndt_t_Module_name(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_Module_name(PyCapsule_GetPointer(ptr, "ndt_t*")), "char*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_Module_name(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_Module_name())); }
static PyObject *pyc_get_ndt_t_Module_type(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_Module_type(PyCapsule_GetPointer(ptr, "ndt_t*")), "ndt_t*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_Module_type(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_Module_type())); }
static PyObject *pyc_get_ndt_t_Function_elemwise(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_Function_elemwise(PyCapsule_GetPointer(ptr, "ndt_t*")), "bool", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_Function_elemwise(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_Function_elemwise())); }
static PyObject *pyc_get_ndt_t_Function_nin(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_Function_nin(PyCapsule_GetPointer(ptr, "ndt_t*")), "int64_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_Function_nin(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_Function_nin())); }
static PyObject *pyc_get_ndt_t_Function_nout(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_Function_nout(PyCapsule_GetPointer(ptr, "ndt_t*")), "int64_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_Function_nout(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_Function_nout())); }
static PyObject *pyc_get_ndt_t_Function_nargs(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_Function_nargs(PyCapsule_GetPointer(ptr, "ndt_t*")), "int64_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_Function_nargs(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_Function_nargs())); }
static PyObject *pyc_get_ndt_t_Function_types(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_Function_types(PyCapsule_GetPointer(ptr, "ndt_t*")), "ndt_t**", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_Function_types(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_Function_types())); }
static PyObject *pyc_get_ndt_t_FixedDim_shape(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_FixedDim_shape(PyCapsule_GetPointer(ptr, "ndt_t*")), "int64_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_FixedDim_shape(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_FixedDim_shape())); }
static PyObject *pyc_get_ndt_t_FixedDim_type(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_FixedDim_type(PyCapsule_GetPointer(ptr, "ndt_t*")), "ndt_t*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_FixedDim_type(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_FixedDim_type())); }
static PyObject *pyc_get_ndt_t_VarDim_type(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_VarDim_type(PyCapsule_GetPointer(ptr, "ndt_t*")), "ndt_t*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_VarDim_type(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_VarDim_type())); }
static PyObject *pyc_get_ndt_t_SymbolicDim_name(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_SymbolicDim_name(PyCapsule_GetPointer(ptr, "ndt_t*")), "char*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_SymbolicDim_name(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_SymbolicDim_name())); }
static PyObject *pyc_get_ndt_t_SymbolicDim_type(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_SymbolicDim_type(PyCapsule_GetPointer(ptr, "ndt_t*")), "ndt_t*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_SymbolicDim_type(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_SymbolicDim_type())); }
static PyObject *pyc_get_ndt_t_EllipsisDim_name(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_EllipsisDim_name(PyCapsule_GetPointer(ptr, "ndt_t*")), "char*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_EllipsisDim_name(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_EllipsisDim_name())); }
static PyObject *pyc_get_ndt_t_EllipsisDim_type(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_EllipsisDim_type(PyCapsule_GetPointer(ptr, "ndt_t*")), "ndt_t*", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_EllipsisDim_type(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_EllipsisDim_type())); }
static PyObject *pyc_get_ndt_t_Tuple_flag(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_Tuple_flag(PyCapsule_GetPointer(ptr, "ndt_t*")), "enum ndt_variadic", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_Tuple_flag(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_Tuple_flag())); }
static PyObject *pyc_get_ndt_t_Tuple_shape(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_Tuple_shape(PyCapsule_GetPointer(ptr, "ndt_t*")), "int64_t", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_Tuple_shape(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_Tuple_shape())); }
static PyObject *pyc_get_ndt_t_Tuple_types(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_Tuple_types(PyCapsule_GetPointer(ptr, "ndt_t*")), "ndt_t**", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_Tuple_types(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_Tuple_types())); }
static PyObject *pyc_get_ndt_t_Record_flag(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {
return PyCapsule_New( get_ndt_t_Record_flag(PyCapsule_GetPointer(ptr, "ndt_t*")), "enum ndt_variadic", NULL);
}
PyErr_SetString(PyExc_TypeError, "expected capsuleted ndt_t");
return NULL;
}
static PyObject *pyc_offsetof_ndt_t_Record_flag(PyObject *self, PyObject *args) { return PyLong_FromLong((long)(offsetof_ndt_t_Record_flag())); }
static PyObject *pyc_get_ndt_t_Record_shape(PyObject *self, PyObject *args) {
PyObject* ptr=NULL;
if (!PyArg_UnpackTuple(args, "ndt_t", 0, 1, &ptr))
return NULL;
if (PyCapsule_CheckExact(ptr)) {