summaryrefslogtreecommitdiff
path: root/xinput_ivy.h
blob: ba4eebcbf733d3f8ddeda2b6e5cfbf654b946d3f (plain)
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
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
#ifdef __cplusplus
extern "C" {
#endif
/*
ANSI C code generated by SmartEiffel The GNU Eiffel Compiler, Eiffel tools and libraries
Release 2.4 (??? June ??th 2009) [????]
Copyright (C), 1994-2002 - INRIA - LORIA - ESIAL UHP Nancy 1 - FRANCE
Copyright (C), 2003-2005 - INRIA - LORIA - IUT Charlemagne Nancy 2 - FRANCE
D.COLNET, P.RIBET, C.ADRIAN, V.CROIZIER F.MERIZEN - SmartEiffel@loria.fr
http://SmartEiffel.loria.fr
C Compiler options used: -pipe -O3 -fomit-frame-pointer
*/

/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
/*
  This file (SmartEiffel/sys/runtime/base.h) contains all basic Eiffel
  type definitions.
  This file is automatically included in the header for all modes of
  compilation: -boost, -no_check, -require_check, -ensure_check, ...
  This file is also included in the header of any cecil file (when the
  -cecil option is used).
  This file is also included in the header file of C++ wrappers (when
  using the external "C++" clause).
*/

#ifndef _BASE_H
#define _BASE_H

#if defined(_MSC_VER) && (_MSC_VER >= 1400)       /* VC8+ */
# ifndef _CRT_SECURE_NO_DEPRECATE
#  define _CRT_SECURE_NO_DEPRECATE
# endif
# ifndef _CRT_NONSTDC_NO_DEPRECATE
#  define _CRT_NONSTDC_NO_DEPRECATE
# endif
#endif   /* VC8+ */

#include <stdio.h>
#include <string.h>
#include <math.h>
#include <stdlib.h>
#include <signal.h>
#include <stddef.h>
#include <stdarg.h>
#include <limits.h>
#include <float.h>
#include <setjmp.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#if defined __USE_POSIX || defined __unix__ || defined _POSIX_C_SOURCE
#  include <unistd.h>
#endif
#if !defined(WIN32) && \
       (defined(WINVER) || defined(_WIN32_WINNT) || defined(_WIN32) || \
	defined(__WIN32__) || defined(__TOS_WIN__) || defined(_MSC_VER))
#  define WIN32 1
#endif
#ifdef WIN32
#  include <windows.h>
#else
#  ifndef O_RDONLY
#    include <sys/file.h>
#  endif
#  ifndef O_RDONLY
#    define O_RDONLY 0000
#  endif
#endif

#if defined(_MSC_VER) && (_MSC_VER < 1600) /* MSVC older than v10 */
typedef signed char int8_t;
typedef signed short int16_t;
typedef signed int int32_t;
typedef signed __int64 int64_t;
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
typedef unsigned __int64 uint64_t;
#  define PRId8 "d"
#  define PRId16 "d"
#  define PRId32 "d"
#  define PRId64 "I64d"
#  define INT8_C(c) c
#  define INT16_C(c) c
#  define INT32_C(c) c
#  define INT64_C(c) c ## i64
#elif defined(__WATCOMC__) && (__WATCOMC__ <= 1220) /* WATCOM 12.2 or lower */
typedef signed char int8_t;
typedef signed short int16_t;
typedef signed long int int32_t;
typedef signed __int64 int64_t;
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned long int uint32_t;
typedef unsigned __int64 uint64_t;
#  define PRId8 "d"
#  define PRId16 "d"
#  define PRId32 "d"
#  define PRId64 "Ld"
#  define INT8_C(c) c
#  define INT16_C(c) c
#  define INT32_C(c) c ## L
#  define INT64_C(c) c ## i64
#elif defined(__BORLANDC__) && (__BORLANDC__ < 0x600) /* Borland before 6.0 */
typedef signed char int8_t;
typedef signed short int16_t;
typedef signed long int int32_t;
typedef signed __int64 int64_t;
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned long int uint32_t;
typedef unsigned __int64 uint64_t;
#  define PRId8 "d"
#  define PRId16 "d"
#  define PRId32 "ld"
#  define PRId64 "I64Ld"
#  define INT8_C(c) c
#  define INT16_C(c) c
#  define INT32_C(c) c ## L
#  define INT64_C(c) c ## i64
#elif defined(__FreeBSD__) && (__FreeBSD__ < 5) /* FreeBSD before 5.0 */ && !defined (_SYS_INTTYPES_H_)
typedef signed char int8_t;
typedef signed short int16_t;
typedef signed long int int32_t;
typedef signed long long int int64_t;
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned long int uint32_t;
typedef unsigned long long int uint64_t;
#elif defined(__CYGWIN__) && defined(__BIT_TYPES_DEFINED__) /* Cygwin defines intxx_t in sys/types.h instead of inttypes.h */
#  include <cygwin/version.h>
#  if defined(CYGWIN_VERSION_DLL_MAJOR) && (CYGWIN_VERSION_DLL_MAJOR<1005)
typedef unsigned char uint8_t;
typedef __uint16_t uint16_t;
typedef __uint32_t uint32_t;
typedef __uint64_t uint64_t;
#  endif
#elif defined(SASC)
#    error("Too old SAS/C compiler, sorry.");
#elif defined(__SASC__)
#  if (__SASC__ < 750 ) /*  SAS/C before 7.50 */
typedef signed char int8_t;
typedef signed short int16_t;
typedef signed long int int32_t;
typedef signed long long int int64_t;
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned long int uint32_t;
typedef unsigned long long int uint64_t;
#  endif
#else
#  include <inttypes.h>
#  if !defined(INT8_MAX) && defined(INT16_MAX)
/* int8_t is not mandatory */
typedef int_least8_t int8_t;
#  endif
#endif

#if !defined(PRId16)
#  define PRId8 "d"
#  define PRId16 "d"
#  define PRId32 "ld"
#  define PRId64 "lld"
#elif !defined(PRId8)
#  define PRId8 "d"
#endif
#if !defined(INT16_C)
#  define INT8_C(c) c
#  define INT16_C(c) c
#  define INT32_C(c) c ## L
#  define INT64_C(c) c ## LL
#elif !defined(INT8_C)
#  define INT8_C(c) c
#endif
#if !defined(INT16_MIN)
#  define INT8_MIN (-INT8_C(127)-1)
#  define INT8_MAX (INT8_C(127))
#  define INT16_MIN (-INT16_C(32767)-1)
#  define INT16_MAX (INT16_C(32767))
#  define INT32_MIN (-INT32_C(2147483647)-1)
#  define INT32_MAX (INT32_C(2147483647))
#  define INT64_MIN (-INT64_C(9223372036854775807)-1)
#  define INT64_MAX (INT64_C(9223372036854775807))
#elif !defined(INT8_MIN)
#  define INT8_MIN (-INT8_C(127)-1)
#endif


/*
  Endian stuff
*/
#if defined(BSD) && (BSD >= 199103)
#  include <machine/endian.h>
#elif defined(__alpha__) || defined(__alpha) || defined(_M_ALPHA)
/* bi-endian processor, current mode should be find in machine/endian.h file */
#  include <machine/endian.h>
#elif defined(linux)
#  include <endian.h>
#endif



#if !defined(BYTE_ORDER) && defined(__BYTE_ORDER)
#  define BYTE_ORDER      __BYTE_ORDER
#endif

#if !defined(LITTLE_ENDIAN) && defined(__LITTLE_ENDIAN)
#  define LITTLE_ENDIAN      __LITTLE_ENDIAN
#endif

#if !defined(BIG_ENDIAN) && defined(__BIG_ENDIAN)
#  define BIG_ENDIAN      __BIG_ENDIAN
#endif

#if !defined(LITTLE_ENDIAN)
#  define LITTLE_ENDIAN   1234    /* LSB first (vax, pc) */
#endif
#if !defined(BIG_ENDIAN)
#  define BIG_ENDIAN      4321    /* MSB first (IBM, net) */
#endif
#if !defined(PDP_ENDIAN)
#  define PDP_ENDIAN      3412    /* LSB first in word, MSW first in long */
#endif

#if !defined(BYTE_ORDER) && defined(BIT_ZERO_ON_RIGHT)
#  define BYTE_ORDER      LITTLE_ENDIAN
#elif !defined(BYTE_ORDER) && defined(BIT_ZERO_ON_LEFT)
#  define BYTE_ORDER      BIG_ENDIAN
#elif !defined(BYTE_ORDER)

/* ARM */
#  if defined(__ARMEL__)
#    define BYTE_ORDER      LITTLE_ENDIAN
#  elif defined(__ARMEB__)
#    define BYTE_ORDER      BIG_ENDIAN
#  elif defined(__arm__)
#    error "ARMs are bi-endian processors. Endianness is unknown for this system, please drop an e-mail to SmartEiffel@loria.fr"
#  endif

/* HP RISC */
#  if defined(__hppa__) || defined(__hppa) || defined(__hp9000) || \
      defined(__hp9000s300) || defined(hp9000s300) || \
      defined(__hp9000s700) || defined(hp9000s700) || \
      defined(__hp9000s800) || defined(hp9000s800) || defined(hp9000s820)
#    define BYTE_ORDER      BIG_ENDIAN
#  endif

/* IBM */
#  if defined(ibm032) || defined(ibm370) || defined(_IBMR2) || \
      defined(IBM370) || defined(__MVS__)
#    define BYTE_ORDER      BIG_ENDIAN
#  endif

/* Intel x86 */
#  if defined(i386) || defined(__i386__) || defined(__i386) || \
      defined(_M_IX86) || defined(_X86_) || defined(__THW_INTEL) || \
      defined(sun386)
#    define BYTE_ORDER      LITTLE_ENDIAN
#  endif

/* Intel Itanium */
#  if defined(__ia64__) || defined(_IA64) || defined(__IA64__) || \
      defined(_M_IA64)
#    define BYTE_ORDER      LITTLE_ENDIAN
#  endif

/* Nationnal Semiconductor 32000 serie */
#  if  defined(ns32000)
#    define BYTE_ORDER      LITTLE_ENDIAN
#  endif

/* Motorola 68000 */
#  if defined(mc68000) || defined(is68k) || defined(macII) || defined(m68k)
#    define BYTE_ORDER      BIG_ENDIAN
#  endif

/* MIPS */
#  if defined(MIPSEL) || defined(_MIPSEL)
#    define BYTE_ORDER      LITTLE_ENDIAN
#  elif defined(MIPSEB) || defined(_MIPSEB)
#    define BYTE_ORDER      BIG_ENDIAN
#  elif defined(__mips__) || defined(__mips) || defined(__MIPS__)
#    error "MIPS are bi-endian processors. Endianness is unknown for this system, please drop an e-mail to SmartEiffel@loria.fr"
#  endif

/* Power PC */
/* this processor is bi-endian, how to know if little-endian is set? */
#  if defined(__powerpc) || defined(__powerpc__) || defined(__POWERPC__) || \
      defined(__ppc__) || defined(__ppc) || defined(_M_PPC) || \
      defined(__PPC) || defined(__PPC__)
#    define BYTE_ORDER      BIG_ENDIAN
#  endif

/* Pyramid 9810 */
#  if defined(pyr)
#    define BYTE_ORDER      BIG_ENDIAN
#  endif

/* RS/6000 */
#  if defined(__THW_RS6000) || defined(_IBMR2) || defined(_POWER) || \
      defined(_ARCH_PWR) || defined(_ARCH_PWR2)
#    define BYTE_ORDER      BIG_ENDIAN
#  endif

/* SPARC */
#  if defined(__sparc__) || defined(sparc) || defined(__sparc)
#    define BYTE_ORDER      BIG_ENDIAN
#  endif

/* CCI Tahoe */
#  if defined(tahoe)
#    define BYTE_ORDER      BIG_ENDIAN
#  endif

/* VAX */
#  if defined(vax) || defined(VAX) || defined(__vax__) || defined(_vax_) || \
      defined(__vax) || defined(__VAX)
#    define BYTE_ORDER      LITTLE_ENDIAN
#  endif

/* ELATE is a virtual OS with a little endian Virtual Processor */
#  if defined(__ELATE__)
#    define BYTE_ORDER      LITTLE_ENDIAN
#  endif

/* Miscellaneous little endian */
#  if defined(wrltitan)
#    define BYTE_ORDER      LITTLE_ENDIAN
#  endif

/* Miscellaneous big endian */
#  if defined(apollo) || defined(__convex__) || defined(_CRAY) || defined(sel)
#    define BYTE_ORDER      BIG_ENDIAN
#  endif
#endif


#if !defined(BYTE_ORDER)
#  error "Unknown byte order. Add your system in above macros once you know your system type. Please drop an e-mail to SmartEiffel@loria.fr"
#endif
#if (BYTE_ORDER != BIG_ENDIAN && BYTE_ORDER != LITTLE_ENDIAN)
#  error "Only little-endian and big-endian are valid at this time. Please drop an e-mail to SmartEiffel@loria.fr"
#endif


/*
  Byte swapping stuff
*/
extern void copy_swap_16(const uint16_t *src, uint16_t *dest, int count);


/* Because ANSI C EXIT_* are not always defined: */
#ifndef EXIT_FAILURE
#  define EXIT_FAILURE 1
#endif
#ifndef EXIT_SUCCESS
#  define EXIT_SUCCESS 0
#endif

/*
   On Linux glibc systems, we need to use sig.* versions of jmp_buf,
   setjmp and longjmp to preserve the signal handling context.
   Currently, the way I figured to detect this is if _SIGSET_H_types has
   been defined in /usr/include/setjmp.h.

   NOTE: with gcc, -ansi is used for SmartEiffel generated files EXCEPT in
   -no_split mode. ANSI only recognizes the non-sig versions.
*/
#if (defined(_SIGSET_H_types) && !defined(__STRICT_ANSI__))
#  define JMP_BUF    sigjmp_buf
#  define SETJMP(x)  sigsetjmp( (x), 1)
#  define LONGJMP    siglongjmp
#else
#  define JMP_BUF    jmp_buf
#  define SETJMP(x)  setjmp( (x) )
#  define LONGJMP    longjmp
#endif

/*
   Type to store reference objects Id:
 */
typedef int Tid;
typedef struct S0 T0;
struct S0{Tid id;};

/*
   The default channel used to print runtime error messages:
*/
#define SE_ERR stderr

/*
   Eiffel type INTEGER_8 is #1:
*/
typedef int8_t T1;
#define EIF_INTEGER_8 T1
#define M1 (INT8_C(0))
#define EIF_INTEGER_8_BITS (CHAR_BIT)
#define EIF_MINIMUM_INTEGER_8 (INT8_MIN)
#define EIF_MAXIMUM_INTEGER_8 (INT8_MAX)

/*
  Eiffel type INTEGER_16 is #10:
*/
typedef int16_t T10;
#define EIF_INTEGER_16 T10
#define M10 (INT16_C(0))
#define EIF_INTEGER_16_BITS (CHAR_BIT*sizeof(T10t))
#define EIF_MINIMUM_INTEGER_16 (INT16_MIN) /*-32768*/
#define EIF_MAXIMUM_INTEGER_16 (INT16_MAX) /*+32767*/

/*
  Eiffel type INTEGER or INTEGER_32 is #2:
*/
typedef int32_t T2;
#define EIF_INTEGER T2
#define EIF_INTEGER_32 T2
#define M2 (INT32_C(0))
#define EIF_INTEGER_BITS ((T2)(CHAR_BIT*sizeof(T2)))
#define EIF_INTEGER_32_BITS EIF_INTEGER_BITS
#define EIF_MINIMUM_INTEGER (INT32_MIN)
#define EIF_MAXIMUM_INTEGER (INT32_MAX)

/*
  Eiffel type INTEGER_64 is #11:
*/
typedef int64_t T11;
#define EIF_INTEGER_64 T11
#define M11 (INT64_C(0))
#define EIF_INTEGER_64_BITS (CHAR_BIT*sizeof(T11))
#define EIF_MINIMUM_INTEGER_64 (INT64_MIN)
#define EIF_MAXIMUM_INTEGER_64 (INT64_MAX)

/*
  Eiffel type CHARACTER is #3:
*/
typedef unsigned char T3;
#define EIF_CHARACTER T3
#define M3 (0)
#define EIF_CHARACTER_BITS (CHAR_BIT)
#define EIF_MINIMUM_CHARACTER_CODE (0)
#define EIF_MAXIMUM_CHARACTER_CODE (255)
#define T3code(x) ((T10)(x))
#define T3to_integer(x) ((signed char)(x))
#define T3to_integer_8(x) ((signed char)(x))
#define T3to_bit(x) (x)

/*
  Eiffel type REAL_32 is #4:
*/
typedef float T4;
typedef T4 real32_t;
#define EIF_REAL_32 T4
#define M4 (0.0)
#define EIF_MINIMUM_REAL_32 (-(FLT_MAX))
#define EIF_MAXIMUM_REAL_32 (FLT_MAX)

/*
  Eiffel type REAL or REAL_64 is #5:
*/
typedef double T5;
typedef T5 real64_t;
#define EIF_REAL_64 T5
#define M5 (0.0)
#define EIF_MINIMUM_REAL_64 (-(DBL_MAX))
#define EIF_MINIMUM_REAL (EIF_MINIMUM_REAL_64)
#define EIF_MAXIMUM_REAL_64 (DBL_MAX)
#define EIF_MAXIMUM_REAL (EIF_MAXIMUM_REAL_64)

/*
  Eiffel type REAL_EXTENDED is #12:
*/
typedef long double T12;
typedef T12 real_extended_t;
#define EIF_REAL_EXTENDED T12
#define M12 (0.0)
#define EIF_MINIMUM_REAL_EXTENDED (-(DBL_MAX))
#define EIF_MAXIMUM_REAL_EXTENDED (DBL_MAX)

/*
  Eiffel type BOOLEAN is #6:
*/
typedef char T6;
#define EIF_BOOLEAN T6
#define M6 (0)
#define EIF_BOOLEAN_BITS (CHAR_BIT)

/*
   Eiffel type POINTER is #8:
*/
typedef void* T8;
#define EIF_POINTER T8
/* Sometimes, NULL is defined as 0 */
#define M8 ((void*)NULL)
#define EIF_POINTER_BITS (CHAR_BIT*sizeof(void*))

/*
  To use type STRING on the C side:
*/
#define EIF_STRING T7*

/*
  Some Other EIF_* defined in ETL:
*/
#define eif_access(x) ((char*)(x))
#define EIF_REFERENCE T0*
#define EIF_OBJ T0*
#define EIF_OBJECT EIF_OBJ

/*
   Wrappers for `malloc' and `calloc':
*/
void* se_malloc(size_t size);
void* se_calloc(size_t nmemb, size_t size);
void* se_realloc(void* src, size_t size);

/*
   die method.
 */
void se_die(int code);

/*
    Runtime hooks. They allow different runtime modules to be quite independant. In time, they will also allow
    thread-safe operations.

    Currently known modules:
      - boost
      - no_check
      - sedb
      - gc
      - print stack
      - profile
      - plugins

    However, currently only profile uses this method. It will be extended to other modules later.

    The currently defined hooks are described in the enum below (the names should be self-explanatory).
 */
typedef enum {
  SE_HANDLE_EXCEPTION_SET, /* called when an exception handler is set, prior to SETJMP */
  SE_HANDLE_EXCEPTION_CLEAR, /* called when a feature with an exception handler normally returns */
  SE_HANDLE_EXCEPTION_THROWN, /* called when an exception is thrown, prior to the LONGJMP */
  SE_HANDLE_ENTER_GC, /* called when gc_start() begins */
  SE_HANDLE_EXIT_GC, /* called when gc_start() ends */
  SE_HANDLE_ENTER_PRINT_STACK, /* called when se_print_run_time_stack() begins */
  SE_HANDLE_EXIT_PRINT_STACK, /* called when se_print_run_time_stack() ends */
  SE_HANDLE_NO_MORE_MEMORY, /* called by se_alloc() and co */
  SE_HANDLE_SEDB_BREAK, /* called when sedb stops the program */
  SE_HANDLE_SEDB_CONTINUE, /* called when sedb continues the program */
  SE_HANDLE_RUNTIME_ERROR, /* called when a runtime error is raised and not caught by an exception. Cannot be raised in boost mode. */
  SE_HANDLE_DIE_WITH_CODE, /* called when the program is stopped by the die_with_code feature. The data points to the int code. */
  SE_HANDLE_NORMAL_EXIT /* called when the program correctly terminates. The data is null. */
} se_handler_action_t;

extern int handlers_count;
typedef void se_runtime_handler_t(se_handler_action_t action, void*data);
void register_handler(se_runtime_handler_t*handler);
void _handle(se_handler_action_t action, void*data);

#define handle(action,data) do{if(handlers_count>0)_handle(action,data);}while(0)

#endif /* #ifndef _BASE_H */
#define SE_BOOST 1
#define SE_GC_LIB 1
#include "X11/extensions/XInput.h"

#define x_list_input_devices(list_size) (XListInputDevices(dpy, list_size))
// XDeviceInfo * XListInputDevices(Display * display, int * returned_list_size);


#define x_device_info_id(device_list, index) (((XDeviceInfo *)device_list)[index].id)
//XID x_device_info_id(XDeviceInfo * device_list, int index)

#define x_device_info_type(device_list, index) (((XDeviceInfo *)device_list)[index].type)
//Atom x_device_info_type(XDeviceInfo * device_list, int index)

#define x_device_info_name(device_list, index) (((XDeviceInfo *)device_list)[index].name)
//char * x_device_info_name(XDeviceInfo * device_list, int index)

#define x_device_info_num_classes(device_list, index) (((XDeviceInfo *)device_list)[index].num_classes)
//int x_device_info_num_classes(XDeviceInfo * device_list, int index)

#define x_device_info_class_info(device_list, index) (((XDeviceInfo *)device_list)[index].inputclassinfo)
//XAnyClassPtr x_device_info_class_info(XDeviceInfo * device_list, int index)

#define x_next_class_info(class_info) ((XAnyClassPtr)((char *)class_info + ((XAnyClassPtr)class_info)->length))
//XAnyClassPtr x_next_class_info(XAnyClassPtr class_info)

#define x_is_key_class_info(class_info) (((XAnyClassPtr)class_info)->class == KeyClass)
//bool x_is_key_class_info(XAnyClassPtr class_info)

#define x_is_button_class_info(class_info) (((XAnyClassPtr)class_info)->class == ButtonClass)
//bool x_is_button_class_info(XAnyClassPtr class_info)

#define x_is_valuator_class_info(class_info) (((XAnyClassPtr)class_info)->class == ValuatorClass)
//bool x_is_valuator_class_info(XAnyClassPtr class_info)

#define x_device_info_is_pointer(device_list, index) (((XDeviceInfo *)device_list)[index].use == IsXPointer)
//bool x_device_info_is_pointer(XDeviceInfo * device_list, int index)

#define x_device_info_is_keyboard(device_list, index) (((XDeviceInfo *)device_list)[index].use == IsXKeyboard)
//bool x_device_info_is_keyboard(XDeviceInfo * device_list, int index)

#ifdef IsXExtensionPointer
/* Defined in .c */
#else
#  define x_device_info_is_available_extension(device_list, index) (((XDeviceInfo *)device_list)[index].use == IsXExtensionDevice)
#endif
//bool x_device_info_is_available_extension(XDeviceInfo * device_list, int index)

#define x_button_info_num_buttons(info) (((XButtonInfo *)info)->num_buttons)
//short x_button_info_num_buttons(XButtonInfo * info)

#define x_valuator_info_minimum(info, index) (((XValuatorInfo *)info)->axes[index].min_value)
//int x_valuator_info_minimum(XValuatorInfo * info, int index)

#define x_valuator_info_maximum(info, index) (((XValuatorInfo *)info)->axes[index].max_value)
//int x_valuator_info_maximum(XValuatorInfo * info, int index)

#define x_valuator_info_resolution(info, index) (((XValuatorInfo *)info)->axes[index].resolution)
//int x_valuator_info_resolution(XValuatorInfo * info, int index)

#define x_open_device(device_id) XOpenDevice(dpy, device_id)
//XDevice * x_open_device(XID device_id)

#define x_close_device(device) XCloseDevice(dpy, device)
//void x_close_device(XDevice * device)

#define x_device_motion_event_data(index) (((XDeviceMotionEvent*)&last_event)->axis_data[index])
//int x_device_motion_event_data(int index)

#define x_device_proximity_event_data(index) (((XProximityNotifyEvent*)&last_event)->axis_data[index])
//int x_device_proximity_event_data(int index)

#define x_device_button_event_number (((XDeviceButtonEvent*)&last_event)->button)
//int x_device_button_event_number

#define x_device_event_time (((XDeviceButtonEvent*)&last_event)->time)
//int x_device_event_time

extern void x_key_info_init(XKeyInfo *info, int *min_k, int *max_k, int *num_k);

extern void x_valuator_info_init(XValuatorInfo *info, int *nb_axes, int *is_absolute, int *buf_size);

extern void * x_device_init_events(XDevice * device, int * events_id);
// Result is XEventClass *

void x_device_select_events(void * window, XEventClass * events_classes);
/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
#ifdef WIN32
#  include <winuser.h>
#  include <mmsystem.h>  /* needed for timeGetTime() */
void vision_init(void);
#  ifndef WM_MOUSEWHEEL
#    define WM_MOUSEWHEEL 0x20A
#  endif
#else
#  include <X11/Xlib.h>
#  include <X11/Xutil.h>
#  include <X11/Xatom.h>
#endif

#ifndef VISION_DEBUG
#  define vision_check_call(x) (x)
#  define vision_check(x)
#else

/* Executes x; if it returns zero, exits. */
#define vision_check_call(x) \
  do { \
    if (!(x)) { \
      fprintf(stderr, "Call failed line %d in %s (call was: \"%s\")\n", __LINE__, __FILE__, #x); exit(1); \
    } \
  } while (0)

/* If x is non-zero, exits. */
#define vision_check(x) \
  do { \
    if (!(x)) { \
      fprintf(stderr, "Check failed line %d in %s (test was: \"%s\")\n", __LINE__, __FILE__, #x); exit(1); \
    } \
  } while (0)

#endif


#define basic_vision_init          _basic_vision_init()
#define basic_vision_next_event    _basic_vision_next_event()
#define basic_vision_character     _basic_vision_character()
#define basic_vision_key           _basic_vision_key()
extern int _basic_vision_init(void);
extern int _basic_vision_next_event(void);
extern int _basic_vision_character(void);
extern int basic_vision_get_keysym(char*);
extern void *basic_vision_get_color(int *r, int *g, int *b);

#ifdef WIN32
  extern HDC hdc;
  extern const char *CLASSNAME;
  extern HINSTANCE main_hInstance;
  extern int main_nCmdShow;
  extern MSG last_message;
  extern HANDLE sem_thread_finished_work;
  extern HANDLE sem_new_window;
  extern void display_error(int num);
  enum commands {CREATE_WINDOW = 1, SET_TITLE, CLEAR_AREA, MAP_WINDOW, MOVE_WINDOW, SET_FOCUS};
  struct cmd_list {struct cmd_list * next; enum commands cmd_type; int param1; int param2; int param3; int param4; int param5; int param6;};
  extern volatile struct cmd_list *first_cmd;
  extern volatile struct cmd_list *first_free_cmd;
  extern HANDLE sem_cmd_ready;

  /* paint message informations */
  extern PAINTSTRUCT paintstruct;

  extern RECT windowRect; /* new window size definition */
  extern DWORD message_thread_id;
  extern int decorated_window_x_offset;
  extern int decorated_window_y_offset;
  extern int decorated_window_width_offset;
  extern int decorated_window_height_offset;

#  define basic_vision_real_event     (last_message.message)
#  define basic_vision_flush          ((void)0)
#  define basic_vision_display_width  (GetSystemMetrics(SM_CXSCREEN))
#  define basic_vision_display_height (GetSystemMetrics(SM_CYSCREEN))
#  define basic_vision_event_widget ((void *)(last_message.hwnd))
#  define basic_vision_pointer_x      ((short)LOWORD(last_message.lParam))
#  define basic_vision_pointer_y      ((short)HIWORD(last_message.lParam))
#  define basic_vision_pointer_x_root (last_message.pt.x)
#  define basic_vision_pointer_y_root (last_message.pt.y)
#  define basic_vision_event_time     (last_message.time)
#  define basic_vision_expose_x       (paintstruct.rcPaint.left)
#  define basic_vision_expose_y       (paintstruct.rcPaint.top)
#  define basic_vision_expose_width   (paintstruct.rcPaint.right-paintstruct.rcPaint.left)
#  define basic_vision_expose_height  (paintstruct.rcPaint.bottom-paintstruct.rcPaint.top)
#  define basic_vision_geometry_x      (windowRect.left)
#  define basic_vision_geometry_y      (windowRect.top)
#  define basic_vision_geometry_width  (windowRect.right)
#  define basic_vision_geometry_height (windowRect.bottom)
#  define basic_vision_geometry_border (GetSystemMetrics(SM_CXBORDER)) /* --TODO: X and Y may have different values */
#  define basic_vision_is_left_down    (GetAsyncKeyState(button_swapped?VK_RBUTTON:VK_LBUTTON)>>15)
#  define basic_vision_is_middle_down  (GetAsyncKeyState(VK_MBUTTON)>>15)
#  define basic_vision_is_right_down   (GetAsyncKeyState(button_swapped?VK_LBUTTON:VK_RBUTTON)>>15)

#  define basic_vision_extension_device_id (fprintf(stderr, "No extension currently available for Windows.\n"))

extern int button_swapped;

#else
  extern Display *dpy;            /* X server connection */
  extern XEvent last_event;

  extern Atom atom_DELWIN;
  extern Atom atom_PROTOCOLS;

#  define basic_vision_real_event      (last_event.type)
#  define basic_vision_flush           XFlush(dpy)
#  define basic_vision_display_width   (DisplayWidth(dpy,DefaultScreen(dpy)))
#  define basic_vision_display_height  (DisplayHeight(dpy,DefaultScreen(dpy)))
#  define basic_vision_event_widget    ((void *)(last_event.xany.window))
#  define basic_vision_pointer_x       (((XButtonEvent*)&last_event)->x)
#  define basic_vision_pointer_y       (((XButtonEvent*)&last_event)->y)
#  define basic_vision_pointer_x_root  (((XButtonEvent*)&last_event)->x_root)
#  define basic_vision_pointer_y_root  (((XButtonEvent*)&last_event)->y_root)
#  define basic_vision_event_time      (((XButtonEvent*)&last_event)->time)
#  define basic_vision_expose_x        (((XExposeEvent*)&last_event)->x)
#  define basic_vision_expose_y        (((XExposeEvent*)&last_event)->y)
#  define basic_vision_expose_width    (((XExposeEvent*)&last_event)->width)
#  define basic_vision_expose_height   (((XExposeEvent*)&last_event)->height)
#  define basic_vision_geometry_x      (((XConfigureEvent*)&last_event)->x)
#  define basic_vision_geometry_y      (((XConfigureEvent*)&last_event)->y)
#  define basic_vision_geometry_width  (((XConfigureEvent*)&last_event)->width)
#  define basic_vision_geometry_height (((XConfigureEvent*)&last_event)->height)
#  define basic_vision_geometry_border (((XConfigureEvent*)&last_event)->border_width)
#  define basic_vision_is_left_down    ((((XCrossingEvent*)&last_event)->state & Button1Mask) != 0 )
#  define basic_vision_is_middle_down  ((((XCrossingEvent*)&last_event)->state & Button2Mask) != 0 )
#  define basic_vision_is_right_down   ((((XCrossingEvent*)&last_event)->state & Button3Mask) != 0 )

/* For X Input extension */
#  define basic_vision_extension_device_id (((XMotionEvent*)&last_event)->root) /* TRICK (should be deviceid of Device Events */

#endif

int vision_available(void);
/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
#include <errno.h>

#define text_file_read_open(p) (fopen(((char*)(p)),"r"))
#define text_file_write_open(p) (fopen(((char*)(p)),"w"))
#define text_file_write_append(p) (fopen(((char*)(p)),"a"))
#define text_file_read_write_open(p) (fopen(((char*)(p)),"r+"))
#define text_file_read_write_append(p) (fopen(((char*)(p)),"a+"))
#define binary_file_read_open(p) (fopen(((char*)(p)),"rb"))
#define binary_file_write_open(p) (fopen(((char*)(p)),"wb"))
#define binary_file_write_append(p) (fopen(((char*)(p)),"ab"))
#define io_fclose(p) (fclose((FILE*)(p)))
#define io_flush(p) (fflush((FILE*)(p)))
#define io_getc(f) (getc(((FILE*)(f))))
#define io_putc(b, f) (putc((b),((FILE*)(f))))
#define io_ungetc(b, f) (ungetc((b), (FILE*)(f)))
#define io_fread(b, n, f) (fread((void *)(b),(size_t)(1), (size_t)(n),(FILE*)(f)))
#define io_fwrite(b, n, f) (fwrite((void *)(b),(size_t)(1), (size_t)(n),(FILE*)(f)))
#define io_feof(f) (feof(((FILE*)(f))))
#define io_rename(o, n) (rename(((char*)(o)),((char*)(n))))
#define io_remove(f) (remove(((char*)(f))))
#define io_fseek(f, o) (fseek((FILE*)(f),(o),SEEK_SET))
#define io_ftell(f) ((EIF_INTEGER_64)ftell((FILE*)(f)))

#if defined __USE_POSIX || defined __unix__ || defined _POSIX_C_SOURCE
#  define read_stdin(b, s) (read(STDIN_FILENO, b, s))
#else
   extern int read_stdin(EIF_CHARACTER *buffer, int size);
#endif

extern void io_copy(char*source, char*target);
extern int io_file_exists(char*source);
extern int io_same_physical_file(char*path1,char*path2);
/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
#include <time.h>

#define basic_time ((EIF_INTEGER_64)time(NULL))
EIF_REAL_64 time_difftime(time_t t2, time_t t1);
EIF_INTEGER time_getyear(time_t t, EIF_INTEGER m);
EIF_INTEGER time_getmonth(time_t t, EIF_INTEGER m);
EIF_INTEGER time_getday(time_t t, EIF_INTEGER m);
EIF_INTEGER time_gethour(time_t t, EIF_INTEGER m);
EIF_INTEGER time_getminute(time_t t, EIF_INTEGER m);
EIF_INTEGER time_getsecond(time_t t, EIF_INTEGER m);
EIF_INTEGER time_getyday(time_t t, EIF_INTEGER m);
EIF_INTEGER time_getwday(time_t t, EIF_INTEGER m);
EIF_BOOLEAN time_is_summer_time_used(time_t t);
EIF_INTEGER_64 time_mktime(EIF_INTEGER year, EIF_INTEGER mon,
			   EIF_INTEGER mday, EIF_INTEGER hour,
			   EIF_INTEGER min,  EIF_INTEGER sec);
void time_add_second(EIF_INTEGER_64 *t, EIF_INTEGER s);
/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
#define sprintf_pointer(buffer, pointer) sprintf((char*)(buffer),"%p",pointer)
void sprintf_real_64(EIF_CHARACTER* b, EIF_CHARACTER m, int32_t f, real64_t r);
void sprintf_real_extended(EIF_CHARACTER* b, EIF_CHARACTER m, int32_t f, real_extended_t r);
/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
#define pointer_hash_code(p) (((unsigned int)(unsigned long)(p))>>1)
#define pointer_to_any(p) ((T0*)(p))
#define pointer_plus(p, o) (((char*)(p))+o)

#define x_get_atom_name(atom) XGetAtomName(dpy, (Atom)atom)

extern int x_query_extension(char * extension_name);

/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
#ifdef WIN32
/*#  include <windows.h> done in base.h */
#  ifndef _MSC_VER
#    include <winsock2.h>
#  endif
   extern int win32_msg;
   extern int win32_msg_ready;
   extern HANDLE sem_msg_ready;
#else
#  include <sys/time.h>
/*#  include <unistd.h> done in base.h */
/*#  include <sys/types.h> done in base.h */
#endif

#ifdef WIN32
#  define sequencer_watch(set, fd) do { \
  if ((fd)==-1) win32_msg=1; else FD_SET((SOCKET)fd, (fd_set*)(set)); \
} while(0)
#else
#  define sequencer_watch(set, fd) FD_SET(fd, (fd_set*)(set))
#endif


#ifdef WIN32
/****TODO: fd evaluated twice. */
#  define sequencer_is_ready(set, fd) (EIF_BOOLEAN)(((fd)==-1)?win32_msg_ready:FD_ISSET(fd, (fd_set*)(set)))
#else
#  define sequencer_is_ready(set, fd) FD_ISSET(fd, (fd_set*)(set))
#endif


#ifdef WIN32
#  define sequencer_reset(set) do{win32_msg=0;win32_msg_ready=FALSE;FD_ZERO((fd_set*)(set));}while(0)
#else
#  define sequencer_reset(set) FD_ZERO((fd_set*)(set))
#endif

#define sequencer_create_set (_sequencer_create_set())
EIF_POINTER _sequencer_create_set(void);
int sequencer_wait(int n, fd_set *read_set, int read_size, fd_set *write_set, int write_size, fd_set *exception_set, int exception_size, int s, int us);

#define sequencer_descriptor(file) (fileno((FILE *)(file)))
#include "Ivy/ivy.h"
#include "Ivy/ivyloop.h"
#include "Ivy/ivysocket.h"

extern void ivy_init(char * application_name, char * ready_text, void * eiffel_object, void * channel_up_callback, void * channel_down_callback, void * agent_call_callback);

extern void * bind_message(char * pattern, void * agent);

#define send_message(txt) IvySendMsg("%s", txt)
#define IvyIdle IvyIdle()
#define delete_callback(delete_func, data) ((void (*)(void *))delete_func)(data)
#define read_callback(read_func, channel, descriptor, data) ((void (*)(void *, int, void *))read_func)(channel, descriptor, data)
/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
#ifndef WIN32
#  include <sys/time.h>
#endif

extern EIF_INTEGER basic_microsecond_microsecond;
extern EIF_INTEGER_64 basic_microsecond_time;
#define basic_microsecond_update (_basic_microsecond_update())
void _basic_microsecond_update(void);
/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
#ifdef WIN32
extern void new_window(void);

typedef struct window_description_s window_description;
struct window_description_s {
  HWND Current;
  HBRUSH background;
  HBITMAP background_pixmap; /* if non-void, use this pixmap for background 
				painting. Useful for Win95 only */
  struct window_description_s *parent;
  int marked;
  int min_width;
  int max_width;
  int min_height;
  int max_height;
  int decorated;
};

extern window_description screen_desc;

#  define basic_window_root_id NULL
#else
#  define basic_window_root_id ((void*)DefaultRootWindow(dpy))
#endif


extern void * basic_window_create(int x, int y, int width, int height, void * parent, int decorate);

extern void * basic_window_get_drawing_widget(void *window);

extern char* basic_window_get_title(void *window);

extern void basic_window_free_title(void *title);

extern void basic_window_set_title(void *window, void *title);

extern void basic_window_set_bg_color(void *window, void *color);

extern void basic_window_set_bg_pixmap(void *window, void *pixmap);

extern void basic_window_clear_no_expose(void *window);

extern void basic_window_clear_area_no_expose(void *window, int x, int y, int w, int h);

extern void basic_window_clear_area(void *window, int x, int y, int w, int h);

extern void basic_window_set_kbd_focus(void *window);

extern void basic_window_map(void *window);

extern void basic_window_unmap(void *window);

extern void basic_window_set_geometry(void *window,int x, int y, int w, int h);
     
extern void basic_window_set_requisition(void *window, int min_w, int min_h, int max_w, int max_h);

extern void basic_window_set_position(void *window, int x, int y);
   
extern void basic_window_set_size(void *window, int x, int y, int width, int height);
/* C Header Pass 1: */
typedef union _se_agent se_agent;
typedef struct _se_agent0 se_agent0;
typedef struct S113 T113;
typedef struct S123 T123;
typedef struct S205 T205;
typedef T0 T245;
typedef struct S290 T290;
typedef struct S192 T192;
typedef struct S131 T131;
typedef struct S329 T329;
typedef struct S327 T327;
typedef struct S326 T326;
typedef struct S317 T317;
typedef struct S311 T311;
typedef struct S308 T308;
typedef struct S307 T307;
typedef struct S146 T146;
typedef struct S149 T149;
typedef struct S148 T148;
typedef struct S302 T302;
typedef struct S300 T300;
typedef struct S261 T261;
typedef struct S298 T298;
typedef struct S297 T297;
typedef struct S296 T296;
typedef struct S293 T293;
typedef struct S292 T292;
typedef struct S289 T289;
typedef struct S288 T288;
typedef struct S287 T287;
typedef struct S284 T284;
typedef struct S153 T153;
typedef struct S155 T155;
typedef struct S280 T280;
typedef struct S154 T154;
typedef struct S279 T279;
typedef struct S160 T160;
typedef struct S277 T277;
typedef struct S276 T276;
typedef struct S275 T275;
typedef struct S273 T273;
typedef struct S271 T271;
typedef struct S269 T269;
typedef struct S268 T268;
typedef struct S267 T267;
typedef struct S266 T266;
typedef struct S265 T265;
typedef struct S68 T68;
typedef struct S263 T263;
typedef struct S262 T262;
typedef struct S260 T260;
typedef struct S259 T259;
typedef struct S257 T257;
typedef struct S256 T256;
typedef struct S7 T7;
typedef struct S253 T253;
typedef T0 T251;
typedef struct S250 T250;
typedef struct S249 T249;
typedef struct S248 T248;
typedef struct S73 T73;
typedef struct S134 T134;
typedef struct S133 T133;
typedef struct S53 T53;
typedef void*T46;
typedef struct S191 T191;
typedef struct S247 T247;
typedef int T150;
typedef void*T43;
typedef struct S70 T70;
typedef struct S244 T244;
typedef struct S71 T71;
typedef struct S65 T65;
typedef struct S25 T25;
/* C Header Pass 2: */
typedef T0**T337;
#define M337 NULL
typedef T0**T336;
#define M336 NULL
typedef T0**T335;
#define M335 NULL
typedef T0**T334;
#define M334 NULL
typedef T0**T333;
#define M333 NULL
typedef T0**T332;
#define M332 NULL
typedef T0**T331;
#define M331 NULL
typedef T0**T330;
#define M330 NULL
typedef T0**T328;
#define M328 NULL
typedef T0**T324;
#define M324 NULL
typedef T0**T321;
#define M321 NULL
typedef T0**T316;
#define M316 NULL
typedef T0**T310;
#define M310 NULL
typedef T0**T306;
#define M306 NULL
typedef T0**T305;
#define M305 NULL
typedef T0**T304;
#define M304 NULL
typedef T0**T303;
#define M303 NULL
typedef T0**T301;
#define M301 NULL
typedef T0**T299;
#define M299 NULL
typedef T0**T295;
#define M295 NULL
typedef T2*T294;
#define M294 NULL
typedef T0**T291;
#define M291 NULL
typedef T0**T283;
#define M283 NULL
typedef T0**T282;
#define M282 NULL
typedef T0**T281;
#define M281 NULL
typedef T0**T264;
#define M264 NULL
typedef T0**T255;
#define M255 NULL
typedef T8*T254;
#define M254 NULL
typedef T3*T9;
#define M9 NULL
/* C Header Pass 3: */
struct S205{T11 _time_memory;};
int se_cmpT205(T205* o1,T205* o2);
struct S192{T205 _time;T2 _microsecond;};
int se_cmpT192(T192* o1,T192* o2);
/* C Header Pass 4: */
struct S113{Tid id;T0* _stream;};
extern T113 M113;
struct S123{Tid id;T0* _input_stream;};
extern T123 M123;
extern T205 M205;
extern T192 M192;
struct S329{Tid id;T0* _item;};
extern T329 M329;
struct S327{T0* _item;T8 _key;T0* _next;};
extern T327 M327;
struct S326{Tid id;T0* _item;};
extern T326 M326;
struct S317{Tid id;T0* _item;};
extern T317 M317;
struct S311{Tid id;T0* _item;};
extern T311 M311;
struct S308{Tid id;T0* _item;};
extern T308 M308;
struct S307{T0* _item;T2 _key;T0* _next;};
extern T307 M307;
struct S302{Tid id;T0* _item;};
extern T302 M302;
struct S300{T0* _item;T0* _key;T0* _next;};
extern T300 M300;
struct S298{T334 _storage;T2 _capacity;T2 _upper;};
extern T298 M298;
struct S297{Tid id;T0* _item;};
extern T297 M297;
struct S296{T2 _item;T2 _key;T0* _next;};
extern T296 M296;
struct S293{Tid id;T0* _item;};
extern T293 M293;
struct S292{T8 _item;T0* _key;T0* _next;};
extern T292 M292;
struct S290{T0* _item;T0* _key;T0* _next;};
extern T290 M290;
struct S289{Tid id;T0* _item;};
extern T289 M289;
struct S288{T333 _buckets;T2 _capacity;T2 _count;T2 _cache_user;T0* _free_nodes;};
extern T288 M288;
struct S287{Tid id;T0* _item;};
extern T287 M287;
struct S284{T0* _item;T0* _key;T0* _next;};
extern T284 M284;
struct S280{T332 _storage;T2 _capacity;T2 _upper;};
extern T280 M280;
struct S154{T6 _queryable;T2 _timeout;T192 _expiration;T6 _expiration_valid;T6 _current_time_valid;T8 _read_set;T2 _read_size;T8 _write_set;T2 _write_size;T8 _exception_set;T2 _exception_size;T2 _highest;};
extern T154 M154;
struct S279{T331 _storage;T2 _capacity;T2 _upper;};
extern T279 M279;
struct S160{T0* _container;};
extern T160 M160;
struct S277{T330 _storage;T2 _capacity;T2 _upper;};
extern T277 M277;
struct S276{T328 _buckets;T2 _capacity;T2 _count;T2 _cache_user;T0* _free_nodes;};
extern T276 M276;
struct S275{T324 _buckets;T2 _capacity;T2 _count;T2 _cache_user;T0* _free_nodes;};
extern T275 M275;
struct S273{T321 _storage;T2 _capacity;T2 _upper;};
extern T273 M273;
struct S271{T316 _buckets;T2 _capacity;T2 _count;T2 _cache_user;T0* _free_nodes;};
extern T271 M271;
struct S269{T310 _buckets;T2 _capacity;T2 _count;T2 _cache_user;T0* _free_nodes;};
extern T269 M269;
struct S268{T306 _buckets;T2 _capacity;T2 _count;T2 _cache_user;T0* _free_nodes;};
extern T268 M268;
struct S146{T2 _key_count;T2 _minimum_code;T2 _maximum_code;};
extern T146 M146;
struct S267{T305 _storage;T2 _capacity;T2 _upper;};
extern T267 M267;
struct S149{T2 _buttons_count;};
extern T149 M149;
struct S266{T304 _storage;T2 _capacity;T2 _upper;};
extern T266 M266;
struct S148{T6 _absolute;T2 _motion_buffer_size;T0* _minimums;T0* _maximums;T0* _resolutions;};
extern T148 M148;
struct S265{T303 _storage;T2 _capacity;T2 _upper;};
extern T265 M265;
struct S263{T301 _buckets;T2 _capacity;T2 _count;T2 _cache_user;T0* _free_nodes;};
extern T263 M263;
struct S262{T299 _storage;T2 _capacity;T2 _upper;};
extern T262 M262;
struct S261{T0* _callbacks;T2 _last;T2 _index;};
extern T261 M261;
struct S260{T295 _buckets;T2 _capacity;T2 _count;T2 _cache_user;T0* _free_nodes;};
extern T260 M260;
struct S259{T294 _storage;T2 _capacity;T2 _upper;};
extern T259 M259;
struct S257{T255 _storage;T2 _capacity;T2 _upper;T2 _lower;};
extern T257 M257;
struct S256{T294 _storage;T2 _capacity;T2 _upper;T2 _lower;T2 _storage_lower;};
extern T256 M256;
struct S253{T291 _buckets;T2 _capacity;T2 _count;T2 _cache_user;T0* _free_nodes;};
extern T253 M253;
struct S250{T283 _buckets;T2 _capacity;T2 _count;T2 _cache_user;T0* _free_nodes;};
extern T250 M250;
struct S153{Tid id;T0* _stream_exception;T0* _can_read;T6 _is_connected;T2 _filtered_descriptor;T8 _delete_function;T8 _read_function;T8 _write_function;T8 _data;};
extern T153 M153;
struct S249{T282 _storage;T2 _capacity;T2 _upper;};
extern T249 M249;
struct S248{T281 _storage;T2 _capacity;T2 _upper;};
extern T248 M248;
struct S155{T0* _job_list;T0* _finished_jobs;T0* _ready_jobs;T0* _events;T6 _pause;T6 _break;};
extern T155 M155;
struct S73{T8 _widget;T0* _layout;T2 _height;T2 _width;T2 _min_height;T2 _min_width;T2 _std_width;T2 _std_height;T0* _child;};
extern T73 M73;
struct S134{Tid id;T0* _can_read;T2 _descriptor;};
extern T134 M134;
struct S133{T0* _loop_stack;T6 _stop;T0* _vision;T0* _event_catcher_stack;};
extern T133 M133;
struct S131{Tid id;T2 _priority;T6 _done;T2 _current_event_type;T0* _widget;T0* _event;T0* _pointer_move_event;T0* _geometry_change_event;T0* _extension_devices;T0* _graphic_connection;T6 _suspend;T0* _event_catcher_found;};
extern T131 M131;
struct S53{T2 _buffer_position;T9 _buffer;T2 _capacity;};
extern T53 M53;
extern T46 M46;
struct S191{T0* _devices;};
extern T191 M191;
struct S247{T264 _storage;T2 _capacity;T2 _upper;};
extern T247 M247;
extern T150 M150;
struct S68{T2 _device_id;T0* _name;T0* _type;T6 _is_current_pointer;T6 _is_current_keyboard;T6 _is_available_extension;T0* _key_capabilities;T0* _button_capabilities;T0* _axes_capabilities;T8 _x_device;T0* _actions;T0* _events_indexes;T0* _events_id;T8 _events_classes;};
extern T68 M68;
extern T43 M43;
struct S70{T0* _xinput_ivy;T2 _x_offset;T2 _y_offset;T6 _cropping;T2 _crop_height;T2 _x_max_crop;T2 _y_min_crop;T2 _x_min_crop;T2 _y_max_crop;T2 _crop_width;T5 _prediction_time;T2 _ignored_counter;T2 _ignore_rate;T0* _button_message_header;T0* _pointer_message_header;T2 _old_presure;T0* _time_history;T0* _y_history;T0* _x_history;T2 _predicted_y;T2 _predicted_x;T5 _a2y;T5 _a2x;T5 _t0;T5 _y2;T5 _x2;T5 _s2y;T5 _s2x;T5 _s2yn;T5 _s2xn;T5 _t2;T5 _t1;};
extern T70 M70;
struct S244{T255 _storage;T2 _capacity;T2 _upper;};
extern T244 M244;
struct S7{T9 _storage;T2 _count;T2 _capacity;};
extern T7 M7;
struct S71{Tid id;T2 _priority;T6 _started;T0* _pattern_list;T0* _callback_list;T2 _destination_count;T0* _tmp_client_list;T6 _done;T0* _events_set;T0* _ivy_clients;T0* _application_name_;T0* _ready_message_;};
extern T71 M71;
struct S65{T2 _display_width;T2 _display_height;T0* _loop_stack;T0* _event_catcher;T0* _graphic_connection;T0* _widget;};
extern T65 M65;
struct S25{T0* _ivy_bus;T0* _application_name;T0* _device_id;T0* _screen;int _x11;T2 _left_pad_position;T2 _right_pad_position;T0* _ivy;};
extern T25 M25;
extern char*s25_0;
extern char*s25_21190322;
extern char*s25_314746909;
extern char*s70_190991;
extern char*s70_475;
extern char*s70_112207026;
extern char*s70_220157120;
extern char*s13_1432888418;
extern char*s70_697;
extern char*s70_1961093439;
extern char*s70_104371129;
extern char*s70_104371267;
extern char*s70_1699147265;
extern char*s13_1210;
extern char*s70_1756148648;
extern char*s70_1756148653;
extern char*s25_1948078333;
extern char*s25_92383297;
extern char*s70_1461;
extern char*s70_1466;
extern char*s70_23436791;
extern char*s25_1666922512;
extern char*s70_56246305;
extern char*s25_1957581;
extern char*s25_1403610646;
extern char*s70_4725661;
extern char*s70_4725666;
extern char*s70_4738061;
extern char*s25_1213754110;
extern char*s25_765567725;
extern char*s25_1387538644;
extern char*s25_1370426634;
extern char*s70_2179769;
extern char*s25_751291742;
extern char*s25_1554692325;
extern char*s70_2097616536;
extern char*s25_357338863;
extern char*s70_2676;
extern char*s70_1874520032;
extern char*s70_1619665677;
extern char*s25_1491411490;
extern char*s25_4487261;
extern char*s70_1940108584;
extern char*s25_694149733;
extern char*s65_1686724329;
extern char*s70_586741066;
extern char*s25_89639;
extern char*s70_15980;
extern char*s70_397440;
extern char*s25_69208946;
extern char*s70_188916;
extern char*s25_447643634;
extern char*s70_2057747851;
extern char*s25_3479972;
extern char*s25_1126339109;
extern char*s25_557679246;
extern char*s25_1638797568;
extern char*s25_1260406502;
extern char*s70_22702411;
extern char*s70_22702416;
extern char*s25_946366;
extern char*s70_1501987274;
extern char*s25_382517595;
extern char*s70_952626;
extern char*s70_2112369621;
extern char*s70_10739017;
extern char*s70_10739024;
extern char*s70_10739030;
extern char*s71_202554;
extern char*s150_1472358418;
extern char*s25_1959886733;
extern char*s70_1257860908;
/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
#define SE_BOOST 1
void se_print_run_time_stack (void);
void se_signal_handler(int sig);
#define FSOC_SIZE 8192
#define RSOC_SIZE 32768
/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
/*
   This file (SmartEiffel/sys/runtime/gc_lib.h) is automatically included
   when the Garbage Collector is used (default, unless option -no_gc has
   been selected).
*/

#define SE_GC_LIB 1

#define SE_GC_LOW_MEMORY_STRATEGY 0
#define SE_GC_HIGH_MEMORY_STRATEGY 1
#define SE_GC_DEFAULT_MEMORY_STRATEGY 2
extern int se_gc_strategy;


#define RSOH_UNMARKED 15253
#define RSOH_FREE 1
#define RSOH_MARKED 2


#define FSOH_UNMARKED ((void *) 1)
#define FSOH_MARKED   ((void *) 2)

/* To codify the state and the type of some Memory Chunk, we are
   using the following definitions :
*/
#define FSO_FREE_CHUNK  (-2)
#define RSO_FREE_CHUNK  (-1)
#define RSO_USED_CHUNK  ( 0)
#define FSO_STORE_CHUNK ( 1)
#define FSO_USED_CHUNK  ( 2)
#define FREE_CHUNK(x) ((x)<0)

/* Minimum size for a store area in a ReSizable Objects Chunk :
 */
#define RSOC_MIN_STORE 512

/* The default channel used to print -gc_info flag information :
*/
#define SE_GCINFO SE_ERR

extern int collector_counter; /* MEMORY.collector_counter */

typedef struct s_mch mch; /* Memory Chunk Header. */
typedef struct s_fsoc fsoc; /* Fixed Size Objects Chunk. */
typedef union u_rsoh rsoh; /* ReSizable Object Header. */
typedef struct s_fll_rsoh fll_rsoh;
typedef struct s_rsoc rsoc; /* ReSizable Objects Chunk. */
typedef struct s_na_env na_env; /* Native Array ENVironment. */


struct s_mch{
  unsigned int size; /* In number of bytes (actual argument of malloc).*/
  int state_type; /* One value in : RSO_USED_CHUNK,
                     FREE_CHUNK, FSO_STORE_CHUNK, FSO_USED_CHUNK */
  void(*amfp)(mch*,void*); /* Align Mark Function Pointer. */
  void(*swfp)(mch*); /* SWeep Function Pointer. */
};

struct s_fsoc{
  mch header; /* Common header for fsoc and rsoc. */
  fsoc* next; /* The next one when in free list (fsocfl). */
  int count_minus_one;
  double first_object;
};

typedef struct _rso_header rso_header;

struct _rso_header{
    unsigned int size;
    int magic_flag;     /* RSOH_MARKED when used,
			   RSOH_FREE when free,
			   else RSOH_UNMARKED */
};

typedef union u_fso_header fso_header;

union u_fso_header{
  void* flag;
  void* next;/* accurately typed as gcXX* in actual fso headers */
};

union u_rsoh{
  rso_header header;
  double padding;
};

struct s_fll_rsoh {
  rso_header rsoh_field;
  fll_rsoh* nextflol;
};

struct s_rsoc{
  mch header; /* Common header for fsoc and rsoc. */
  unsigned int isize; /* Initial size (at malloc time) to detect split chunks. */
  rsoc* next; /* Next one when in free list (rsocfl) or in na_env->chunk_list. */
  fll_rsoh*free_list_of_large; /* Intra. free list. */
  na_env*nae;
  rsoh first_header;
};

struct s_na_env{
  unsigned int store_left;
  rsoh* store;
  rsoc*store_chunk;
  rsoc*chunk_list; /*List of chunks of that type that have a non-null free_list_of_large*/
  void (*gc_mark)(T0*);
  int space_used;
};

extern void**stack_bottom;
extern mch**gcmt;
extern int gcmt_max;
extern int gcmt_used;
extern int gc_is_off;
extern fsoc* fsocfl;
extern unsigned int fsoc_count;
extern unsigned int rsoc_count;
extern void*gcmt_tail_addr;

void gc_sweep(void);
void gc_mark(void* p);
mch* gc_find_chunk(void* p);
int gc_stack_size(void);
int garbage_delayed(void);
void gc_update_ceils(void);
char*new_na(na_env*nae,unsigned int size);
unsigned int fsocfl_count(void);
unsigned int rsocfl_count(void);
void gc_dispose_before_exit(void);
void mark_stack_and_registers (void);
fsoc* gc_fsoc_get1(void);
fsoc* gc_fsoc_get2(void);

int gc_memory_used(void);
/*The generic se_agent0 definition:*/
struct _se_agent0{
Tid id;
Tid creation_mold_id;
void(*afp)(se_agent*);void(*gc_mark_agent_mold)(se_agent*);
int(*eq)(se_agent*,se_agent*);
};
extern unsigned int fsoc_count_ceil;
extern unsigned int rsoc_count_ceil;
/*INTEGER_16*/T2 r10to_integer_32(T10 C);
/*INTEGER_16*/T3 r10decimal_digit(T10 C);
/*INTEGER_16*/void r10append_in(T10 C,T0* a1);
extern T9 oBC102sprintf_buffer;
/*REAL_64*/void r5append_in_format(T5 C,T0* a1,T2 a2);
/*POINTER*/T2 r8hash_code(T8 C);
/*INTEGER_32*/T10 r2high_16(T2 C);
/*INTEGER_32*/T6 r2in_range(T2 C,T2 a1,T2 a2);
/*INTEGER_32*/T2 r2max(T2 C,T2 a1);
/*INTEGER_32*/T3 r2decimal_digit(T2 C);
/*INTEGER_32*/void r2append_in(T2 C,T0* a1);
/*CHARACTER*/T6 r3_ix_6261(T3 C,T3 a1);
/*CHARACTER*/T6 r3_ix_6061(T3 C,T3 a1);
/*CHARACTER*/T6 r3is_digit(T3 C);
/*CHARACTER*/T1 r3value(T3 C);
/*CHARACTER*/T6 r3is_separator(T3 C);
/*CHARACTER*/T1 r3decimal_value(T3 C);
/*BOOLEAN*/T6 r6_ix_or(T6 C,T6 a1);
/*NATIVE_ARRAY[PROCEDURE[TUPLE[X_INPUT_DEVICE]]]*/T334 r334realloc(T334 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[PROCEDURE[TUPLE[X_INPUT_DEVICE]]]*/void r334copy_from(T334 C,T334 a1,T2 a2);
/*NATIVE_ARRAY[PROCEDURE[TUPLE[X_INPUT_DEVICE]]]*/void r334clear_all(T334 C,T2 a1);
/*NATIVE_ARRAY[HASHED_DICTIONARY_NODE[WEAK_REFERENCE[ANY_HASHED_DICTIONARY_NODE],STRING]]*/void r333clear_all(T333 C,T2 a1);
/*NATIVE_ARRAY[JOB]*/T332 r332realloc(T332 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[JOB]*/void r332copy_from(T332 C,T332 a1,T2 a2);
/*NATIVE_ARRAY[JOB]*/void r332clear_all(T332 C,T2 a1);
/*NATIVE_ARRAY[JOB]*/void r332remove(T332 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[TOPLEVEL_WINDOW]*/void r331clear_all(T331 C,T2 a1);
/*NATIVE_ARRAY[EVENT_CATCHER]*/void r330clear_all(T330 C,T2 a1);
/*NATIVE_ARRAY[HASHED_DICTIONARY_NODE[SENSITIVE,POINTER]]*/void r328clear_all(T328 C,T2 a1);
/*NATIVE_ARRAY[HASHED_DICTIONARY_NODE[SIGNAL_0,SENSITIVE]]*/void r324clear_all(T324 C,T2 a1);
/*NATIVE_ARRAY[DICTIONARY[SIGNAL_0,SENSITIVE]]*/void r321clear_all(T321 C,T2 a1);
/*NATIVE_ARRAY[HASHED_DICTIONARY_NODE[SIGNAL_2[INTEGER_32,INTEGER_32],SENSITIVE]]*/void r316clear_all(T316 C,T2 a1);
/*NATIVE_ARRAY[HASHED_DICTIONARY_NODE[SIGNAL_4[INTEGER_32,INTEGER_32,INTEGER_32,INTEGER_32],SENSITIVE]]*/void r310clear_all(T310 C,T2 a1);
/*NATIVE_ARRAY[HASHED_DICTIONARY_NODE[EXTENSION_DEVICE,INTEGER_32]]*/void r306clear_all(T306 C,T2 a1);
/*NATIVE_ARRAY[KEY_RANGE]*/T305 r305realloc(T305 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[KEY_RANGE]*/void r305copy_from(T305 C,T305 a1,T2 a2);
/*NATIVE_ARRAY[KEY_RANGE]*/void r305clear_all(T305 C,T2 a1);
/*NATIVE_ARRAY[BUTTON_RANGE]*/T304 r304realloc(T304 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[BUTTON_RANGE]*/void r304copy_from(T304 C,T304 a1,T2 a2);
/*NATIVE_ARRAY[BUTTON_RANGE]*/void r304clear_all(T304 C,T2 a1);
/*NATIVE_ARRAY[AXES_RANGE]*/T303 r303realloc(T303 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[AXES_RANGE]*/void r303copy_from(T303 C,T303 a1,T2 a2);
/*NATIVE_ARRAY[AXES_RANGE]*/void r303clear_all(T303 C,T2 a1);
/*NATIVE_ARRAY[HASHED_DICTIONARY_NODE[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]]*/void r301clear_all(T301 C,T2 a1);
/*NATIVE_ARRAY[SIGNAL_1[X_INPUT_DEVICE]]*/void r299clear_all(T299 C,T2 a1);
/*NATIVE_ARRAY[HASHED_DICTIONARY_NODE[INTEGER_32,INTEGER_32]]*/void r295clear_all(T295 C,T2 a1);
/*NATIVE_ARRAY[INTEGER_32]*/void r294set_slice_with(T294 C,T2 a1,T2 a2,T2 a3);
/*NATIVE_ARRAY[INTEGER_32]*/T294 r294realloc(T294 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[INTEGER_32]*/void r294copy_from(T294 C,T294 a1,T2 a2);
/*NATIVE_ARRAY[INTEGER_32]*/void r294clear_all(T294 C,T2 a1);
/*NATIVE_ARRAY[INTEGER_32]*/void r294set_all_with(T294 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[HASHED_DICTIONARY_NODE[POINTER,STRING]]*/void r291clear_all(T291 C,T2 a1);
/*NATIVE_ARRAY[HASHED_DICTIONARY_NODE[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]]*/void r283clear_all(T283 C,T2 a1);
/*NATIVE_ARRAY[IVY_CLIENT]*/T282 r282realloc(T282 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[IVY_CLIENT]*/void r282clear_all(T282 C,T2 a1);
/*NATIVE_ARRAY[IVY_CLIENT]*/void r282copy_from(T282 C,T282 a1,T2 a2);
/*NATIVE_ARRAY[IVY_CLIENT]*/void r282remove(T282 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[IVY_CLIENT]*/void r282clear(T282 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[IVY_CLIENT]*/T2 r282fast_index_of(T282 C,T0* a1,T2 a2,T2 a3);
/*NATIVE_ARRAY[LOOP_ITEM]*/T281 r281realloc(T281 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[LOOP_ITEM]*/void r281copy_from(T281 C,T281 a1,T2 a2);
/*NATIVE_ARRAY[LOOP_ITEM]*/void r281clear_all(T281 C,T2 a1);
/*NATIVE_ARRAY[X_INPUT_DEVICE]*/void r264clear_all(T264 C,T2 a1);
/*NATIVE_ARRAY[STRING]*/T255 r255realloc(T255 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[STRING]*/void r255copy_from(T255 C,T255 a1,T2 a2);
/*NATIVE_ARRAY[STRING]*/void r255clear_all(T255 C,T2 a1);
/*NATIVE_ARRAY[STRING]*/void r255set_all_with(T255 C,T0* a1,T2 a2);
/*NATIVE_ARRAY[STRING]*/void r255clear(T255 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[CHARACTER]*/void r9fast_replace_all(T9 C,T3 a1,T3 a2,T2 a3);
/*NATIVE_ARRAY[CHARACTER]*/T9 r9realloc(T9 C,T2 a1,T2 a2);
/*NATIVE_ARRAY[CHARACTER]*/void r9copy_from(T9 C,T9 a1,T2 a2);
/*NATIVE_ARRAY[CHARACTER]*/void r9clear_all(T9 C,T2 a1);
/*NATIVE_ARRAY[CHARACTER]*/void r9copy_at(T9 C,T2 a1,T9 a2,T2 a3);
/*NATIVE_ARRAY[CHARACTER]*/T6 r9fast_memcmp(T9 C,T9 a1,T2 a2);
/*NATIVE_ARRAY[CHARACTER]*/T2 r9fast_index_of(T9 C,T3 a1,T2 a2,T2 a3);
/*NATIVE_ARRAY[CHARACTER]*/T2 r9fast_occurrences(T9 C,T3 a1,T2 a2);
T7*create7from_external(T8 a1);
/*STRING*/T6 r7is_equal(T7* C,T0* a1);
/*STRING*/T5 r7to_real(T7* C);
/*STRING*/void r7put(T7* C,T3 a1,T2 a2);
/*STRING*/void r7remove_between(T7* C,T2 a1,T2 a2);
/*STRING*/void r7copy(T7* C,T0* a1);
extern T0*oBC7string_buffer;
extern int fBC7string_buffer;
/*STRING*/T0* r7string_buffer(void);
extern T0*oBC7split_buffer;
extern int fBC7split_buffer;
/*STRING*/T0* r7split_buffer(void);
/*STRING*/T0* r7split(T7* C);
/*STRING*/void r7append(T7* C,T0* a1);
/*STRING*/T6 r7is_real(T7* C);
/*STRING*/T2 r7index_of(T7* C,T3 a1,T2 a2);
/*STRING*/void r7replace_all(T7* C,T3 a1,T3 a2);
/*STRING*/T6 r7is_integer(T7* C);
/*STRING*/T0* r7twin(T7* C);
/*STRING*/void r7remove_tail(T7* C,T2 a1);
/*STRING*/T6 r7has_prefix(T7* C,T0* a1);
/*STRING*/void r7extend(T7* C,T3 a1);
/*STRING*/T2 r7hash_code(T7* C);
/*STRING*/void r7remove_last(T7* C);
/*STRING*/void r7make(T7* C,T2 a1);
/*STRING*/void r7add_last(T7* C,T3 a1);
/*STRING*/void r7ensure_capacity(T7* C,T2 a1);
/*STRING*/void r7from_external_copy(T7* C,T8 a1);
/*STRING*/void r7from_external(T7* C,T8 a1);
/*STRING*/T8 r7to_external(T7* C);
/*STRING*/T2 r7to_integer(T7* C);
/*STRING*/void r7remove_head(T7* C,T2 a1);
/*STRING*/void r7split_in(T7* C,T0* a1);
/*STRING*/void r7swap(T7* C,T2 a1,T2 a2);
/*STRING*/T3 r7item(T7* C,T2 a1);
/*STRING*/T2 r7first_index_of(T7* C,T3 a1);
/*STRING*/T2 r7occurrences(T7* C,T3 a1);
/*FAST_ARRAY[PROCEDURE[TUPLE[X_INPUT_DEVICE]]]*/void r298make(T298* C,T2 a1);
/*FAST_ARRAY[PROCEDURE[TUPLE[X_INPUT_DEVICE]]]*/void r298add_last(T298* C,T0* a1);
/*FAST_ARRAY[PROCEDURE[TUPLE[X_INPUT_DEVICE]]]*/void r298mark_native_arrays(T298* C);
/*FAST_ARRAY[JOB]*/void r280move(T280* C,T2 a1,T2 a2,T2 a3);
/*FAST_ARRAY[JOB]*/void r280remove(T280* C,T2 a1);
/*FAST_ARRAY[JOB]*/void r280make(T280* C,T2 a1);
/*FAST_ARRAY[JOB]*/void r280add_last(T280* C,T0* a1);
/*FAST_ARRAY[JOB]*/T6 r280is_empty(T280* C);
/*FAST_ARRAY[JOB]*/void r280mark_native_arrays(T280* C);
/*FAST_ARRAY[JOB]*/void r280add(T280* C,T0* a1,T2 a2);
/*FAST_ARRAY[TOPLEVEL_WINDOW]*/void r279make(T279* C,T2 a1);
/*FAST_ARRAY[TOPLEVEL_WINDOW]*/void r279mark_native_arrays(T279* C);
/*FAST_ARRAY[EVENT_CATCHER]*/void r277make(T277* C,T2 a1);
/*FAST_ARRAY[EVENT_CATCHER]*/void r277mark_native_arrays(T277* C);
/*FAST_ARRAY[DICTIONARY[SIGNAL_0,SENSITIVE]]*/void r273make(T273* C,T2 a1);
/*FAST_ARRAY[DICTIONARY[SIGNAL_0,SENSITIVE]]*/void r273mark_native_arrays(T273* C);
/*FAST_ARRAY[KEY_RANGE]*/void r267make(T267* C,T2 a1);
/*FAST_ARRAY[KEY_RANGE]*/void r267add_last(T267* C,T0* a1);
/*FAST_ARRAY[KEY_RANGE]*/void r267mark_native_arrays(T267* C);
/*FAST_ARRAY[BUTTON_RANGE]*/void r266make(T266* C,T2 a1);
/*FAST_ARRAY[BUTTON_RANGE]*/void r266add_last(T266* C,T0* a1);
/*FAST_ARRAY[BUTTON_RANGE]*/void r266mark_native_arrays(T266* C);
/*FAST_ARRAY[AXES_RANGE]*/void r265make(T265* C,T2 a1);
/*FAST_ARRAY[AXES_RANGE]*/void r265add_last(T265* C,T0* a1);
/*FAST_ARRAY[AXES_RANGE]*/void r265mark_native_arrays(T265* C);
/*FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]]*/void r262make(T262* C,T2 a1);
/*FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]]*/void r262mark_native_arrays(T262* C);
/*FAST_ARRAY[INTEGER_32]*/void r259make(T259* C,T2 a1);
/*FAST_ARRAY[INTEGER_32]*/T2 r259count(T259* C);
/*ARRAY[STRING]*/void r257put(T257* C,T0* a1,T2 a2);
/*ARRAY[STRING]*/void r257clear_all(T257* C);
/*ARRAY[STRING]*/void r257copy(T257* C,T0* a1);
/*ARRAY[STRING]*/void r257set_all_with(T257* C,T0* a1);
/*ARRAY[STRING]*/T0* r257twin(T257* C);
/*ARRAY[STRING]*/void r257clear_count(T257* C);
/*ARRAY[STRING]*/void r257remove_last(T257* C);
/*ARRAY[STRING]*/void r257add_last(T257* C,T0* a1);
/*ARRAY[STRING]*/void r257with_capacity(T257* C,T2 a1,T2 a2);
/*ARRAY[STRING]*/T2 r257count(T257* C);
/*ARRAY[STRING]*/T0* r257last(T257* C);
/*ARRAY[STRING]*/T6 r257is_empty(T257* C);
/*ARRAY[STRING]*/T0* r257item(T257* C,T2 a1);
/*ARRAY[STRING]*/void r257mark_native_arrays(T257* C);
/*ARRAY[STRING]*/void r257ensure_capacity_and_bounds(T257* C,T2 a1,T2 a2,T2 a3);
/*FAST_ARRAY[IVY_CLIENT]*/void r249copy(T249* C,T0* a1);
/*FAST_ARRAY[IVY_CLIENT]*/void r249remove(T249* C,T2 a1);
/*FAST_ARRAY[IVY_CLIENT]*/void r249make(T249* C,T2 a1);
/*FAST_ARRAY[IVY_CLIENT]*/void r249add_last(T249* C,T0* a1);
/*FAST_ARRAY[IVY_CLIENT]*/void r249mark_native_arrays(T249* C);
/*FAST_ARRAY[IVY_CLIENT]*/T2 r249fast_index_of(T249* C,T0* a1,T2 a2);
/*FAST_ARRAY[LOOP_ITEM]*/void r248remove_last(T248* C);
/*FAST_ARRAY[LOOP_ITEM]*/void r248make(T248* C,T2 a1);
/*FAST_ARRAY[LOOP_ITEM]*/void r248add_last(T248* C,T0* a1);
/*FAST_ARRAY[LOOP_ITEM]*/T0* r248last(T248* C);
/*FAST_ARRAY[LOOP_ITEM]*/T6 r248is_empty(T248* C);
/*FAST_ARRAY[LOOP_ITEM]*/void r248mark_native_arrays(T248* C);
/*FAST_ARRAY[X_INPUT_DEVICE]*/void r247make(T247* C,T2 a1);
/*FAST_ARRAY[X_INPUT_DEVICE]*/void r247mark_native_arrays(T247* C);
/*FAST_ARRAY[STRING]*/void r244make(T244* C,T2 a1);
/*FAST_ARRAY[STRING]*/void r244add_last(T244* C,T0* a1);
/*FAST_ARRAY[STRING]*/void r244with_capacity(T244* C,T2 a1);
/*FAST_ARRAY[STRING]*/void r244mark_native_arrays(T244* C);
/*WEAK_REFERENCE[HASHED_DICTIONARY_NODE[SENSITIVE,POINTER]]*/void r329set_item(T329* C,T0* a1);
/*HASHED_DICTIONARY_NODE[SENSITIVE,POINTER]*/void r327make(T327* C,T0* a1,T8 a2,T0* a3);
/*WEAK_REFERENCE[HASHED_DICTIONARY_NODE[SIGNAL_0,SENSITIVE]]*/void r326set_item(T326* C,T0* a1);
/*WEAK_REFERENCE[HASHED_DICTIONARY_NODE[SIGNAL_2[INTEGER_32,INTEGER_32],SENSITIVE]]*/void r317set_item(T317* C,T0* a1);
/*WEAK_REFERENCE[HASHED_DICTIONARY_NODE[SIGNAL_4[INTEGER_32,INTEGER_32,INTEGER_32,INTEGER_32],SENSITIVE]]*/void r311set_item(T311* C,T0* a1);
/*WEAK_REFERENCE[HASHED_DICTIONARY_NODE[EXTENSION_DEVICE,INTEGER_32]]*/void r308set_item(T308* C,T0* a1);
/*HASHED_DICTIONARY_NODE[EXTENSION_DEVICE,INTEGER_32]*/void r307make(T307* C,T0* a1,T2 a2,T0* a3);
/*WEAK_REFERENCE[HASHED_DICTIONARY_NODE[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]]*/void r302set_item(T302* C,T0* a1);
/*HASHED_DICTIONARY_NODE[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/void r300make(T300* C,T0* a1,T0* a2,T0* a3);
/*WEAK_REFERENCE[HASHED_DICTIONARY_NODE[INTEGER_32,INTEGER_32]]*/void r297set_item(T297* C,T0* a1);
/*HASHED_DICTIONARY_NODE[INTEGER_32,INTEGER_32]*/void r296make(T296* C,T2 a1,T2 a2,T0* a3);
/*WEAK_REFERENCE[HASHED_DICTIONARY_NODE[POINTER,STRING]]*/void r293set_item(T293* C,T0* a1);
/*HASHED_DICTIONARY_NODE[POINTER,STRING]*/void r292make(T292* C,T8 a1,T0* a2,T0* a3);
/*HASHED_DICTIONARY_NODE[WEAK_REFERENCE[ANY_HASHED_DICTIONARY_NODE],STRING]*/void r290make(T290* C,T0* a1,T0* a2,T0* a3);
/*WEAK_REFERENCE[HASHED_DICTIONARY_NODE[WEAK_REFERENCE[ANY_HASHED_DICTIONARY_NODE],STRING]]*/void r289set_item(T289* C,T0* a1);
/*HASHED_DICTIONARY[WEAK_REFERENCE[ANY_HASHED_DICTIONARY_NODE],STRING]*/T0* r288fast_reference_at(T288* C,T0* a1);
/*HASHED_DICTIONARY[WEAK_REFERENCE[ANY_HASHED_DICTIONARY_NODE],STRING]*/T2 r288prime_capacity(T2 a1);
/*HASHED_DICTIONARY[WEAK_REFERENCE[ANY_HASHED_DICTIONARY_NODE],STRING]*/T2 r288prime_number_ceiling(T2 a1);
/*HASHED_DICTIONARY[WEAK_REFERENCE[ANY_HASHED_DICTIONARY_NODE],STRING]*/T6 r288should_increase_capacity(T2 a1,T2 a2);
/*HASHED_DICTIONARY[WEAK_REFERENCE[ANY_HASHED_DICTIONARY_NODE],STRING]*/T0* r288new_node(T288* C,T0* a1,T0* a2,T0* a3);
/*HASHED_DICTIONARY[WEAK_REFERENCE[ANY_HASHED_DICTIONARY_NODE],STRING]*/void r288special_common_dictionary(T288* C,T0* a1);
/*HASHED_DICTIONARY[WEAK_REFERENCE[ANY_HASHED_DICTIONARY_NODE],STRING]*/void r288increase_capacity(T288* C);
/*HASHED_DICTIONARY[WEAK_REFERENCE[ANY_HASHED_DICTIONARY_NODE],STRING]*/void r288add(T288* C,T0* a1,T0* a2);
/*WEAK_REFERENCE[HASHED_DICTIONARY_NODE[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]]*/void r287set_item(T287* C,T0* a1);
/*HASHED_DICTIONARY_NODE[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]*/void r284make(T284* C,T0* a1,T0* a2,T0* a3);
/*HASHED_DICTIONARY[SENSITIVE,POINTER]*/T0* r276reference_at(T276* C,T8 a1);
/*HASHED_DICTIONARY[SENSITIVE,POINTER]*/void r276make(T276* C);
/*HASHED_DICTIONARY[SENSITIVE,POINTER]*/T6 r276key_safe_equal(T8 a1,T8 a2);
/*HASHED_DICTIONARY[SENSITIVE,POINTER]*/T2 r276prime_capacity(T2 a1);
/*HASHED_DICTIONARY[SENSITIVE,POINTER]*/T2 r276prime_number_ceiling(T2 a1);
/*HASHED_DICTIONARY[SENSITIVE,POINTER]*/T6 r276should_increase_capacity(T2 a1,T2 a2);
extern T0*oBC143common_free_nodes;
extern int fBC143common_free_nodes;
/*HASHED_DICTIONARY[SENSITIVE,POINTER]*/T0* r276common_free_nodes(void);
/*HASHED_DICTIONARY[SENSITIVE,POINTER]*/T0* r276new_node(T276* C,T0* a1,T8 a2,T0* a3);
/*HASHED_DICTIONARY[SENSITIVE,POINTER]*/void r276create_with_capacity(T276* C,T2 a1);
/*HASHED_DICTIONARY[SENSITIVE,POINTER]*/void r276increase_capacity(T276* C);
/*HASHED_DICTIONARY[SENSITIVE,POINTER]*/void r276add(T276* C,T0* a1,T8 a2);
/*HASHED_DICTIONARY[SIGNAL_0,SENSITIVE]*/T0* r275reference_at(T275* C,T0* a1);
/*HASHED_DICTIONARY[SIGNAL_0,SENSITIVE]*/void r275make(T275* C);
/*HASHED_DICTIONARY[SIGNAL_0,SENSITIVE]*/T0* r275common_free_nodes(void);
/*HASHED_DICTIONARY[SIGNAL_0,SENSITIVE]*/void r275create_with_capacity(T275* C,T2 a1);
/*HASHED_DICTIONARY[SIGNAL_2[INTEGER_32,INTEGER_32],SENSITIVE]*/T0* r271reference_at(T271* C,T0* a1);
/*HASHED_DICTIONARY[SIGNAL_2[INTEGER_32,INTEGER_32],SENSITIVE]*/void r271make(T271* C);
/*HASHED_DICTIONARY[SIGNAL_2[INTEGER_32,INTEGER_32],SENSITIVE]*/T0* r271common_free_nodes(void);
/*HASHED_DICTIONARY[SIGNAL_2[INTEGER_32,INTEGER_32],SENSITIVE]*/void r271create_with_capacity(T271* C,T2 a1);
/*HASHED_DICTIONARY[SIGNAL_4[INTEGER_32,INTEGER_32,INTEGER_32,INTEGER_32],SENSITIVE]*/T0* r269reference_at(T269* C,T0* a1);
/*HASHED_DICTIONARY[SIGNAL_4[INTEGER_32,INTEGER_32,INTEGER_32,INTEGER_32],SENSITIVE]*/void r269make(T269* C);
/*HASHED_DICTIONARY[SIGNAL_4[INTEGER_32,INTEGER_32,INTEGER_32,INTEGER_32],SENSITIVE]*/T0* r269common_free_nodes(void);
/*HASHED_DICTIONARY[SIGNAL_4[INTEGER_32,INTEGER_32,INTEGER_32,INTEGER_32],SENSITIVE]*/void r269create_with_capacity(T269* C,T2 a1);
/*HASHED_DICTIONARY[EXTENSION_DEVICE,INTEGER_32]*/void r268put(T268* C,T0* a1,T2 a2);
/*HASHED_DICTIONARY[EXTENSION_DEVICE,INTEGER_32]*/T0* r268reference_at(T268* C,T2 a1);
/*HASHED_DICTIONARY[EXTENSION_DEVICE,INTEGER_32]*/void r268make(T268* C);
/*HASHED_DICTIONARY[EXTENSION_DEVICE,INTEGER_32]*/T6 r268key_safe_equal(T2 a1,T2 a2);
/*HASHED_DICTIONARY[EXTENSION_DEVICE,INTEGER_32]*/T2 r268prime_capacity(T2 a1);
/*HASHED_DICTIONARY[EXTENSION_DEVICE,INTEGER_32]*/T2 r268prime_number_ceiling(T2 a1);
/*HASHED_DICTIONARY[EXTENSION_DEVICE,INTEGER_32]*/T6 r268should_increase_capacity(T2 a1,T2 a2);
/*HASHED_DICTIONARY[EXTENSION_DEVICE,INTEGER_32]*/T0* r268common_free_nodes(void);
/*HASHED_DICTIONARY[EXTENSION_DEVICE,INTEGER_32]*/T0* r268new_node(T268* C,T0* a1,T2 a2,T0* a3);
/*HASHED_DICTIONARY[EXTENSION_DEVICE,INTEGER_32]*/void r268create_with_capacity(T268* C,T2 a1);
/*HASHED_DICTIONARY[EXTENSION_DEVICE,INTEGER_32]*/void r268increase_capacity(T268* C);
/*HASHED_DICTIONARY[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/void r263make(T263* C);
/*HASHED_DICTIONARY[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/T0* r263reference_at(T263* C,T0* a1);
/*HASHED_DICTIONARY[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/T6 r263key_safe_equal(T0* a1,T0* a2);
/*HASHED_DICTIONARY[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/T2 r263prime_capacity(T2 a1);
/*HASHED_DICTIONARY[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/T2 r263prime_number_ceiling(T2 a1);
/*HASHED_DICTIONARY[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/T6 r263should_increase_capacity(T2 a1,T2 a2);
/*HASHED_DICTIONARY[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/T0* r263common_free_nodes(void);
/*HASHED_DICTIONARY[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/T0* r263new_node(T263* C,T0* a1,T0* a2,T0* a3);
/*HASHED_DICTIONARY[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/void r263create_with_capacity(T263* C,T2 a1);
/*HASHED_DICTIONARY[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/void r263increase_capacity(T263* C);
/*HASHED_DICTIONARY[FAST_ARRAY[SIGNAL_1[X_INPUT_DEVICE]],SENSITIVE]*/void r263add(T263* C,T0* a1,T0* a2);
/*SIGNAL_1[X_INPUT_DEVICE]*/void r261emit(T261* C,T0* a1);
/*SIGNAL_1[X_INPUT_DEVICE]*/void r261make(T261* C);
/*HASHED_DICTIONARY[INTEGER_32,INTEGER_32]*/void r260put(T260* C,T2 a1,T2 a2);
/*HASHED_DICTIONARY[INTEGER_32,INTEGER_32]*/T2 r260at(T260* C,T2 a1);
/*HASHED_DICTIONARY[INTEGER_32,INTEGER_32]*/void r260make(T260* C);
/*HASHED_DICTIONARY[INTEGER_32,INTEGER_32]*/T6 r260key_safe_equal(T2 a1,T2 a2);
/*HASHED_DICTIONARY[INTEGER_32,INTEGER_32]*/T2 r260prime_capacity(T2 a1);
/*HASHED_DICTIONARY[INTEGER_32,INTEGER_32]*/T2 r260prime_number_ceiling(T2 a1);
/*HASHED_DICTIONARY[INTEGER_32,INTEGER_32]*/T6 r260should_increase_capacity(T2 a1,T2 a2);
/*HASHED_DICTIONARY[INTEGER_32,INTEGER_32]*/T0* r260common_free_nodes(void);
/*HASHED_DICTIONARY[INTEGER_32,INTEGER_32]*/T0* r260new_node(T260* C,T2 a1,T2 a2,T0* a3);
/*HASHED_DICTIONARY[INTEGER_32,INTEGER_32]*/void r260create_with_capacity(T260* C,T2 a1);
/*HASHED_DICTIONARY[INTEGER_32,INTEGER_32]*/void r260increase_capacity(T260* C);
/*RING_ARRAY[INTEGER_32]*/void r256move(T256* C,T2 a1,T2 a2,T2 a3);
/*RING_ARRAY[INTEGER_32]*/void r256remove_first(T256* C);
/*RING_ARRAY[INTEGER_32]*/T2 r256wrap_point(T256* C);
/*RING_ARRAY[INTEGER_32]*/void r256make_space_for_one(T256* C);
/*RING_ARRAY[INTEGER_32]*/void r256squeeze_bubble(T256* C,T2 a1,T2 a2,T2 a3,T2 a4);
/*RING_ARRAY[INTEGER_32]*/T2 r256storage_upper(T256* C);
/*RING_ARRAY[INTEGER_32]*/void r256put(T256* C,T2 a1,T2 a2);
/*RING_ARRAY[INTEGER_32]*/T2 r256storage_index(T256* C,T2 a1);
/*RING_ARRAY[INTEGER_32]*/void r256clear_all(T256* C);
/*RING_ARRAY[INTEGER_32]*/void r256set_all_with(T256* C,T2 a1);
/*RING_ARRAY[INTEGER_32]*/void r256make(T256* C,T2 a1,T2 a2);
/*RING_ARRAY[INTEGER_32]*/void r256add_last(T256* C,T2 a1);
/*RING_ARRAY[INTEGER_32]*/T2 r256count(T256* C);
/*RING_ARRAY[INTEGER_32]*/T6 r256is_empty(T256* C);
/*RING_ARRAY[INTEGER_32]*/T2 r256item(T256* C,T2 a1);
/*HASHED_DICTIONARY[POINTER,STRING]*/void r253make(T253* C);
/*HASHED_DICTIONARY[POINTER,STRING]*/T2 r253prime_capacity(T2 a1);
/*HASHED_DICTIONARY[POINTER,STRING]*/T2 r253prime_number_ceiling(T2 a1);
/*HASHED_DICTIONARY[POINTER,STRING]*/T6 r253should_increase_capacity(T2 a1,T2 a2);
/*HASHED_DICTIONARY[POINTER,STRING]*/T0* r253common_free_nodes(void);
/*HASHED_DICTIONARY[POINTER,STRING]*/T0* r253new_node(T253* C,T8 a1,T0* a2,T0* a3);
/*HASHED_DICTIONARY[POINTER,STRING]*/void r253create_with_capacity(T253* C,T2 a1);
/*HASHED_DICTIONARY[POINTER,STRING]*/void r253increase_capacity(T253* C);
/*HASHED_DICTIONARY[POINTER,STRING]*/void r253add(T253* C,T8 a1,T0* a2);
/*HASHED_DICTIONARY[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]*/void r250make(T250* C);
/*HASHED_DICTIONARY[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]*/T2 r250prime_capacity(T2 a1);
/*HASHED_DICTIONARY[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]*/T2 r250prime_number_ceiling(T2 a1);
/*HASHED_DICTIONARY[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]*/T6 r250should_increase_capacity(T2 a1,T2 a2);
/*HASHED_DICTIONARY[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]*/T0* r250common_free_nodes(void);
/*HASHED_DICTIONARY[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]*/T0* r250new_node(T250* C,T0* a1,T0* a2,T0* a3);
/*HASHED_DICTIONARY[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]*/void r250create_with_capacity(T250* C,T2 a1);
/*HASHED_DICTIONARY[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]*/void r250increase_capacity(T250* C);
/*HASHED_DICTIONARY[PROCEDURE[TUPLE[FAST_ARRAY[STRING]]],STRING]*/void r250add(T250* C,T0* a1,T0* a2);
/*STREAM_EXCEPTION*/void r113make(T113* C,T0* a1);
/*STREAM_EXCEPTION*/void r113expect(T113* C,T0* a1);
/*STREAM_EXCEPTION*/T6 r113occurred(T113* C,T0* a1);
/*CAN_READ_DATA_FROM_STREAM*/void r123make(T123* C,T0* a1);
/*CAN_READ_DATA_FROM_STREAM*/void r123expect(T123* C,T0* a1);
/*CAN_READ_DATA_FROM_STREAM*/T6 r123occurred(T123* C,T0* a1);
/*TIME*/T6 r205_ix_60(T205* C,T205 a1);
/*TIME*/T5 r205elapsed_seconds(T205* C,T205 a1);
/*MICROSECOND_TIME*/T6 r192_ix_60(T192* C,T192 a1);
/*MICROSECOND_TIME*/T5 r192elapsed_seconds(T192* C,T192 a1);
/*MICROSECOND_TIME*/void r192update(T192* C);
/*EVENTS_SET*/T6 r154has_exception(T154* C,T2 a1);
/*EVENTS_SET*/void r154expect_readable(T154* C,T2 a1);
/*EVENTS_SET*/void r154when_data(T154* C,T0* a1);
/*EVENTS_SET*/T6 r154can_read(T154* C,T2 a1);
/*EVENTS_SET*/T6 r154is_data(T154* C,T0* a1);
/*EVENTS_SET*/void r154make(T154* C);
/*EVENTS_SET*/void r154when_exception(T154* C,T0* a1);
/*EVENTS_SET*/T6 r154event_occurred(T154* C,T0* a1);
/*EVENTS_SET*/T6 r154is_exception(T154* C,T0* a1);
/*EVENTS_SET*/void r154wait(T154* C);
/*EVENTS_SET*/void r154expect_exception(T154* C,T2 a1);
/*EVENTS_SET*/void r154reset(T154* C);
/*EVENTS_SET*/void r154expect(T154* C,T0* a1);
/*KEY_RANGE*/void r146make(T146* C,T8 a1);
/*BUTTON_RANGE*/void r149make(T149* C,T8 a1);
/*AXES_RANGE*/void r148make(T148* C,T8 a1);
/*IVY_CLIENT*/void r153process_incomming_data(T153* C);
/*IVY_CLIENT*/T0* r153event_can_read(T153* C);
/*IVY_CLIENT*/void r153make(T153* C,T2 a1,T8 a2,T8 a3,T8 a4,T8 a5);
/*IVY_CLIENT*/void r153disconnect(T153* C);
/*IVY_CLIENT*/void r153dispose(T153* C);
/*IVY_CLIENT*/T0* r153event_exception(T153* C);
T155*create155make(void);
/*LOOP_ITEM*/void r155make(T155* C);
/*LOOP_ITEM*/void r155add_job(T155* C,T0* a1);
/*LOOP_ITEM*/void r155run(T155* C);
/*ROOT_WINDOW*/void r73default_create(T73* C);
extern T0*oBC26vision;
extern int fBC26vision;
/*ROOT_WINDOW*/T0* r73vision(void);
/*ROOT_WINDOW*/T2 r73hash_code(T73* C);
/*ROOT_WINDOW*/void r73container_init(T73* C);
/*GRAPHIC_CONNECTION*/T0* r134event_can_read(T134* C);
/*GRAPHIC_CONNECTION*/void r134set_descriptor(T134* C,T2 a1);
/*VISION_LOOP_STACK*/void r133make(T133* C);
/*VISION_LOOP_STACK*/T0* r133current_loop(T133* C);
/*VISION_LOOP_STACK*/void r133run(T133* C);
/*VISION_LOOP_STACK*/void r133_P_132_make(T133* C);
/*EVENT_CATCHER*/T0* r131vision(void);
/*EVENT_CATCHER*/void r131make(T131* C,T0* a1);
/*EVENT_CATCHER*/void r131prepare(T131* C,T0* a1);
/*EVENT_CATCHER*/T6 r131is_ready(T131* C,T0* a1);
/*EVENT_CATCHER*/void r131continue(T131* C);
/*EVENT_CATCHER*/void r131add_extension(T131* C,T0* a1);
/*EVENT_CATCHER*/T0* r131search_widget(T131* C,T8 a1);
/*EVENT_CATCHER*/void r131emit_event(T131* C,T0* a1,T2 a2);
/*STD_OUTPUT*/void r53filtered_flush(T53* C);
/*STD_OUTPUT*/void r53filtered_put_character(T53* C,T3 a1);
extern T0*oBC13std_output;
extern int fBC13std_output;
/*STD_OUTPUT*/T0* r53std_output(void);
/*STD_OUTPUT*/void r53se_atexit(void);
/*STD_OUTPUT*/void r53make(T53* C);
/*STD_OUTPUT*/void r53write_buffer(T53* C);
/*STD_OUTPUT*/void r53flush(T53* C);
/*STD_OUTPUT*/void r53put_string(T53* C,T0* a1);
/*STD_OUTPUT*/void r53put_line(T53* C,T0* a1);
/*STD_INPUT_OUTPUT*/T0* r46std_output(void);
/*STD_INPUT_OUTPUT*/void r46put_string(T0* a1);
/*STD_INPUT_OUTPUT*/void r46put_line(T0* a1);
/*X_INPUT_EXTENSION*/void r191make(T191* C);
/*X11*/void r150default_create(void);
/*X11*/T0* r150vision(void);
extern T0*oBC150x_input_extension;
extern int fBC150x_input_extension;
/*X11*/T0* r150x_input_extension(void);
/*X11*/T6 r150has_x_input_extension(void);
/*X11*/T0* r150get_atom_name(T2 a1);
/*X_INPUT_DEVICE*/T0* r68vision(void);
/*X_INPUT_DEVICE*/void r68make(T68* C,T8 a1,T2 a2);
/*X_INPUT_DEVICE*/void r68handle_event(T68* C,T2 a1,T0* a2);
/*X_INPUT_DEVICE*/void r68when_proximity_out(T68* C,T0* a1,T0* a2);
/*X_INPUT_DEVICE*/void r68connect(T68* C);
/*X_INPUT_DEVICE*/void r68when_button_released(T68* C,T0* a1,T0* a2);
/*X_INPUT_DEVICE*/void r68when_event(T68* C,T2 a1,T0* a2,T0* a3);
/*X_INPUT_DEVICE*/void r68when_moved(T68* C,T0* a1,T0* a2);
/*X_INPUT_DEVICE*/T2 r68proximity_axis_data(T2 a1);
/*X_INPUT_DEVICE*/void r68when_button_pressed(T68* C,T0* a1,T0* a2);
/*X_INPUT_DEVICE*/T2 r68motion_axis_data(T2 a1);
/*X_INPUT_DEVICE*/void r68when_proximity_in(T68* C,T0* a1,T0* a2);
/*STD_ERROR*/void r43put_string(T0* a1);
/*STD_ERROR*/void r43put_line(T0* a1);
typedef struct _se_agenT70f70l203c34 se_agenT70f70l203c34;
struct _se_agenT70f70l203c34{Tid id;
int creation_mold_id;
void(*afp)(se_agenT70f70l203c34*,T0*);
void(*gc_mark_agent_mold)(se_agenT70f70l203c34*);
int (*eq)(se_agent*,se_agent*);
T0* closed_C;};
/*agent creation*/T0*agenT70f70l203c34(T0* closed_C);
void gc_mark_agenT70f70l203c34(se_agenT70f70l203c34*u);
/*WACOM_POINTER*/void r70move(T70* C,T0* a1);
/*WACOM_POINTER*/void r70crop_identifier(T70* C,T0* a1);
/*WACOM_POINTER*/void r70set_message_header(T70* C,T0* a1);
/*WACOM_POINTER*/T6 r70is_valid_crop(T0* a1);
/*WACOM_POINTER*/void r70button(T70* C,T6 a1,T0* a2);
/*WACOM_POINTER*/void r70proximity(T70* C,T6 a1,T0* a2);
/*WACOM_POINTER*/T2 r70device_to_screen_y(T70* C,T2 a1);
/*WACOM_POINTER*/T2 r70device_to_screen_x(T70* C,T2 a1);
/*WACOM_POINTER*/T0* r70type_to_name(T2 a1);
extern T0*oBC13io;
/*WACOM_POINTER*/T0* r70twin(T70* C);
/*WACOM_POINTER*/T5 r70mean(T0* a1);
/*WACOM_POINTER*/void r70reconfigure_crop(T70* C,T0* a1);
/*WACOM_POINTER*/void r70set_crop(T70* C,T0* a1);
/*WACOM_POINTER*/void r70update_predicted_position(T70* C,T5 a1,T5 a2,T5 a3);
/*WACOM_POINTER*/void r70make(T70* C,T0* a1);
/*WACOM_POINTER*/void r70print_data_in(T70* C,T0* a1,T2 a2,T2 a3,T2 a4,T2 a5,T2 a6,T2 a7,T2 a8,T0* a9);
/*IVY*/void r71start(T71* C,T0* a1);
/*IVY*/void r71make(T71* C,T0* a1);
/*IVY*/void r71prepare(T71* C,T0* a1);
/*IVY*/T6 r71is_ready(T71* C,T0* a1);
/*IVY*/void r71continue(T71* C);
/*IVY*/void r71subscribe(T71* C,T0* a1,T0* a2);
/*IVY*/void r71channel_down(T71* C,T0* a1);
/*IVY*/void r71callback_runner(T0* a1,T2 a2,T254 a3);
/*IVY*/T0* r71channel_up(T71* C,T2 a1,T8 a2,T8 a3,T8 a4,T8 a5);
/*IVY*/void r71send_message(T71* C,T0* a1);
void* W71channel_up(void* C,T2 a1,T8 a2,T8 a3,T8 a4,T8 a5);
void W71channel_down(void* C,void* a1);
void W71callback_runner(void* C,void* a1,T2 a2,T254 a3);
/*VISION*/void r65start(T65* C);
/*VISION*/void r65register(T65* C,T0* a1);
/*VISION*/void r65graphic_init(T65* C);
extern T0*oBC65root_window;
extern int fBC65root_window;
/*VISION*/T0* r65root_window(void);
extern T0*oBC13std_error;
/*VISION*/void r65crash(T65* C);
/*VISION*/void r65not_yet_implemented(T65* C);
typedef struct _se_agenT25f25l227c40 se_agenT25f25l227c40;
struct _se_agenT25f25l227c40{Tid id;
int creation_mold_id;
void(*afp)(se_agenT25f25l227c40*,T0*);
void(*gc_mark_agent_mold)(se_agenT25f25l227c40*);
int (*eq)(se_agent*,se_agent*);
T0* closed_C;};
/*agent creation*/T0*agenT25f25l227c40(T0* closed_C);
void gc_mark_agenT25f25l227c40(se_agenT25f25l227c40*u);
typedef struct _se_agenT25f25l226c39 se_agenT25f25l226c39;
struct _se_agenT25f25l226c39{Tid id;
int creation_mold_id;
void(*afp)(se_agenT25f25l226c39*,T0*);
void(*gc_mark_agent_mold)(se_agenT25f25l226c39*);
int (*eq)(se_agent*,se_agent*);
T0* closed_C;};
/*agent creation*/T0*agenT25f25l226c39(T0* closed_C);
void gc_mark_agenT25f25l226c39(se_agenT25f25l226c39*u);
typedef struct _se_agenT25f25l225c42 se_agenT25f25l225c42;
struct _se_agenT25f25l225c42{Tid id;
int creation_mold_id;
void(*afp)(se_agenT25f25l225c42*,T0*);
void(*gc_mark_agent_mold)(se_agenT25f25l225c42*);
int (*eq)(se_agent*,se_agent*);
T0* closed_C;};
/*agent creation*/T0*agenT25f25l225c42(T0* closed_C);
void gc_mark_agenT25f25l225c42(se_agenT25f25l225c42*u);
typedef struct _se_agenT25f25l224c41 se_agenT25f25l224c41;
struct _se_agenT25f25l224c41{Tid id;
int creation_mold_id;
void(*afp)(se_agenT25f25l224c41*,T0*);
void(*gc_mark_agent_mold)(se_agenT25f25l224c41*);
int (*eq)(se_agent*,se_agent*);
T0* closed_C;};
/*agent creation*/T0*agenT25f25l224c41(T0* closed_C);
void gc_mark_agenT25f25l224c41(se_agenT25f25l224c41*u);
typedef struct _se_agenT25f25l223c32 se_agenT25f25l223c32;
struct _se_agenT25f25l223c32{Tid id;
int creation_mold_id;
void(*afp)(se_agenT25f25l223c32*,T0*);
void(*gc_mark_agent_mold)(se_agenT25f25l223c32*);
int (*eq)(se_agent*,se_agent*);
T0* closed_C;};
/*agent creation*/T0*agenT25f25l223c32(T0* closed_C);
void gc_mark_agenT25f25l223c32(se_agenT25f25l223c32*u);
typedef struct _se_agenT25f25l205c38 se_agenT25f25l205c38;
struct _se_agenT25f25l205c38{Tid id;
int creation_mold_id;
void(*afp)(se_agenT25f25l205c38*,T0*);
void(*gc_mark_agent_mold)(se_agenT25f25l205c38*);
int (*eq)(se_agent*,se_agent*);
T0* closed_C;T0* closed_a1;};
/*agent creation*/T0*agenT25f25l205c38(T0* closed_C,T0* closed_a1);
void gc_mark_agenT25f25l205c38(se_agenT25f25l205c38*u);
typedef struct _se_agenT25f25l204c37 se_agenT25f25l204c37;
struct _se_agenT25f25l204c37{Tid id;
int creation_mold_id;
void(*afp)(se_agenT25f25l204c37*,T0*);
void(*gc_mark_agent_mold)(se_agenT25f25l204c37*);
int (*eq)(se_agent*,se_agent*);
T0* closed_C;T0* closed_a1;};
/*agent creation*/T0*agenT25f25l204c37(T0* closed_C,T0* closed_a1);
void gc_mark_agenT25f25l204c37(se_agenT25f25l204c37*u);
typedef struct _se_agenT25f25l199c36 se_agenT25f25l199c36;
struct _se_agenT25f25l199c36{Tid id;
int creation_mold_id;
void(*afp)(se_agenT25f25l199c36*,T0*);
void(*gc_mark_agent_mold)(se_agenT25f25l199c36*);
int (*eq)(se_agent*,se_agent*);
T0* closed_C;T0* closed_a1;};
/*agent creation*/T0*agenT25f25l199c36(T0* closed_C,T0* closed_a1);
void gc_mark_agenT25f25l199c36(se_agenT25f25l199c36*u);
typedef struct _se_agenT25f25l198c28 se_agenT25f25l198c28;
struct _se_agenT25f25l198c28{Tid id;
int creation_mold_id;
void(*afp)(se_agenT25f25l198c28*,T0*);
void(*gc_mark_agent_mold)(se_agenT25f25l198c28*);
int (*eq)(se_agent*,se_agent*);
T0* closed_C;T0* closed_a1;};
/*agent creation*/T0*agenT25f25l198c28(T0* closed_C,T0* closed_a1);
void gc_mark_agenT25f25l198c28(se_agenT25f25l198c28*u);
/*XINPUT_IVY*/T0* r25std_output(void);
/*XINPUT_IVY*/T0* r25vision(void);
/*XINPUT_IVY*/T6 r25decode_options(T25* C);
/*XINPUT_IVY*/void r25list_devices(T25* C);
/*XINPUT_IVY*/void r25print_help(void);
/*XINPUT_IVY*/T6 r25init_pad(T25* C,T0* a1);
/*XINPUT_IVY*/void r25decode_application_name_option(T25* C);
/*XINPUT_IVY*/void r25left_slider_out(T25* C,T0* a1,T0* a2);
/*XINPUT_IVY*/void r25pad_button_pressed(T25* C,T0* a1,T0* a2);
/*XINPUT_IVY*/T2 r25argument_count(void);
/*XINPUT_IVY*/void r25pad_button_released(T25* C,T0* a1,T0* a2);
/*XINPUT_IVY*/void r25make(T25* C);
/*XINPUT_IVY*/T0* r25subscribe_input(T25* C,T0* a1);
/*XINPUT_IVY*/T6 r25init_wacom_pointer(T25* C,T0* a1,T0* a2);
extern T0*oBC30command_arguments;
extern int fBC30command_arguments;
/*XINPUT_IVY*/T0* r25command_arguments(void);
/*XINPUT_IVY*/void r25slider_event(T25* C,T0* a1,T0* a2);
void agent_launcher_FAST_ARRAY__STRING__(/*agent*/T0*a,T0* a1);
void agent_launcher_X_INPUT_DEVICE(/*agent*/T0*a,T0* a1);
union _se_agent{T0 s0;se_agent0 u0;
se_agenT25f25l198c28 uagenT25f25l198c28;
se_agenT25f25l199c36 uagenT25f25l199c36;
se_agenT25f25l204c37 uagenT25f25l204c37;
se_agenT25f25l205c38 uagenT25f25l205c38;
se_agenT25f25l223c32 uagenT25f25l223c32;
se_agenT25f25l224c41 uagenT25f25l224c41;
se_agenT25f25l225c42 uagenT25f25l225c42;
se_agenT25f25l226c39 uagenT25f25l226c39;
se_agenT25f25l227c40 uagenT25f25l227c40;
se_agenT70f70l203c34 uagenT70f70l203c34;
};
/*
-- ------------------------------------------------------------------------------------------------------------
-- Copyright notice below. Please read.
--
-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
-- Copyright(C) 2003-2005: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
--
-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
--
-- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
-- documentation files (the "Software"), to deal in the Software without restriction, including without
-- limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
-- the Software, and to permit persons to whom the Software is furnished to do so, subject to the following
-- conditions:
--
-- The above copyright notice and this permission notice shall be included in all copies or substantial
-- portions of the Software.
--
-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
-- LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
-- EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-- AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
-- OR OTHER DEALINGS IN THE SOFTWARE.
--
-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
-- ------------------------------------------------------------------------------------------------------------
*/
#define SE_AGENTS 1
#define EIF_AGENT se_agent*

se_agent* new_agent(Tid id);

#ifdef SE_GC_LIB

  typedef struct B_agent gc_agent;

  struct B_agent {
    se_agent object;
    union {
      void *flag;
      gc_agent *next;
    } header;
  };

  extern gc_agent *store_agent;
  extern gc_agent *gc_free_agent;
  extern int       store_left_agent;
  extern fsoc     *store_chunk_agent;
  extern fsoc      H_agent;
  extern int       gc_info_nb_agent;

  void gc_align_mark_agent(fsoc *c, gc_agent* a);
  void gc_sweep_agent(fsoc *c);

#endif
extern T0*ms25_0bc70c15;
extern T0*ms25_0bc70c11;
extern T0*ms70_952626;
extern T0*ms70_15980;
extern T0*ms25_0bc25c15l400;
extern T0*ms25_92383297;
extern T0*ms25_0bc70c15l97;
extern T0*ms70_1874520032;
extern T0*ms70_22702416;
extern T0*ms70_22702411;
extern T0*ms25_0bc25;
extern T0*ms25_0bc70;
extern T0*ms70_2097616536;
extern T0*ms70_2057747851;
extern T0*ms25_1403610646;
extern T0*ms70_1257860908;
extern T0*ms70_190991;
extern T0*ms70_586741066;
extern T0*ms25_0;
extern T0*ms70_188916;
extern T0*ms25_1959886733;
extern T0*ms25_0bc25c15;
extern T0*ms70_112207026;
extern T0*ms25_3479972;
extern T0*ms70_2112369621;
extern T0*ms25_21190322;
extern T0*ms70_10739030;
extern T0*ms70_10739024;
extern T0*ms70_10739017;
extern T0*ms25_314746909;
extern T0*ms70_1961093439;
extern T0*ms25_1638797568;
extern T0*ms70_220157120;
extern T0*ms70_1699147265;
extern T0*ms70_475;
extern T0*ms70_697;
extern T0*ms25_4487261bc70;
extern T0*ms25_694149733;
extern T0*ms70_1619665677;
extern T0*ms70_1756148648;
extern T0*ms70_1756148653;
extern T0*ms150_1472358418;
extern T0*ms70_4738061;
extern T0*ms70_23436791;
extern T0*ms25_557679246;
extern T0*ms70_1940108584;
extern T0*ms70_1461;
extern T0*ms70_1466;
extern T0*ms70_2676;
extern T0*ms70_4725666;
extern T0*ms70_4725661;
extern T0*ms25_4487261;
extern T0*ms70_1501987274;
extern T0*ms70_104371129;
extern T0*ms25_1403610646bc25;
extern T0*ms70_104371267;
extern T0*ms70_56246305bc70;
extern T0*ms70_56246305;
extern T0*ms25_946366;
extern T0*ms25_0bc70c15l379;
T0*se_ms(int c,char*e);
T0*se_string(char*e);
void se_msi1(void);
void se_msi2(void);
void manifest_string_mark1(void);
void once_function_mark(void);
void gc_start(void);
typedef struct B113 gc113;
struct B113{T113 object;union {void*flag;gc113*next;} header;};
extern gc113*store113;
extern int store_left113;
extern fsoc*store_chunk113;
extern gc113*gc_free113;
typedef struct B123 gc123;
struct B123{T123 object;union {void*flag;gc123*next;} header;};
extern gc123*store123;
extern int store_left123;
extern fsoc*store_chunk123;
extern gc123*gc_free123;
extern na_env na_env337;
extern na_env na_env336;
extern na_env na_env335;
extern na_env na_env334;
extern na_env na_env333;
extern na_env na_env332;
extern na_env na_env331;
extern na_env na_env330;
typedef struct B329 gc329;
struct B329{T329 object;union {void*flag;gc329*next;} header;};
extern gc329*store329;
extern int store_left329;
extern fsoc*store_chunk329;
extern gc329*gc_free329;
extern na_env na_env328;
typedef struct B327 gc327;
struct B327{T327 object;union {void*flag;gc327*next;} header;};
extern gc327*store327;
extern int store_left327;
extern fsoc*store_chunk327;
extern gc327*gc_free327;
typedef struct B326 gc326;
struct B326{T326 object;union {void*flag;gc326*next;} header;};
extern gc326*store326;
extern int store_left326;
extern fsoc*store_chunk326;
extern gc326*gc_free326;
extern na_env na_env324;
extern na_env na_env321;
typedef struct B317 gc317;
struct B317{T317 object;union {void*flag;gc317*next;} header;};
extern gc317*store317;
extern int store_left317;
extern fsoc*store_chunk317;
extern gc317*gc_free317;
extern na_env na_env316;
typedef struct B311 gc311;
struct B311{T311 object;union {void*flag;gc311*next;} header;};
extern gc311*store311;
extern int store_left311;
extern fsoc*store_chunk311;
extern gc311*gc_free311;
extern na_env na_env310;
typedef struct B308 gc308;
struct B308{T308 object;union {void*flag;gc308*next;} header;};
extern gc308*store308;
extern int store_left308;
extern fsoc*store_chunk308;
extern gc308*gc_free308;
typedef struct B307 gc307;
struct B307{T307 object;union {void*flag;gc307*next;} header;};
extern gc307*store307;
extern int store_left307;
extern fsoc*store_chunk307;
extern gc307*gc_free307;
extern na_env na_env306;
extern na_env na_env305;
extern na_env na_env304;
extern na_env na_env303;
typedef struct B302 gc302;
struct B302{T302 object;union {void*flag;gc302*next;} header;};
extern gc302*store302;
extern int store_left302;
extern fsoc*store_chunk302;
extern gc302*gc_free302;
extern na_env na_env301;
typedef struct B300 gc300;
struct B300{T300 object;union {void*flag;gc300*next;} header;};
extern gc300*store300;
extern int store_left300;
extern fsoc*store_chunk300;
extern gc300*gc_free300;
extern na_env na_env299;
typedef struct B298 gc298;
struct B298{T298 object;union {void*flag;gc298*next;} header;};
extern gc298*store298;
extern int store_left298;
extern fsoc*store_chunk298;
extern gc298*gc_free298;
typedef struct B297 gc297;
struct B297{T297 object;union {void*flag;gc297*next;} header;};
extern gc297*store297;
extern int store_left297;
extern fsoc*store_chunk297;
extern gc297*gc_free297;
typedef struct B296 gc296;
struct B296{T296 object;union {void*flag;gc296*next;} header;};
extern gc296*store296;
extern int store_left296;
extern fsoc*store_chunk296;
extern gc296*gc_free296;
extern na_env na_env295;
extern na_env na_env294;
typedef struct B293 gc293;
struct B293{T293 object;union {void*flag;gc293*next;} header;};
extern gc293*store293;
extern int store_left293;
extern fsoc*store_chunk293;
extern gc293*gc_free293;
typedef struct B292 gc292;
struct B292{T292 object;union {void*flag;gc292*next;} header;};
extern gc292*store292;
extern int store_left292;
extern fsoc*store_chunk292;
extern gc292*gc_free292;
extern na_env na_env291;
typedef struct B290 gc290;
struct B290{T290 object;union {void*flag;gc290*next;} header;};
extern gc290*store290;
extern int store_left290;
extern fsoc*store_chunk290;
extern gc290*gc_free290;
typedef struct B289 gc289;
struct B289{T289 object;union {void*flag;gc289*next;} header;};
extern gc289*store289;
extern int store_left289;
extern fsoc*store_chunk289;
extern gc289*gc_free289;
typedef struct B288 gc288;
struct B288{T288 object;union {void*flag;gc288*next;} header;};
extern gc288*store288;
extern int store_left288;
extern fsoc*store_chunk288;
extern gc288*gc_free288;
typedef struct B287 gc287;
struct B287{T287 object;union {void*flag;gc287*next;} header;};
extern gc287*store287;
extern int store_left287;
extern fsoc*store_chunk287;
extern gc287*gc_free287;
typedef struct B284 gc284;
struct B284{T284 object;union {void*flag;gc284*next;} header;};
extern gc284*store284;
extern int store_left284;
extern fsoc*store_chunk284;
extern gc284*gc_free284;
extern na_env na_env283;
extern na_env na_env282;
extern na_env na_env281;
typedef struct B280 gc280;
struct B280{T280 object;union {void*flag;gc280*next;} header;};
extern gc280*store280;
extern int store_left280;
extern fsoc*store_chunk280;
extern gc280*gc_free280;
typedef struct B154 gc154;
struct B154{T154 object;union {void*flag;gc154*next;} header;};
extern gc154*store154;
extern int store_left154;
extern fsoc*store_chunk154;
extern gc154*gc_free154;
typedef struct B279 gc279;
struct B279{T279 object;union {void*flag;gc279*next;} header;};
extern gc279*store279;
extern int store_left279;
extern fsoc*store_chunk279;
extern gc279*gc_free279;
typedef struct B160 gc160;
struct B160{T160 object;union {void*flag;gc160*next;} header;};
extern gc160*store160;
extern int store_left160;
extern fsoc*store_chunk160;
extern gc160*gc_free160;
typedef struct B277 gc277;
struct B277{T277 object;union {void*flag;gc277*next;} header;};
extern gc277*store277;
extern int store_left277;
extern fsoc*store_chunk277;
extern gc277*gc_free277;
typedef struct B276 gc276;
struct B276{T276 object;union {void*flag;gc276*next;} header;};
extern gc276*store276;
extern int store_left276;
extern fsoc*store_chunk276;
extern gc276*gc_free276;
typedef struct B275 gc275;
struct B275{T275 object;union {void*flag;gc275*next;} header;};
extern gc275*store275;
extern int store_left275;
extern fsoc*store_chunk275;
extern gc275*gc_free275;
typedef struct B273 gc273;
struct B273{T273 object;union {void*flag;gc273*next;} header;};
extern gc273*store273;
extern int store_left273;
extern fsoc*store_chunk273;
extern gc273*gc_free273;
typedef struct B271 gc271;
struct B271{T271 object;union {void*flag;gc271*next;} header;};
extern gc271*store271;
extern int store_left271;
extern fsoc*store_chunk271;
extern gc271*gc_free271;
typedef struct B269 gc269;
struct B269{T269 object;union {void*flag;gc269*next;} header;};
extern gc269*store269;
extern int store_left269;
extern fsoc*store_chunk269;
extern gc269*gc_free269;
typedef struct B268 gc268;
struct B268{T268 object;union {void*flag;gc268*next;} header;};
extern gc268*store268;
extern int store_left268;
extern fsoc*store_chunk268;
extern gc268*gc_free268;
typedef struct B146 gc146;
struct B146{T146 object;union {void*flag;gc146*next;} header;};
extern gc146*store146;
extern int store_left146;
extern fsoc*store_chunk146;
extern gc146*gc_free146;
typedef struct B267 gc267;
struct B267{T267 object;union {void*flag;gc267*next;} header;};
extern gc267*store267;
extern int store_left267;
extern fsoc*store_chunk267;
extern gc267*gc_free267;
typedef struct B149 gc149;
struct B149{T149 object;union {void*flag;gc149*next;} header;};
extern gc149*store149;
extern int store_left149;
extern fsoc*store_chunk149;
extern gc149*gc_free149;
typedef struct B266 gc266;
struct B266{T266 object;union {void*flag;gc266*next;} header;};
extern gc266*store266;
extern int store_left266;
extern fsoc*store_chunk266;
extern gc266*gc_free266;
typedef struct B148 gc148;
struct B148{T148 object;union {void*flag;gc148*next;} header;};
extern gc148*store148;
extern int store_left148;
extern fsoc*store_chunk148;
extern gc148*gc_free148;
typedef struct B265 gc265;
struct B265{T265 object;union {void*flag;gc265*next;} header;};
extern gc265*store265;
extern int store_left265;
extern fsoc*store_chunk265;
extern gc265*gc_free265;
extern na_env na_env264;
typedef struct B263 gc263;
struct B263{T263 object;union {void*flag;gc263*next;} header;};
extern gc263*store263;
extern int store_left263;
extern fsoc*store_chunk263;
extern gc263*gc_free263;
typedef struct B262 gc262;
struct B262{T262 object;union {void*flag;gc262*next;} header;};
extern gc262*store262;
extern int store_left262;
extern fsoc*store_chunk262;
extern gc262*gc_free262;
typedef struct B261 gc261;
struct B261{T261 object;union {void*flag;gc261*next;} header;};
extern gc261*store261;
extern int store_left261;
extern fsoc*store_chunk261;
extern gc261*gc_free261;
typedef struct B260 gc260;
struct B260{T260 object;union {void*flag;gc260*next;} header;};
extern gc260*store260;
extern int store_left260;
extern fsoc*store_chunk260;
extern gc260*gc_free260;
typedef struct B259 gc259;
struct B259{T259 object;union {void*flag;gc259*next;} header;};
extern gc259*store259;
extern int store_left259;
extern fsoc*store_chunk259;
extern gc259*gc_free259;
typedef struct B257 gc257;
struct B257{T257 object;union {void*flag;gc257*next;} header;};
extern gc257*store257;
extern int store_left257;
extern fsoc*store_chunk257;
extern gc257*gc_free257;
typedef struct B256 gc256;
struct B256{T256 object;union {void*flag;gc256*next;} header;};
extern gc256*store256;
extern int store_left256;
extern fsoc*store_chunk256;
extern gc256*gc_free256;
extern na_env na_env255;
extern na_env na_env254;
typedef struct B253 gc253;
struct B253{T253 object;union {void*flag;gc253*next;} header;};
extern gc253*store253;
extern int store_left253;
extern fsoc*store_chunk253;
extern gc253*gc_free253;

#define gc_mark251(x) (((se_agent0*)(x))->gc_mark_agent_mold((se_agent*)(x)))

typedef struct B250 gc250;
struct B250{T250 object;union {void*flag;gc250*next;} header;};
extern gc250*store250;
extern int store_left250;
extern fsoc*store_chunk250;
extern gc250*gc_free250;
typedef struct B153 gc153;
struct B153{T153 object;union {void*flag;gc153*next;} header;};
extern gc153*store153;
extern int store_left153;
extern fsoc*store_chunk153;
extern gc153*gc_free153;
typedef struct B249 gc249;
struct B249{T249 object;union {void*flag;gc249*next;} header;};
extern gc249*store249;
extern int store_left249;
extern fsoc*store_chunk249;
extern gc249*gc_free249;
typedef struct B248 gc248;
struct B248{T248 object;union {void*flag;gc248*next;} header;};
extern gc248*store248;
extern int store_left248;
extern fsoc*store_chunk248;
extern gc248*gc_free248;
typedef struct B155 gc155;
struct B155{T155 object;union {void*flag;gc155*next;} header;};
extern gc155*store155;
extern int store_left155;
extern fsoc*store_chunk155;
extern gc155*gc_free155;
typedef struct B73 gc73;
struct B73{T73 object;union {void*flag;gc73*next;} header;};
extern gc73*store73;
extern int store_left73;
extern fsoc*store_chunk73;
extern gc73*gc_free73;
typedef struct B134 gc134;
struct B134{T134 object;union {void*flag;gc134*next;} header;};
extern gc134*store134;
extern int store_left134;
extern fsoc*store_chunk134;
extern gc134*gc_free134;
typedef struct B133 gc133;
struct B133{T133 object;union {void*flag;gc133*next;} header;};
extern gc133*store133;
extern int store_left133;
extern fsoc*store_chunk133;
extern gc133*gc_free133;
typedef struct B131 gc131;
struct B131{T131 object;union {void*flag;gc131*next;} header;};
extern gc131*store131;
extern int store_left131;
extern fsoc*store_chunk131;
extern gc131*gc_free131;
typedef struct B53 gc53;
struct B53{T53 object;union {void*flag;gc53*next;} header;};
extern gc53*store53;
extern int store_left53;
extern fsoc*store_chunk53;
extern gc53*gc_free53;
typedef struct B46 gc46;
struct B46{T46 object;union {void*flag;gc46*next;} header;};
extern gc46*store46;
extern int store_left46;
extern fsoc*store_chunk46;
extern gc46*gc_free46;
typedef struct B191 gc191;
struct B191{T191 object;union {void*flag;gc191*next;} header;};
extern gc191*store191;
extern int store_left191;
extern fsoc*store_chunk191;
extern gc191*gc_free191;
typedef struct B247 gc247;
struct B247{T247 object;union {void*flag;gc247*next;} header;};
extern gc247*store247;
extern int store_left247;
extern fsoc*store_chunk247;
extern gc247*gc_free247;

#define gc_mark245(x) (((se_agent0*)(x))->gc_mark_agent_mold((se_agent*)(x)))

typedef struct B68 gc68;
struct B68{T68 object;union {void*flag;gc68*next;} header;};
extern gc68*store68;
extern int store_left68;
extern fsoc*store_chunk68;
extern gc68*gc_free68;
typedef struct B43 gc43;
struct B43{T43 object;union {void*flag;gc43*next;} header;};
extern gc43*store43;
extern int store_left43;
extern fsoc*store_chunk43;
extern gc43*gc_free43;
typedef struct B70 gc70;
struct B70{T70 object;union {void*flag;gc70*next;} header;};
extern gc70*store70;
extern int store_left70;
extern fsoc*store_chunk70;
extern gc70*gc_free70;
typedef struct B244 gc244;
struct B244{T244 object;union {void*flag;gc244*next;} header;};
extern gc244*store244;
extern int store_left244;
extern fsoc*store_chunk244;
extern gc244*gc_free244;
extern na_env na_env9;
typedef struct B7 gc7;
struct B7{T7 object;union {void*flag;gc7*next;} header;};
extern gc7*store7;
extern int store_left7;
extern fsoc*store_chunk7;
extern gc7*gc_free7;
typedef struct B71 gc71;
struct B71{T71 object;union {void*flag;gc71*next;} header;};
extern gc71*store71;
extern int store_left71;
extern fsoc*store_chunk71;
extern gc71*gc_free71;
typedef struct B65 gc65;
struct B65{T65 object;union {void*flag;gc65*next;} header;};
extern gc65*store65;
extern int store_left65;
extern fsoc*store_chunk65;
extern gc65*gc_free65;
typedef struct B25 gc25;
struct B25{T25 object;union {void*flag;gc25*next;} header;};
extern gc25*store25;
extern int store_left25;
extern fsoc*store_chunk25;
extern gc25*gc_free25;
void gc_sweep113(fsoc*c);
void gc_mark113(T113*o);
void gc_align_mark113(fsoc*c,gc113*p);
extern fsoc H113;
T113*new113(void);
void gc_sweep123(fsoc*c);
void gc_mark123(T123*o);
void gc_align_mark123(fsoc*c,gc123*p);
extern fsoc H123;
T123*new123(void);
void gc_mark337(T337 o);
T337 new337(unsigned int size);
void gc_mark336(T336 o);
T336 new336(unsigned int size);
void gc_mark335(T335 o);
T335 new335(unsigned int size);
void gc_mark334(T334 o);
T334 new334(unsigned int size);
void gc_mark333(T333 o);
T333 new333(unsigned int size);
void gc_mark332(T332 o);
T332 new332(unsigned int size);
void gc_mark331(T331 o);
T331 new331(unsigned int size);
void gc_mark330(T330 o);
T330 new330(unsigned int size);
void gc_sweep329(fsoc*c);
void gc_update_weak_ref_item329(T329* wr);
void gc_mark329(T329*o);
void gc_align_mark329(fsoc*c,gc329*p);
extern fsoc H329;
T329*new329(void);
void gc_mark328(T328 o);
T328 new328(unsigned int size);
void gc_sweep327(fsoc*c);
void gc_mark327(T327*o);
void gc_align_mark327(fsoc*c,gc327*p);
extern fsoc H327;
T327*new327(void);
void gc_sweep326(fsoc*c);
void gc_update_weak_ref_item_polymorph(T0** item);
void gc_mark326(T326*o);
void gc_align_mark326(fsoc*c,gc326*p);
extern fsoc H326;
T326*new326(void);
void gc_mark324(T324 o);
T324 new324(unsigned int size);
void gc_mark321(T321 o);
T321 new321(unsigned int size);
void gc_sweep317(fsoc*c);
void gc_mark317(T317*o);
void gc_align_mark317(fsoc*c,gc317*p);
extern fsoc H317;
T317*new317(void);
void gc_mark316(T316 o);
T316 new316(unsigned int size);
void gc_sweep311(fsoc*c);
void gc_mark311(T311*o);
void gc_align_mark311(fsoc*c,gc311*p);
extern fsoc H311;
T311*new311(void);
void gc_mark310(T310 o);
T310 new310(unsigned int size);
void gc_sweep308(fsoc*c);
void gc_update_weak_ref_item308(T308* wr);
void gc_mark308(T308*o);
void gc_align_mark308(fsoc*c,gc308*p);
extern fsoc H308;
T308*new308(void);
void gc_sweep307(fsoc*c);
void gc_mark307(T307*o);
void gc_align_mark307(fsoc*c,gc307*p);
extern fsoc H307;
T307*new307(void);
void gc_mark306(T306 o);
T306 new306(unsigned int size);
void gc_mark305(T305 o);
T305 new305(unsigned int size);
void gc_mark304(T304 o);
T304 new304(unsigned int size);
void gc_mark303(T303 o);
T303 new303(unsigned int size);
void gc_sweep302(fsoc*c);
void gc_update_weak_ref_item302(T302* wr);
void gc_mark302(T302*o);
void gc_align_mark302(fsoc*c,gc302*p);
extern fsoc H302;
T302*new302(void);
void gc_mark301(T301 o);
T301 new301(unsigned int size);
void gc_sweep300(fsoc*c);
void gc_mark300(T300*o);
void gc_align_mark300(fsoc*c,gc300*p);
extern fsoc H300;
T300*new300(void);
void gc_mark299(T299 o);
T299 new299(unsigned int size);
void gc_sweep298(fsoc*c);
void gc_mark298(T298*o);
void gc_align_mark298(fsoc*c,gc298*p);
extern fsoc H298;
T298*new298(void);
void gc_sweep297(fsoc*c);
void gc_update_weak_ref_item297(T297* wr);
void gc_mark297(T297*o);
void gc_align_mark297(fsoc*c,gc297*p);
extern fsoc H297;
T297*new297(void);
void gc_sweep296(fsoc*c);
void gc_mark296(T296*o);
void gc_align_mark296(fsoc*c,gc296*p);
extern fsoc H296;
T296*new296(void);
void gc_mark295(T295 o);
T295 new295(unsigned int size);
void gc_mark294(T294 o);
T294 new294(unsigned int size);
void gc_sweep293(fsoc*c);
void gc_update_weak_ref_item293(T293* wr);
void gc_mark293(T293*o);
void gc_align_mark293(fsoc*c,gc293*p);
extern fsoc H293;
T293*new293(void);
void gc_sweep292(fsoc*c);
void gc_mark292(T292*o);
void gc_align_mark292(fsoc*c,gc292*p);
extern fsoc H292;
T292*new292(void);
void gc_mark291(T291 o);
T291 new291(unsigned int size);
void gc_sweep290(fsoc*c);
void gc_mark290(T290*o);
void gc_align_mark290(fsoc*c,gc290*p);
extern fsoc H290;
T290*new290(void);
void gc_sweep289(fsoc*c);
void gc_update_weak_ref_item289(T289* wr);
void gc_mark289(T289*o);
void gc_align_mark289(fsoc*c,gc289*p);
extern fsoc H289;
T289*new289(void);
void gc_sweep288(fsoc*c);
void gc_mark288(T288*o);
void gc_align_mark288(fsoc*c,gc288*p);
extern fsoc H288;
T288*new288(void);
void gc_sweep287(fsoc*c);
void gc_update_weak_ref_item287(T287* wr);
void gc_mark287(T287*o);
void gc_align_mark287(fsoc*c,gc287*p);
extern fsoc H287;
T287*new287(void);
void gc_sweep284(fsoc*c);
void gc_mark284(T284*o);
void gc_align_mark284(fsoc*c,gc284*p);
extern fsoc H284;
T284*new284(void);
void gc_mark283(T283 o);
T283 new283(unsigned int size);
void gc_mark282(T282 o);
T282 new282(unsigned int size);
void gc_mark281(T281 o);
T281 new281(unsigned int size);
void gc_sweep280(fsoc*c);
void gc_mark280(T280*o);
void gc_align_mark280(fsoc*c,gc280*p);
extern fsoc H280;
T280*new280(void);
void gc_sweep154(fsoc*c);
void gc_mark154(T154*o);
void gc_align_mark154(fsoc*c,gc154*p);
extern fsoc H154;
T154*new154(void);
void gc_sweep279(fsoc*c);
void gc_mark279(T279*o);
void gc_align_mark279(fsoc*c,gc279*p);
extern fsoc H279;
T279*new279(void);
void gc_sweep160(fsoc*c);
void gc_mark160(T160*o);
void gc_align_mark160(fsoc*c,gc160*p);
extern fsoc H160;
T160*new160(void);
void gc_sweep277(fsoc*c);
void gc_mark277(T277*o);
void gc_align_mark277(fsoc*c,gc277*p);
extern fsoc H277;
T277*new277(void);
void gc_sweep276(fsoc*c);
void gc_mark276(T276*o);
void gc_align_mark276(fsoc*c,gc276*p);
extern fsoc H276;
T276*new276(void);
void gc_sweep275(fsoc*c);
void gc_mark275(T275*o);
void gc_align_mark275(fsoc*c,gc275*p);
extern fsoc H275;
T275*new275(void);
void gc_sweep273(fsoc*c);
void gc_mark273(T273*o);
void gc_align_mark273(fsoc*c,gc273*p);
extern fsoc H273;
T273*new273(void);
void gc_sweep271(fsoc*c);
void gc_mark271(T271*o);
void gc_align_mark271(fsoc*c,gc271*p);
extern fsoc H271;
T271*new271(void);
void gc_sweep269(fsoc*c);
void gc_mark269(T269*o);
void gc_align_mark269(fsoc*c,gc269*p);
extern fsoc H269;
T269*new269(void);
void gc_sweep268(fsoc*c);
void gc_mark268(T268*o);
void gc_align_mark268(fsoc*c,gc268*p);
extern fsoc H268;
T268*new268(void);
void gc_sweep146(fsoc*c);
void gc_mark146(T146*o);
void gc_align_mark146(fsoc*c,gc146*p);
extern fsoc H146;
T146*new146(void);
void gc_sweep267(fsoc*c);
void gc_mark267(T267*o);
void gc_align_mark267(fsoc*c,gc267*p);
extern fsoc H267;
T267*new267(void);
void gc_sweep149(fsoc*c);
void gc_mark149(T149*o);
void gc_align_mark149(fsoc*c,gc149*p);
extern fsoc H149;
T149*new149(void);
void gc_sweep266(fsoc*c);
void gc_mark266(T266*o);
void gc_align_mark266(fsoc*c,gc266*p);
extern fsoc H266;
T266*new266(void);
void gc_sweep148(fsoc*c);
void gc_mark148(T148*o);
void gc_align_mark148(fsoc*c,gc148*p);
extern fsoc H148;
T148*new148(void);
void gc_sweep265(fsoc*c);
void gc_mark265(T265*o);
void gc_align_mark265(fsoc*c,gc265*p);
extern fsoc H265;
T265*new265(void);
void gc_mark264(T264 o);
T264 new264(unsigned int size);
void gc_sweep263(fsoc*c);
void gc_mark263(T263*o);
void gc_align_mark263(fsoc*c,gc263*p);
extern fsoc H263;
T263*new263(void);
void gc_sweep262(fsoc*c);
void gc_mark262(T262*o);
void gc_align_mark262(fsoc*c,gc262*p);
extern fsoc H262;
T262*new262(void);
void gc_sweep261(fsoc*c);
void gc_mark261(T261*o);
void gc_align_mark261(fsoc*c,gc261*p);
extern fsoc H261;
T261*new261(void);
void gc_sweep260(fsoc*c);
void gc_mark260(T260*o);
void gc_align_mark260(fsoc*c,gc260*p);
extern fsoc H260;
T260*new260(void);
void gc_sweep259(fsoc*c);
void gc_mark259(T259*o);
void gc_align_mark259(fsoc*c,gc259*p);
extern fsoc H259;
T259*new259(void);
void gc_sweep257(fsoc*c);
void gc_mark257(T257*o);
void gc_align_mark257(fsoc*c,gc257*p);
extern fsoc H257;
T257*new257(void);
void gc_sweep256(fsoc*c);
void gc_mark256(T256*o);
void gc_align_mark256(fsoc*c,gc256*p);
extern fsoc H256;
T256*new256(void);
void gc_mark255(T255 o);
T255 new255(unsigned int size);
void gc_mark254(T254 o);
T254 new254(unsigned int size);
void gc_sweep253(fsoc*c);
void gc_mark253(T253*o);
void gc_align_mark253(fsoc*c,gc253*p);
extern fsoc H253;
T253*new253(void);
void gc_sweep250(fsoc*c);
void gc_mark250(T250*o);
void gc_align_mark250(fsoc*c,gc250*p);
extern fsoc H250;
T250*new250(void);
void gc_sweep153(fsoc*c);
void gc_mark153(T153*o);
void gc_align_mark153(fsoc*c,gc153*p);
extern fsoc H153;
T153*new153(void);
void gc_sweep249(fsoc*c);
void gc_mark249(T249*o);
void gc_align_mark249(fsoc*c,gc249*p);
extern fsoc H249;
T249*new249(void);
void gc_sweep248(fsoc*c);
void gc_mark248(T248*o);
void gc_align_mark248(fsoc*c,gc248*p);
extern fsoc H248;
T248*new248(void);
void gc_sweep155(fsoc*c);
void gc_mark155(T155*o);
void gc_align_mark155(fsoc*c,gc155*p);
extern fsoc H155;
T155*new155(void);
void gc_sweep73(fsoc*c);
void gc_mark73(T73*o);
void gc_align_mark73(fsoc*c,gc73*p);
extern fsoc H73;
T73*new73(void);
void gc_sweep134(fsoc*c);
void gc_mark134(T134*o);
void gc_align_mark134(fsoc*c,gc134*p);
extern fsoc H134;
T134*new134(void);
void gc_sweep133(fsoc*c);
void gc_mark133(T133*o);
void gc_align_mark133(fsoc*c,gc133*p);
extern fsoc H133;
T133*new133(void);
void gc_sweep131(fsoc*c);
void gc_mark131(T131*o);
void gc_align_mark131(fsoc*c,gc131*p);
extern fsoc H131;
T131*new131(void);
void gc_sweep53(fsoc*c);
void gc_mark53(T53*o);
void gc_align_mark53(fsoc*c,gc53*p);
extern fsoc H53;
T53*new53(void);
void gc_sweep46(fsoc*c);
void gc_mark46(T46*o);
void gc_align_mark46(fsoc*c,gc46*p);
extern fsoc H46;
T46*new46(void);
void gc_sweep191(fsoc*c);
void gc_mark191(T191*o);
void gc_align_mark191(fsoc*c,gc191*p);
extern fsoc H191;
T191*new191(void);
void gc_sweep247(fsoc*c);
void gc_mark247(T247*o);
void gc_align_mark247(fsoc*c,gc247*p);
extern fsoc H247;
T247*new247(void);
void gc_sweep68(fsoc*c);
void gc_mark68(T68*o);
void gc_align_mark68(fsoc*c,gc68*p);
extern fsoc H68;
T68*new68(void);
void gc_sweep43(fsoc*c);
void gc_mark43(T43*o);
void gc_align_mark43(fsoc*c,gc43*p);
extern fsoc H43;
T43*new43(void);
void gc_sweep70(fsoc*c);
void gc_mark70(T70*o);
void gc_align_mark70(fsoc*c,gc70*p);
extern fsoc H70;
T70*new70(void);
void gc_sweep244(fsoc*c);
void gc_mark244(T244*o);
void gc_align_mark244(fsoc*c,gc244*p);
extern fsoc H244;
T244*new244(void);
void gc_mark9(T9 o);
T9 new9(unsigned int size);
void gc_sweep7(fsoc*c);
void gc_mark7(T7*o);
void gc_align_mark7(fsoc*c,gc7*p);
extern fsoc H7;
T7*new7(void);
void gc_sweep71(fsoc*c);
void gc_mark71(T71*o);
void gc_align_mark71(fsoc*c,gc71*p);
extern fsoc H71;
T71*new71(void);
void gc_sweep65(fsoc*c);
void gc_mark65(T65*o);
void gc_align_mark65(fsoc*c,gc65*p);
extern fsoc H65;
T65*new65(void);
void gc_sweep25(fsoc*c);
void gc_mark25(T25*o);
void gc_align_mark25(fsoc*c,gc25*p);
extern fsoc H25;
T25*new25(void);
void Xgc_mark286(T0*o);
void Xgc_mark49(T0*o);
void Xgc_mark72(T0*o);
extern T25*eiffel_root_object;
extern int se_argc;
extern char**se_argv;
#define SE_MAXID 338
extern T7*g[];
extern T7*t[];
extern int se_strucT[];
void se_atexit(void);
void initialize_eiffel_runtime(int argc,char*argv[]);
int main(int argc,char*argv[]);

#ifdef __cplusplus
}
#endif