File: dictionary.ads

package info (click to toggle)
spark 2012.0.deb-9
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 29,260 kB
  • ctags: 3,098
  • sloc: ada: 186,243; cpp: 13,497; makefile: 685; yacc: 440; lex: 176; ansic: 119; sh: 16
file content (4636 lines) | stat: -rw-r--r-- 188,299 bytes parent folder | download | duplicates (2)
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
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428
3429
3430
3431
3432
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454
3455
3456
3457
3458
3459
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
3532
3533
3534
3535
3536
3537
3538
3539
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
3558
3559
3560
3561
3562
3563
3564
3565
3566
3567
3568
3569
3570
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
3626
3627
3628
3629
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
3684
3685
3686
3687
3688
3689
3690
3691
3692
3693
3694
3695
3696
3697
3698
3699
3700
3701
3702
3703
3704
3705
3706
3707
3708
3709
3710
3711
3712
3713
3714
3715
3716
3717
3718
3719
3720
3721
3722
3723
3724
3725
3726
3727
3728
3729
3730
3731
3732
3733
3734
3735
3736
3737
3738
3739
3740
3741
3742
3743
3744
3745
3746
3747
3748
3749
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772
3773
3774
3775
3776
3777
3778
3779
3780
3781
3782
3783
3784
3785
3786
3787
3788
3789
3790
3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863
3864
3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
3891
3892
3893
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925
3926
3927
3928
3929
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
3967
3968
3969
3970
3971
3972
3973
3974
3975
3976
3977
3978
3979
3980
3981
3982
3983
3984
3985
3986
3987
3988
3989
3990
3991
3992
3993
3994
3995
3996
3997
3998
3999
4000
4001
4002
4003
4004
4005
4006
4007
4008
4009
4010
4011
4012
4013
4014
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024
4025
4026
4027
4028
4029
4030
4031
4032
4033
4034
4035
4036
4037
4038
4039
4040
4041
4042
4043
4044
4045
4046
4047
4048
4049
4050
4051
4052
4053
4054
4055
4056
4057
4058
4059
4060
4061
4062
4063
4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
4095
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115
4116
4117
4118
4119
4120
4121
4122
4123
4124
4125
4126
4127
4128
4129
4130
4131
4132
4133
4134
4135
4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
4172
4173
4174
4175
4176
4177
4178
4179
4180
4181
4182
4183
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
4219
4220
4221
4222
4223
4224
4225
4226
4227
4228
4229
4230
4231
4232
4233
4234
4235
4236
4237
4238
4239
4240
4241
4242
4243
4244
4245
4246
4247
4248
4249
4250
4251
4252
4253
4254
4255
4256
4257
4258
4259
4260
4261
4262
4263
4264
4265
4266
4267
4268
4269
4270
4271
4272
4273
4274
4275
4276
4277
4278
4279
4280
4281
4282
4283
4284
4285
4286
4287
4288
4289
4290
4291
4292
4293
4294
4295
4296
4297
4298
4299
4300
4301
4302
4303
4304
4305
4306
4307
4308
4309
4310
4311
4312
4313
4314
4315
4316
4317
4318
4319
4320
4321
4322
4323
4324
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337
4338
4339
4340
4341
4342
4343
4344
4345
4346
4347
4348
4349
4350
4351
4352
4353
4354
4355
4356
4357
4358
4359
4360
4361
4362
4363
4364
4365
4366
4367
4368
4369
4370
4371
4372
4373
4374
4375
4376
4377
4378
4379
4380
4381
4382
4383
4384
4385
4386
4387
4388
4389
4390
4391
4392
4393
4394
4395
4396
4397
4398
4399
4400
4401
4402
4403
4404
4405
4406
4407
4408
4409
4410
4411
4412
4413
4414
4415
4416
4417
4418
4419
4420
4421
4422
4423
4424
4425
4426
4427
4428
4429
4430
4431
4432
4433
4434
4435
4436
4437
4438
4439
4440
4441
4442
4443
4444
4445
4446
4447
4448
4449
4450
4451
4452
4453
4454
4455
4456
4457
4458
4459
4460
4461
4462
4463
4464
4465
4466
4467
4468
4469
4470
4471
4472
4473
4474
4475
4476
4477
4478
4479
4480
4481
4482
4483
4484
4485
4486
4487
4488
4489
4490
4491
4492
4493
4494
4495
4496
4497
4498
4499
4500
4501
4502
4503
4504
4505
4506
4507
4508
4509
4510
4511
4512
4513
4514
4515
4516
4517
4518
4519
4520
4521
4522
4523
4524
4525
4526
4527
4528
4529
4530
4531
4532
4533
4534
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556
4557
4558
4559
4560
4561
4562
4563
4564
4565
4566
4567
4568
4569
4570
4571
4572
4573
4574
4575
4576
4577
4578
4579
4580
4581
4582
4583
4584
4585
4586
4587
4588
4589
4590
4591
4592
4593
4594
4595
4596
4597
4598
4599
4600
4601
4602
4603
4604
4605
4606
4607
4608
4609
4610
4611
4612
4613
4614
4615
4616
4617
4618
4619
4620
4621
4622
4623
4624
4625
4626
4627
4628
4629
4630
4631
4632
4633
4634
4635
4636
-------------------------------------------------------------------------------
-- (C) Altran Praxis Limited
-------------------------------------------------------------------------------
--
-- The SPARK toolset is free software; you can redistribute it and/or modify it
-- under terms of the GNU General Public License as published by the Free
-- Software Foundation; either version 3, or (at your option) any later
-- version. The SPARK toolset is distributed in the hope that it will be
-- useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
-- Public License for more details. You should have received a copy of the GNU
-- General Public License distributed with the SPARK toolset; see file
-- COPYING3. If not, go to http://www.gnu.org/licenses for a complete copy of
-- the license.
--
--=============================================================================

with ContextManager;
with ExaminerConstants;
with E_Strings;
with LexTokenManager;
with SPARK_IO;
with SP_Symbols;

use type ContextManager.UnitDescriptors;
use type ExaminerConstants.RefType;
use type LexTokenManager.Str_Comp_Result;
use type SPARK_IO.File_Status;
use type SP_Symbols.SP_Symbol;

--# inherit CommandLineData,
--#         CommandLineHandler,
--#         ContextManager,
--#         ExaminerConstants,
--#         E_Strings,
--#         FileSystem,
--#         LexTokenManager,
--#         LexTokenStacks,
--#         Maths,
--#         ScreenEcho,
--#         SPARK_IO,
--#         SP_Symbols,
--#         Statistics,
--#         SystemErrors,
--#         XMLReport;

package Dictionary
--# own Dict : Dictionaries;
is

   --------------------------------------------------------------------------------
   --                             TYPE DEFINITIONS                               --
   --------------------------------------------------------------------------------

   type Symbol is private;
   NullSymbol : constant Symbol;

   type Iterator is private;
   NullIterator : constant Iterator;

   type Location is record
      Start_Position : LexTokenManager.Token_Position;
      End_Position   : LexTokenManager.Token_Position;
   end record;

   Null_Location : constant Location :=
     Location'(Start_Position => LexTokenManager.Null_Token_Position,
               End_Position   => LexTokenManager.Null_Token_Position);

   type Scopes is private;
   -- following constant is not valid for use other than as a placeholder for constructing a
   -- an aggregate that needs a Scope in it (e.g. EmptyNumericError in Error_Types)
   NullScope : constant Scopes;

   -- conversion routines to and from scope follow in access function section

   type Contexts is (ProofContext, ProgramContext);

   type Modes is (DefaultMode, InMode, OutMode, InOutMode, InvalidMode);

   type Abstractions is (IsAbstract, IsRefined);

   type PrefixSort is (AType, ABaseType, AnObject);

   type PackageSort is (Public, PrivateChild);

   type RavenscarPragmas is (Priority, InterruptPriority, AttachHandler);
   subtype RavenscarPragmasWithValue is RavenscarPragmas range Priority .. InterruptPriority;

   type Generic_Kind is (Generic_Of_Subprogram, Generic_Of_Package);

   type Generic_Parameter_Kind is (Generic_Type_Parameter, Generic_Object_Parameter);

   type SLI_Type is (
                     SLI_Array_Object,
                     SLI_Array_Type,
                     SLI_Boolean_Object,
                     SLI_Boolean_Type,
                     SLI_Enumeration_Object,
                     SLI_Enumeration_Type,
                     SLI_Floating_Point_Object,
                     SLI_Floating_Point_Type,
                     SLI_Abstract_Type,
                     SLI_Signed_Integer_Object,
                     SLI_Signed_Integer_Type,
                     SLI_Generic_Package_Type,
                     SLI_Package_Type,
                     SLI_Label_On_Loop,
                     SLI_Modular_Integer_Object,
                     SLI_Modular_Integer_Type,
                     SLI_Enumeration_Literal,
                     SLI_Named_Number,
                     SLI_Fixed_Point_Object,
                     SLI_Fixed_Point_Type,
                     SLI_Record_Object,
                     SLI_Record_Type,
                     SLI_String_Object,
                     SLI_String_Type,
                     SLI_Task_Object,
                     SLI_Task_Type,
                     SLI_Generic_Procedure_Type,
                     SLI_Procedure_Type,
                     SLI_Generic_Function_Op,
                     SLI_Function_Op,
                     SLI_Protected_Object,
                     SLI_Protected_Type,
                     SLI_Entry_Family,
                     SLI_Generic_Formal_Parameter,
                     SLI_Unknown_Type);

   -- The generation of replacement rules for composite constants is governed
   -- by an object_assertion annotation.  This can either explicitly request
   -- that a rule be generated, request that NO rule be generated, or can be
   -- left unspecified.  The action of the Examiner for these cases also depends
   -- on the setting of the /rules=XXX command-line switch declared in
   -- commandlinedata.ads
   type Rule_Policies is (Unspecified, Rule_Requested, No_Rule_Requested);

   type Visibility is (Visible, Privat, Local);

   function Is_Null_Symbol (TheSymbol : Symbol) return Boolean;
   --# return TheSymbol = NullSymbol;

   function IsDeclaration (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsEnumerationLiteral (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsArrayIndex (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsSubcomponent (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsTypeMark (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsConstant (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsVariable (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsGlobalVariable (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsQuantifiedVariable (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsImplicitReturnVariable (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsImplicitInStream (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsRulePolicy (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsParameterConstraint (TheSymbol : Symbol) return Boolean;
   --# global in Dict;
   -- A subprgoram parameter constraint is a special symbol associated with unconstrained formal parameters

   function IsSubprogramParameter (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsSubprogram (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsOperator (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsDependency (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsPackage (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsGenericParameterSymbol (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsKnownDiscriminant (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsLoop (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsImplicitProofFunction (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsLoopParameter (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   --------------------------------------------------------------------------------
   -- Null Test and Equality of Symbols                                          --
   --                                                                            --
   -- If you know two Symbols are of the same kind (e.g. both denote a package,  --
   -- a type, and so on), then equality should be tested using the strongly-     --
   -- typed functions below.                                                     --
   --                                                                            --
   -- General equality between two Symbols is available using the predefined     --
   -- "=" operator.                                                              --
   --------------------------------------------------------------------------------

   -- This function replaces the "=" function between 2 symbols but
   -- works only between 2 Enumeration_Literals or Null Symbols. If one of the arguments
   -- is not an Enumeration_Literal, the function terminates the Examiner.
   function Enumeration_Literals_Are_Equal (Left_Symbol, Right_Symbol : Symbol) return Boolean;
   --# global in Dict;
   --# return Left_Symbol = Right_Symbol;

   -- This function replaces the "=" function between 2 symbols but
   -- works only between 2 Record_Components or Null Symbols. If one of the arguments
   -- is not an Record_Component, the function terminates the Examiner.
   function Record_Components_Are_Equal (Left_Symbol, Right_Symbol : Symbol) return Boolean;
   --# global in Dict;
   --# return Left_Symbol = Right_Symbol;

   -- This function replaces the "=" function between 2 symbols but
   -- works only between 2 Types or Null Symbols. If one of the arguments
   -- is not a Type, the function terminates the Examiner.
   function Types_Are_Equal (Left_Symbol, Right_Symbol : Symbol;
                             Full_Range_Subtype        : Boolean) return Boolean;
   --# global in Dict;
   --# return R => (not Full_Range_Subtype -> R = (Left_Symbol = Right_Symbol));

   -- This function replaces the "=" function between 2 symbols but
   -- works only between 2 Variables or Null Symbols. If one of the arguments
   -- is not a Variable, the function terminates the Examiner.
   function Variables_Are_Equal (Left_Symbol, Right_Symbol : Symbol) return Boolean;
   --# global in Dict;
   --# return Left_Symbol = Right_Symbol;

   -- This function replaces the "=" function between 2 symbols but
   -- works only between 2 Implicit_Return_Variables or Null Symbols. If one of the arguments
   -- is not a Implicit_Return_Variable, the function terminates the Examiner.
   function Implicit_Return_Variables_Are_Equal (Left_Symbol, Right_Symbol : Symbol) return Boolean;
   --# global in Dict;
   --# return Left_Symbol = Right_Symbol;

   -- This function replaces the "=" function between 2 symbols but
   -- works only between 2 Subprograms or Null Symbols. If one of the arguments
   -- is not a Subprogram, the function terminates the Examiner.
   function Subprograms_Are_Equal (Left_Symbol, Right_Symbol : Symbol) return Boolean;
   --# global in Dict;
   --# return Left_Symbol = Right_Symbol;

   -- This function replaces the "=" function between 2 symbols but
   -- works only between 2 Packages or Null Symbols. If one of the arguments
   -- is not a Package, the function terminates the Examiner.
   function Packages_Are_Equal (Left_Symbol, Right_Symbol : Symbol) return Boolean;
   --# global in Dict;
   --# return Left_Symbol = Right_Symbol;

   --------------------------------------------------------------------------------
   --                               HOUSEKEEPING                                 --
   --------------------------------------------------------------------------------

   procedure Initialize (Write_To_File : in Boolean);
   --# global in     CommandLineData.Content;
   --#        in out LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --#           out Dict;
   --# derives Dict,
   --#         SPARK_IO.File_Sys     from CommandLineData.Content,
   --#                                    LexTokenManager.State,
   --#                                    SPARK_IO.File_Sys,
   --#                                    Write_To_File &
   --#         LexTokenManager.State from *,
   --#                                    CommandLineData.Content;

   procedure Set_Current_File_Name (File_Name : in E_Strings.T);
   --# global in     CommandLineData.Content;
   --#        in out Dict;
   --# derives Dict from *,
   --#                   CommandLineData.Content,
   --#                   File_Name;

   function GetOwnVariableOrConstituentMode (Variable : Symbol) return Modes;
   --# global in Dict;

   procedure Write (File_Name : in     E_Strings.T;
                    Status    :    out SPARK_IO.File_Status);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                File_Name,
   --#                                SPARK_IO.File_Sys &
   --#         SPARK_IO.File_Sys,
   --#         Status            from Dict,
   --#                                File_Name,
   --#                                LexTokenManager.State,
   --#                                SPARK_IO.File_Sys;

   procedure Add_Generic_Unit
     (Kind         : in     Generic_Kind;
      Scope        : in     Scopes;
      Comp_Unit    : in     ContextManager.UnitDescriptors;
      Declaration  : in     Location;
      Generic_Unit :    out Symbol);
   --# global in out Dict;
   --# derives Dict,
   --#         Generic_Unit from Comp_Unit,
   --#                           Declaration,
   --#                           Dict,
   --#                           Kind,
   --#                           Scope;

   procedure ReportUsage;
   --# global in     Dict;
   --#        in out Statistics.TableUsage;
   --# derives Statistics.TableUsage from *,
   --#                                    Dict;

   procedure Read_Target_Data_File;
   --# global in     CommandLineData.Content;
   --#        in out Dict;
   --#        in out LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         LexTokenManager.State,
   --#         SPARK_IO.File_Sys     from *,
   --#                                    CommandLineData.Content,
   --#                                    LexTokenManager.State,
   --#                                    SPARK_IO.File_Sys;

   procedure Output_Target_Data_File (To_File : in SPARK_IO.File_Type);
   --# global in     CommandLineData.Content;
   --#        in out LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --#        in out XMLReport.State;
   --# derives LexTokenManager.State,
   --#         SPARK_IO.File_Sys,
   --#         XMLReport.State       from CommandLineData.Content,
   --#                                    LexTokenManager.State,
   --#                                    SPARK_IO.File_Sys,
   --#                                    To_File,
   --#                                    XMLReport.State;

   --------------------------------------------------------------------------------
   --                                SYMBOLS and ORDERING                        --
   --------------------------------------------------------------------------------

   function Declared_Before (Left, Right : in Symbol) return Boolean;

   --------------------------------------------------------------------------------
   --                              LOOKUP ROUTINES                               --
   --------------------------------------------------------------------------------

   function GlobalScope return Scopes;
   --# global in Dict;

   function Set_Visibility (The_Visibility : Visibility;
                            The_Unit       : Symbol) return Scopes;

   function Get_Visibility (Scope : Scopes) return Visibility;

   function IsLibraryLevel (Scope : Scopes) return Boolean;
   --# global in Dict;

   function IsPredefinedScope (Scope : Scopes) return Boolean;
   --# global in Dict;

   function IsGlobalScope (Scope : Scopes) return Boolean;
   --# global in Dict;

   function GetRegion (Scope : Scopes) return Symbol;

   function IsLocal (Inner, Outer : Scopes) return Boolean;
   --# global in Dict;

   function GetContext (TheSymbol : Symbol) return Contexts;
   --# global in Dict;

   function GetRootPackage (ThePackage : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsPackage (S, Dict));

   function GetLibraryPackage (Scope : Scopes) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsPackage (S, Dict));

   function IsPrivatePackage (ThePackage : Symbol) return Boolean;
   --# global in Dict;

   function GetPackageParent (ThePackage : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsPackage (S, Dict));

   function PackageDeclaresTaggedType (ThePackage : Symbol) return Boolean;
   --# global in Dict;

   function PackageExtendsAnotherPackage (ThePackage : Symbol) return Boolean;
   --# global in Dict;

   function GetPackageThatIsExtended (ThePackage : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsPackage (S, Dict));

   -- Package ownership is a relationship defined as follows:
   -- The owner of a package (if any) is defined to be the
   -- the parent of its closest private ancestor, where the term ancestor is
   -- as defined 10.1.1(11) of the Ada 95 LRM [2], to include the package itself.
   -- As a consequence of this rule only a private package or its private
   -- or public descendents can have an owner.
   -- This definition is given in S.P0468.42.8 section 2.3.3.6 and
   -- a consequntial rule given in the SPARK LRM section 7.1.1.
   function GetPackageOwner (ThePackage : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsPackage (S, Dict));

   function IsProperDescendent (Inner, Outer : Symbol) return Boolean;
   --# global in Dict;

   function IsPrivateDescendent (Inner, Outer : Symbol) return Boolean;
   --# global in Dict;

   function IsDescendentOfPrivateSibling (Candidate, ThePackage : Symbol) return Boolean;
   --# global in Dict;

   function IsDirectlyDefined
     (Name    : LexTokenManager.Lex_String;
      Scope   : Scopes;
      Context : Contexts)
     return    Boolean;
   --# global in Dict;
   --#        in LexTokenManager.State;

   function IsDefined
     (Name              : LexTokenManager.Lex_String;
      Scope             : Scopes;
      Context           : Contexts;
      Full_Package_Name : Boolean)
     return              Boolean;
   --# global in CommandLineData.Content;
   --#        in Dict;
   --#        in LexTokenManager.State;

   function UnaryOperatorIsDefined (Name    : SP_Symbols.SP_Symbol;
                                    Operand : Symbol) return Boolean;
   --# global in CommandLineData.Content;
   --#        in Dict;

   function Get_Binary_Operator_Type
     (Name  : SP_Symbols.SP_Symbol;
      Left  : Symbol;
      Right : Symbol)
     return  Symbol;
   --# global in CommandLineData.Content;
   --#        in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function UnaryOperatorIsVisible
     (Name    : SP_Symbols.SP_Symbol;
      Operand : Symbol;
      Scope   : Scopes)
     return    Boolean;
   --# global in CommandLineData.Content;
   --#        in Dict;

   function BinaryOperatorIsVisible
     (Name  : SP_Symbols.SP_Symbol;
      Left  : Symbol;
      Right : Symbol;
      Scope : Scopes)
     return  Boolean;
   --# global in CommandLineData.Content;
   --#        in Dict;

   function AttributeIsVisible
     (Name     : LexTokenManager.Lex_String;
      Prefix   : PrefixSort;
      TypeMark : Symbol;
      Scope    : Scopes)
     return     Boolean;
   --# global in CommandLineData.Content;
   --#        in Dict;
   --#        in LexTokenManager.State;

   function Attribute_Is_Visible_But_Obsolete
     (Name     : LexTokenManager.Lex_String;
      Prefix   : PrefixSort;
      TypeMark : Symbol;
      Scope    : Scopes)
     return     Boolean;
   --# global in CommandLineData.Content;
   --#        in Dict;
   --#        in LexTokenManager.State;

   function PrefixAllowed (Prefix : Symbol;
                           Scope  : Scopes) return Boolean;
   --# global in Dict;

   function PrefixRequired (Item  : Symbol;
                            Scope : Scopes) return Boolean;
   --# global in Dict;

   function GetPrefix (Item : Symbol) return LexTokenManager.Lex_String;
   --# global in Dict;

   function LookupImmediateScope
     (Name    : LexTokenManager.Lex_String;
      Scope   : Scopes;
      Context : Contexts)
     return    Symbol;
   --# global in Dict;
   --#        in LexTokenManager.State;

   function LookupItem
     (Name              : LexTokenManager.Lex_String;
      Scope             : Scopes;
      Context           : Contexts;
      Full_Package_Name : Boolean)
     return              Symbol;
   --# global in CommandLineData.Content;
   --#        in Dict;
   --#        in LexTokenManager.State;

   function LookupSelectedItem
     (Prefix   : Symbol;
      Selector : LexTokenManager.Lex_String;
      Scope    : Scopes;
      Context  : Contexts)
     return     Symbol;
   --# global in CommandLineData.Content;
   --#        in Dict;
   --#        in LexTokenManager.State;

   function Is_Subprogram (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   -- starting in Scope look for operations inherited as a result of use of
   -- tagged and extended tagged types.  Returns NullSymbol if no match found.
   -- ActualTaggedType is set (on successful return) to the type of the tagged parameter
   -- required in the calling environment.
   procedure SearchForInheritedOperations
     (Name             : in     LexTokenManager.Lex_String;
      Scope            : in     Scopes;
      Prefix           : in     Symbol;
      Context          : in     Contexts;
      OpSym            :    out Symbol;
      ActualTaggedType :    out Symbol);
   --# global in CommandLineData.Content;
   --#        in Dict;
   --#        in LexTokenManager.State;
   --# derives ActualTaggedType,
   --#         OpSym            from CommandLineData.Content,
   --#                               Context,
   --#                               Dict,
   --#                               LexTokenManager.State,
   --#                               Name,
   --#                               Prefix,
   --#                               Scope;
   --# post (Is_Null_Symbol (OpSym) or Is_Subprogram (OpSym, Dict)) and
   --#   (Is_Null_Symbol (ActualTaggedType) or IsTypeMark (ActualTaggedType, Dict));

   function GetSubprogramControllingType (Subprogram : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));
   -- returns null symbol if the subprogram does not have a controlling type (i.e. a parameter of a tagged
   -- type which is declared in the same package as the subprogram)

   function GetOverriddenSubprogram (Subprogram : Symbol) return Symbol;
   --# global in Dict;
   --#        in LexTokenManager.State;

   function IsCallable
     (Subprogram   : Symbol;
      PrefixNeeded : Boolean;
      Scope        : Scopes)
     return         Boolean;
   --# global in Dict;

   function GenerateSimpleName (Item      : Symbol;
                                Separator : String) return E_Strings.T;
   --# global in Dict;
   --#        in LexTokenManager.State;

   function GetAnyPrefixNeeded
     (Sym       : Symbol;
      Scope     : Scopes;
      Separator : String)
     return      E_Strings.T;
   --# global in CommandLineData.Content;
   --#        in Dict;
   --#        in LexTokenManager.State;

   function IsValidGenericTypeAssociation (Formal, Actual : Symbol;
                                           Scope          : Scopes) return Boolean;
   --# global in Dict;

   function Get_Symbol_Compilation_Unit (Item : Symbol) return ContextManager.UnitDescriptors;
   --# global in Dict;

   function Get_Symbol_Location (Item : Symbol) return LexTokenManager.Token_Position;
   --# global in Dict;

   --  This procedure returns RESULT containing the SLI type
   --  associated with the symbol ITEM.
   procedure Get_SLI_Type (Item   : in     Symbol;
                           Result :    out SLI_Type);
   --# global in     CommandLineData.Content;
   --#        in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives Result            from Dict,
   --#                                Item &
   --#         SPARK_IO.File_Sys from *,
   --#                                CommandLineData.Content,
   --#                                Dict,
   --#                                Item,
   --#                                LexTokenManager.State;

   --------------------------------------------------------------------------------
   --                               CONSTRUCTORS                                 --
   --------------------------------------------------------------------------------

   procedure Add_Deferred_Constant
     (Name           : in     LexTokenManager.Lex_String;
      Type_Mark      : in     Symbol;
      Type_Reference : in     Location;
      Comp_Unit      : in     ContextManager.UnitDescriptors;
      Declaration    : in     Location;
      The_Package    : in     Symbol;
      TheConstant    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         TheConstant       from Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Name,
   --#                                The_Package,
   --#                                Type_Mark &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                The_Package,
   --#                                Type_Mark,
   --#                                Type_Reference;
   --# post IsConstant (TheConstant, Dict);

   procedure Promote_Deferred_To_Full_Constant
     (Constant_Sym : in Symbol;
      Comp_Unit    : in ContextManager.UnitDescriptors;
      Declaration  : in Location;
      Value        : in LexTokenManager.Lex_String;
      Exp_Node     : in ExaminerConstants.RefType;
      The_Package  : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Comp_Unit,
   --#                   Constant_Sym,
   --#                   Declaration,
   --#                   Exp_Node,
   --#                   The_Package,
   --#                   Value;

   procedure Add_Constant
     (Name              : in     LexTokenManager.Lex_String;
      The_Type          : in     Symbol;
      Static            : in     Boolean;
      Comp_Unit         : in     ContextManager.UnitDescriptors;
      Declaration       : in     Location;
      Value             : in     LexTokenManager.Lex_String;
      Exp_Is_Wellformed : in     Boolean;
      Exp_Node          : in     ExaminerConstants.RefType;
      Constant_Sym      : in out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Constant_Sym,
   --#         Dict              from Comp_Unit,
   --#                                Constant_Sym,
   --#                                Declaration,
   --#                                Dict,
   --#                                Exp_Is_Wellformed,
   --#                                Exp_Node,
   --#                                Name,
   --#                                Static,
   --#                                The_Type,
   --#                                Value &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Constant_Sym,
   --#                                Declaration,
   --#                                Dict,
   --#                                Exp_Is_Wellformed,
   --#                                Exp_Node,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Static,
   --#                                The_Type,
   --#                                Value;
   --# post IsConstant (Constant_Sym, Dict);

   procedure Add_Constant_Declaration
     (Name              : in     LexTokenManager.Lex_String;
      Type_Mark         : in     Symbol;
      Type_Reference    : in     Location;
      Value             : in     LexTokenManager.Lex_String;
      Exp_Is_Wellformed : in     Boolean;
      Exp_Node          : in     ExaminerConstants.RefType;
      Static            : in     Boolean;
      Comp_Unit         : in     ContextManager.UnitDescriptors;
      Declaration       : in     Location;
      Scope             : in     Scopes;
      Context           : in     Contexts;
      TheConstant       :    out Symbol);
   --# global in     CommandLineData.Content;
   --#        in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         TheConstant       from CommandLineData.Content,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                Exp_Is_Wellformed,
   --#                                Exp_Node,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope,
   --#                                Static,
   --#                                Type_Mark,
   --#                                Value &
   --#         SPARK_IO.File_Sys from *,
   --#                                CommandLineData.Content,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                Exp_Is_Wellformed,
   --#                                Exp_Node,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope,
   --#                                Static,
   --#                                Type_Mark,
   --#                                Type_Reference,
   --#                                Value;
   --# post IsConstant (TheConstant, Dict);

   procedure AddConstantRulePolicy
     (TheConstant   : in     Symbol;
      Comp_Unit     : in     ContextManager.UnitDescriptors;
      Declaration   : in     Location;
      TheScope      : in     Scopes;
      ThePolicy     : in     Rule_Policies;
      TheRulePolicy :    out Symbol);
   --# global in out Dict;
   --# derives Dict,
   --#         TheRulePolicy from Comp_Unit,
   --#                            Declaration,
   --#                            Dict,
   --#                            TheConstant,
   --#                            ThePolicy,
   --#                            TheScope;
   --# post IsRulePolicy (TheRulePolicy, Dict);

   procedure Add_Variable_Declaration
     (Variable_Sym       : in     Symbol;
      The_Type           : in     Symbol;
      Initialized        : in     Boolean;
      Is_Aliased         : in     Boolean;
      Exp_Node           : in     ExaminerConstants.RefType;
      Type_Reference     : in     Location;
      Comp_Unit          : in     ContextManager.UnitDescriptors;
      Declaration        : in     Location;
      Scope              : in     Scopes;
      Declaration_Symbol :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Declaration_Symbol,
   --#         Dict               from Comp_Unit,
   --#                                 Declaration,
   --#                                 Dict,
   --#                                 Exp_Node,
   --#                                 Initialized,
   --#                                 Is_Aliased,
   --#                                 Scope,
   --#                                 The_Type,
   --#                                 Variable_Sym &
   --#         SPARK_IO.File_Sys  from *,
   --#                                 Comp_Unit,
   --#                                 Declaration,
   --#                                 Dict,
   --#                                 Exp_Node,
   --#                                 Initialized,
   --#                                 Is_Aliased,
   --#                                 LexTokenManager.State,
   --#                                 Scope,
   --#                                 The_Type,
   --#                                 Type_Reference,
   --#                                 Variable_Sym;
   --# pre not Is_Null_Symbol (Variable_Sym);
   --# post IsDeclaration (Declaration_Symbol, Dict);

   -- This procedure may also be called to modify an existing
   --  variable.
   procedure Add_Variable
     (Name               : in     LexTokenManager.Lex_String;
      The_Type           : in     Symbol;
      Initialized        : in     Boolean;
      Is_Aliased         : in     Boolean;
      Exp_Node           : in     ExaminerConstants.RefType;
      Type_Reference     : in     Location;
      Comp_Unit          : in     ContextManager.UnitDescriptors;
      Declaration        : in     Location;
      Scope              : in     Scopes;
      Declaration_Symbol :    out Symbol;
      Variable_Symbol    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Declaration_Symbol,
   --#         Dict,
   --#         Variable_Symbol    from Comp_Unit,
   --#                                 Declaration,
   --#                                 Dict,
   --#                                 Exp_Node,
   --#                                 Initialized,
   --#                                 Is_Aliased,
   --#                                 Name,
   --#                                 Scope,
   --#                                 The_Type &
   --#         SPARK_IO.File_Sys  from *,
   --#                                 Comp_Unit,
   --#                                 Declaration,
   --#                                 Dict,
   --#                                 Exp_Node,
   --#                                 Initialized,
   --#                                 Is_Aliased,
   --#                                 LexTokenManager.State,
   --#                                 Name,
   --#                                 Scope,
   --#                                 The_Type,
   --#                                 Type_Reference;
   --# post IsDeclaration (Declaration_Symbol, Dict) and IsVariable (Variable_Symbol, Dict);

   procedure AddVariableAddressClause (Variable : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Variable;
   -- could also be extended to write location to dictionary file as for other reps

   procedure AddVariablePragmaImport (Variable : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Variable;
   -- could also be extended to write location to dictionary file as for other reps

   procedure AddTypeSizeAttribute (TypeMark : in Symbol;
                                   SizeVal  : in LexTokenManager.Lex_String);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   SizeVal,
   --#                   TypeMark;

   procedure SetTypeAtomic (TypeMark : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TypeMark;

   procedure AddRecordSubcomponent
     (Prefix       : in     Symbol;
      Component    : in     Symbol;
      Comp_Unit    : in     ContextManager.UnitDescriptors;
      Subcomponent :    out Symbol);
   --# global in out Dict;
   --# derives Dict,
   --#         Subcomponent from Component,
   --#                           Comp_Unit,
   --#                           Dict,
   --#                           Prefix;
   --# post IsSubcomponent (Subcomponent, Dict);

   procedure AddQuantifiedVariable
     (Name          : in     LexTokenManager.Lex_String;
      Comp_Unit     : in     ContextManager.UnitDescriptors;
      Declaration   : in     Location;
      TypeMark      : in     Symbol;
      TheConstraint : in     Symbol;
      Region        : in     Symbol;
      Variable      :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         Variable          from Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Name,
   --#                                Region,
   --#                                TheConstraint,
   --#                                TypeMark &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Region,
   --#                                TheConstraint,
   --#                                TypeMark;
   --# post IsQuantifiedVariable (Variable, Dict);

   procedure Add_Type_Announcement
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      The_Package : in     Symbol;
      The_Type    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Type          from Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Name,
   --#                                The_Package &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                The_Package;
   --# post IsTypeMark (The_Type, Dict);

   procedure Add_Private_Type
     (Name           : in     LexTokenManager.Lex_String;
      Comp_Unit      : in     ContextManager.UnitDescriptors;
      Declaration    : in     Location;
      The_Package    : in     Symbol;
      Is_Limited     : in     Boolean;
      Is_Tagged_Type : in     Boolean;
      Extends        : in     Symbol;
      The_Type       :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Type          from Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Extends,
   --#                                Is_Limited,
   --#                                Is_Tagged_Type,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                The_Package &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Extends,
   --#                                Is_Limited,
   --#                                Is_Tagged_Type,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                The_Package;
   --# post IsTypeMark (The_Type, Dict);

   procedure Add_Abstract_Proof_Type
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Scope       : in     Scopes;
      The_Type    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope &
   --#         The_Type          from Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure Add_Default_Abstract_Proof_Type
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Scope       : in     Scopes;
      The_Type    :    out Symbol);
   --# global in out Dict;
   --#        in out LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         SPARK_IO.File_Sys     from *,
   --#                                    Comp_Unit,
   --#                                    Declaration,
   --#                                    Dict,
   --#                                    LexTokenManager.State,
   --#                                    Name,
   --#                                    Scope &
   --#         LexTokenManager.State from *,
   --#                                    Name &
   --#         The_Type              from Comp_Unit,
   --#                                    Declaration,
   --#                                    Dict,
   --#                                    LexTokenManager.State,
   --#                                    Name,
   --#                                    Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure Add_Enumeration_Type
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Scope       : in     Scopes;
      Context     : in     Contexts;
      The_Type    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope &
   --#         The_Type          from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure AddEnumerationLiteral
     (Name                  : in     LexTokenManager.Lex_String;
      Comp_Unit             : in     ContextManager.UnitDescriptors;
      Declaration           : in     Location;
      Position              : in     LexTokenManager.Lex_String;
      The_Type              : in     Symbol;
      TheEnumerationLiteral :    out Symbol);
   --# global in out Dict;
   --# derives Dict,
   --#         TheEnumerationLiteral from Comp_Unit,
   --#                                    Declaration,
   --#                                    Dict,
   --#                                    Name,
   --#                                    Position,
   --#                                    The_Type;
   --# post IsEnumerationLiteral (TheEnumerationLiteral, Dict);

   procedure Add_Representation_Clause (The_Type : in Symbol;
                                        Clause   : in Location);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Clause,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                The_Type;

   procedure AddEnumerationLiteralRepresentation (Literal : in Symbol;
                                                  Code    : in Integer);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Code,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Literal;

   procedure Add_Integer_Type
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Lower       : in     LexTokenManager.Lex_String;
      Upper       : in     LexTokenManager.Lex_String;
      Scope       : in     Scopes;
      Context     : in     Contexts;
      The_Type    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Type          from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Lower,
   --#                                Name,
   --#                                Scope,
   --#                                Upper &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure Add_Predef_Integer_Type
     (Name        : in LexTokenManager.Lex_String;
      Comp_Unit   : in ContextManager.UnitDescriptors;
      Declaration : in Location;
      Lower       : in LexTokenManager.Lex_String;
      Upper       : in LexTokenManager.Lex_String;
      Scope       : in Scopes;
      Context     : in Contexts);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                LexTokenManager.State,
   --#                                Lower,
   --#                                Name,
   --#                                Scope,
   --#                                Upper &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;

   procedure Add_Modular_Type
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Modulus     : in     LexTokenManager.Lex_String;
      Scope       : in     Scopes;
      Context     : in     Contexts;
      The_Type    :    out Symbol);
   --# global in out Dict;
   --#        in out LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Type              from Comp_Unit,
   --#                                    Context,
   --#                                    Declaration,
   --#                                    Dict,
   --#                                    LexTokenManager.State,
   --#                                    Modulus,
   --#                                    Name,
   --#                                    Scope &
   --#         LexTokenManager.State from *,
   --#                                    Modulus &
   --#         SPARK_IO.File_Sys     from *,
   --#                                    Comp_Unit,
   --#                                    Context,
   --#                                    Declaration,
   --#                                    Dict,
   --#                                    LexTokenManager.State,
   --#                                    Name,
   --#                                    Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure Add_Floating_Point_Type
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Lower       : in     LexTokenManager.Lex_String;
      Upper       : in     LexTokenManager.Lex_String;
      Error_Bound : in     LexTokenManager.Lex_String;
      Scope       : in     Scopes;
      Context     : in     Contexts;
      The_Type    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Type          from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                Error_Bound,
   --#                                LexTokenManager.State,
   --#                                Lower,
   --#                                Name,
   --#                                Scope,
   --#                                Upper &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure Add_Predef_Floating_Point_Type
     (Name        : in LexTokenManager.Lex_String;
      Comp_Unit   : in ContextManager.UnitDescriptors;
      Declaration : in Location;
      Lower       : in LexTokenManager.Lex_String;
      Upper       : in LexTokenManager.Lex_String;
      Error_Bound : in LexTokenManager.Lex_String;
      Scope       : in Scopes;
      Context     : in Contexts);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Error_Bound,
   --#                                LexTokenManager.State,
   --#                                Lower,
   --#                                Name,
   --#                                Scope,
   --#                                Upper &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;

   procedure Add_Protected_Type
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Scope       : in     Scopes;
      Context     : in     Contexts;
      Mode        : in     Modes;
      Constrained : in     Boolean;
      The_Type    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Type          from Comp_Unit,
   --#                                Constrained,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Mode,
   --#                                Name,
   --#                                Scope &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure Add_Task_Type
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Scope       : in     Scopes;
      Context     : in     Contexts;
      Constrained : in     Boolean;
      The_Type    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Type          from Comp_Unit,
   --#                                Constrained,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure Add_Task_Or_Protected_Subtype
     (Name        : in     LexTokenManager.Lex_String;
      Parent      : in     Symbol;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Scope       : in     Scopes;
      Context     : in     Contexts;
      The_Subtype :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Parent,
   --#                                Scope &
   --#         The_Subtype       from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Parent,
   --#                                Scope;
   --# post IsTypeMark (The_Subtype, Dict);

   procedure SetTypeIsWellformed (TypeMark   : in Symbol;
                                  Wellformed : in Boolean);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TypeMark,
   --#                   Wellformed;

   procedure SetBaseType (TypeMark, BaseType : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   BaseType,
   --#                   TypeMark;

   procedure Add_Fixed_Point_Type
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Lower       : in     LexTokenManager.Lex_String;
      Upper       : in     LexTokenManager.Lex_String;
      Error_Bound : in     LexTokenManager.Lex_String;
      Scope       : in     Scopes;
      Context     : in     Contexts;
      The_Type    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Type          from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                Error_Bound,
   --#                                LexTokenManager.State,
   --#                                Lower,
   --#                                Name,
   --#                                Scope,
   --#                                Upper &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure Add_Array_Type
     (Name                     : in     LexTokenManager.Lex_String;
      Comp_Unit                : in     ContextManager.UnitDescriptors;
      Declaration              : in     Location;
      Scope                    : in     Scopes;
      Context                  : in     Contexts;
      Constrained              : in     Boolean;
      Component_Type           : in     Symbol;
      Component_Type_Reference : in     Location;
      The_Type                 :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Type          from Component_Type,
   --#                                Comp_Unit,
   --#                                Constrained,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope &
   --#         SPARK_IO.File_Sys from *,
   --#                                Component_Type,
   --#                                Component_Type_Reference,
   --#                                Comp_Unit,
   --#                                Constrained,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure AddArrayIndex
     (TheArrayType  : in     Symbol;
      IndexType     : in     Symbol;
      Comp_Unit     : in     ContextManager.UnitDescriptors;
      Declaration   : in     Location;
      TheArrayIndex :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         TheArrayIndex     from Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                IndexType,
   --#                                TheArrayType &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                IndexType,
   --#                                LexTokenManager.State,
   --#                                TheArrayType;
   --# post IsArrayIndex (TheArrayIndex, Dict);

   procedure Add_Record_Type
     (Name           : in     LexTokenManager.Lex_String;
      Is_Tagged_Type : in     Boolean;
      Extends        : in     Symbol;
      Comp_Unit      : in     ContextManager.UnitDescriptors;
      Declaration    : in     Location;
      Scope          : in     Scopes;
      Context        : in     Contexts;
      The_Type       :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Type          from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                Extends,
   --#                                Is_Tagged_Type,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure AddRecordComponent
     (Name                   : in LexTokenManager.Lex_String;
      Comp_Unit              : in ContextManager.UnitDescriptors;
      Declaration            : in Location;
      TheRecordType          : in Symbol;
      TheComponentType       : in Symbol;
      InheritedField         : in Boolean;
      ComponentTypeReference : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                InheritedField,
   --#                                Name,
   --#                                TheComponentType,
   --#                                TheRecordType &
   --#         SPARK_IO.File_Sys from *,
   --#                                ComponentTypeReference,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                InheritedField,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                TheComponentType,
   --#                                TheRecordType;

   -- Generic types

   procedure Add_Generic_Type
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Scope       : in     Scopes;
      The_Type    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope &
   --#         The_Type          from Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope;
   --# post IsTypeMark (The_Type, Dict);

   procedure Set_Generic_Private_Type (The_Type   : in Symbol;
                                       Is_Limited : in Boolean);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Is_Limited,
   --#                   The_Type;

   procedure Set_Generic_Discrete_Type (The_Type : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   The_Type;

   procedure Set_Generic_Integer_Type (The_Type : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   The_Type;

   procedure Set_Generic_Modular_Type (The_Type : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   The_Type;

   procedure Set_Generic_Floating_Point_Type (The_Type : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   The_Type;

   procedure Set_Generic_Fixed_Point_Type (The_Type : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   The_Type;

   procedure Set_Generic_Array_Type (The_Type : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   The_Type;

   procedure Add_Generic_Object
     (Name           : in     LexTokenManager.Lex_String;
      Comp_Unit      : in     ContextManager.UnitDescriptors;
      Declaration    : in     Location;
      Scope          : in     Scopes;
      The_Type       : in     Symbol;
      The_Object_Sym :    out Symbol);
   --# global in out Dict;
   --# derives Dict,
   --#         The_Object_Sym from Comp_Unit,
   --#                             Declaration,
   --#                             Dict,
   --#                             Name,
   --#                             Scope,
   --#                             The_Type;
   --# post IsConstant (The_Object_Sym, Dict);

   procedure AddRecordComponentRepresentation
     (Component        : in Symbol;
      Clause           : in Location;
      RelativeAddress  : in Natural;
      FirstBitPosition : in Natural;
      LastBitPosition  : in Natural);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Clause,
   --#                                Component,
   --#                                Dict,
   --#                                FirstBitPosition,
   --#                                LastBitPosition,
   --#                                LexTokenManager.State,
   --#                                RelativeAddress;

   procedure AddAlignmentClause (TheType : in Symbol;
                                 Clause  : in Location);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Clause,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                TheType;

   procedure AddLoop
     (Scope         : in     Scopes;
      Comp_Unit     : in     ContextManager.UnitDescriptors;
      LoopStatement : in     Location;
      TheLoop       :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                LoopStatement,
   --#                                Scope &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                LoopStatement,
   --#                                Scope &
   --#         TheLoop           from Comp_Unit,
   --#                                Dict,
   --#                                LoopStatement;

   procedure AddLoopName (Name    : in LexTokenManager.Lex_String;
                          TheLoop : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Name,
   --#                   TheLoop;

   procedure AddLoopParameter
     (TheLoop       : in Symbol;
      Comp_Unit     : in ContextManager.UnitDescriptors;
      Declaration   : in Location;
      Name          : in LexTokenManager.Lex_String;
      TypeMark      : in Symbol;
      StaticRange   : in Boolean;
      IsReverse     : in Boolean;
      TypeReference : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                IsReverse,
   --#                                Name,
   --#                                StaticRange,
   --#                                TheLoop,
   --#                                TypeMark &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                IsReverse,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                StaticRange,
   --#                                TheLoop,
   --#                                TypeMark,
   --#                                TypeReference;

   procedure MarkLoopHasExits (TheLoop : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TheLoop;

   -- This is used by the VCG to store a Cells.Cell representing the exit expression of
   -- a for loop. Used by DAG.BuildGraph to build the default loop invariant.
   procedure SetLoopExitExpn (ForLoop : in Symbol;
                              Expn    : in Natural);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Expn,
   --#                   ForLoop;

   -- This is used by the VCG to store a Cells.Cell representing the entry expression of
   -- a for loop. Used by DAG.BuildGraph to build the default loop invariant.
   procedure SetLoopEntryExpn (ForLoop : in Symbol;
                               Expn    : in Natural);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Expn,
   --#                   ForLoop;

   -- Following is used by VCG in for loop modelling to create a variable uniquely associated
   -- with an original variable and a loop.  The original variable is used in the exit expression
   -- of a for loop and the new one is used to store the value on entry to the loop so as to
   -- freeze the loop bounds as required by Ada semantics.
   procedure IdempotentCreateLoopOnEntryVariable
     (OriginalVariable : in     Symbol;
      TheLoop          : in     Symbol;
      OnEntryVariable  :    out Symbol);
   --# global in out Dict;
   --# derives Dict,
   --#         OnEntryVariable from Dict,
   --#                              OriginalVariable,
   --#                              TheLoop;

   -- Provides access to variable created by previous call.
   function GetLoopOnEntryVariable (OriginalVariable : Symbol;
                                    TheLoop          : Symbol) return Symbol;
   --# global in Dict;

   procedure Add_Full_Range_Subtype
     (Name             : in     LexTokenManager.Lex_String;
      Parent           : in     Symbol;
      Parent_Reference : in     Location;
      Comp_Unit        : in     ContextManager.UnitDescriptors;
      Declaration      : in     Location;
      Scope            : in     Scopes;
      Context          : in     Contexts;
      The_Subtype      :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Subtype       from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Parent,
   --#                                Scope &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Parent,
   --#                                Parent_Reference,
   --#                                Scope;
   --# post IsTypeMark (The_Subtype, Dict);

   procedure Add_Enumeration_Subtype
     (Name             : in     LexTokenManager.Lex_String;
      Static           : in     Boolean;
      Parent           : in     Symbol;
      Parent_Reference : in     Location;
      Lower            : in     LexTokenManager.Lex_String;
      Upper            : in     LexTokenManager.Lex_String;
      Comp_Unit        : in     ContextManager.UnitDescriptors;
      Declaration      : in     Location;
      Scope            : in     Scopes;
      Context          : in     Contexts;
      The_Subtype      :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Subtype       from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Lower,
   --#                                Name,
   --#                                Parent,
   --#                                Scope,
   --#                                Static,
   --#                                Upper &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Parent,
   --#                                Parent_Reference,
   --#                                Scope;
   --# post IsTypeMark (The_Subtype, Dict);

   procedure Add_Integer_Subtype
     (Name             : in     LexTokenManager.Lex_String;
      Static           : in     Boolean;
      Parent           : in     Symbol;
      Parent_Reference : in     Location;
      Lower            : in     LexTokenManager.Lex_String;
      Upper            : in     LexTokenManager.Lex_String;
      Comp_Unit        : in     ContextManager.UnitDescriptors;
      Declaration      : in     Location;
      Scope            : in     Scopes;
      Context          : in     Contexts;
      The_Subtype      :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Subtype       from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Lower,
   --#                                Name,
   --#                                Parent,
   --#                                Scope,
   --#                                Static,
   --#                                Upper &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Parent,
   --#                                Parent_Reference,
   --#                                Scope;
   --# post IsTypeMark (The_Subtype, Dict);

   procedure Add_Modular_Subtype
     (Name             : in     LexTokenManager.Lex_String;
      Parent           : in     Symbol;
      Parent_Reference : in     Location;
      Lower            : in     LexTokenManager.Lex_String;
      Upper            : in     LexTokenManager.Lex_String;
      Comp_Unit        : in     ContextManager.UnitDescriptors;
      Declaration      : in     Location;
      Scope            : in     Scopes;
      Context          : in     Contexts;
      The_Subtype      :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Subtype       from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Lower,
   --#                                Name,
   --#                                Parent,
   --#                                Scope,
   --#                                Upper &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Parent,
   --#                                Parent_Reference,
   --#                                Scope;
   --# post IsTypeMark (The_Subtype, Dict);

   procedure Add_Floating_Point_Subtype
     (Name             : in     LexTokenManager.Lex_String;
      Static           : in     Boolean;
      Parent           : in     Symbol;
      Parent_Reference : in     Location;
      Lower            : in     LexTokenManager.Lex_String;
      Upper            : in     LexTokenManager.Lex_String;
      Error_Bound      : in     LexTokenManager.Lex_String;
      Comp_Unit        : in     ContextManager.UnitDescriptors;
      Declaration      : in     Location;
      Scope            : in     Scopes;
      Context          : in     Contexts;
      The_Subtype      :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Subtype       from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                Error_Bound,
   --#                                LexTokenManager.State,
   --#                                Lower,
   --#                                Name,
   --#                                Parent,
   --#                                Scope,
   --#                                Static,
   --#                                Upper &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Parent,
   --#                                Parent_Reference,
   --#                                Scope;
   --# post IsTypeMark (The_Subtype, Dict);

   procedure Add_Fixed_Point_Subtype
     (Name             : in     LexTokenManager.Lex_String;
      Static           : in     Boolean;
      Parent           : in     Symbol;
      Parent_Reference : in     Location;
      Lower            : in     LexTokenManager.Lex_String;
      Upper            : in     LexTokenManager.Lex_String;
      Error_Bound      : in     LexTokenManager.Lex_String;
      Comp_Unit        : in     ContextManager.UnitDescriptors;
      Declaration      : in     Location;
      Scope            : in     Scopes;
      Context          : in     Contexts;
      The_Subtype      :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Subtype       from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                Error_Bound,
   --#                                LexTokenManager.State,
   --#                                Lower,
   --#                                Name,
   --#                                Parent,
   --#                                Scope,
   --#                                Static,
   --#                                Upper &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Parent,
   --#                                Parent_Reference,
   --#                                Scope;
   --# post IsTypeMark (The_Subtype, Dict);

   -- Adds an array subtype that has a (possibly static) constraint. For example -
   -- addition of a constrained subtype of an unconstrained array type
   procedure Add_Array_Subtype
     (Name             : in     LexTokenManager.Lex_String;
      Parent           : in     Symbol;
      Parent_Reference : in     Location;
      Comp_Unit        : in     ContextManager.UnitDescriptors;
      Declaration      : in     Location;
      Scope            : in     Scopes;
      Context          : in     Contexts;
      Static           : in     Boolean;
      The_Subtype      :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         The_Subtype       from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Parent,
   --#                                Scope,
   --#                                Static &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Parent,
   --#                                Parent_Reference,
   --#                                Scope;
   --# post IsTypeMark (The_Subtype, Dict);

   procedure AddAssertStatement (Statement : in Location);
   --# global in     Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Dict,
   --#                                Statement;

   procedure AddCheckStatement (Statement : in Location);
   --# global in     Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Dict,
   --#                                Statement;

   procedure AddPrecondition
     (Abstraction  : in Abstractions;
      Subprogram   : in Symbol;
      Predicate    : in ExaminerConstants.RefType;
      Precondition : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Abstraction,
   --#                                Predicate,
   --#                                Subprogram &
   --#         SPARK_IO.File_Sys from *,
   --#                                Abstraction,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Precondition,
   --#                                Predicate,
   --#                                Subprogram;

   procedure AddPostcondition
     (Abstraction   : in Abstractions;
      Subprogram    : in Symbol;
      Predicate     : in ExaminerConstants.RefType;
      Postcondition : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Abstraction,
   --#                                Predicate,
   --#                                Subprogram &
   --#         SPARK_IO.File_Sys from *,
   --#                                Abstraction,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Postcondition,
   --#                                Predicate,
   --#                                Subprogram;

   procedure AddSubprogram
     (Name          : in     LexTokenManager.Lex_String;
      Comp_Unit     : in     ContextManager.UnitDescriptors;
      Specification : in     Location;
      Scope         : in     Scopes;
      Context       : in     Contexts;
      Subprogram    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         Subprogram        from Comp_Unit,
   --#                                Context,
   --#                                Dict,
   --#                                Name,
   --#                                Scope,
   --#                                Specification &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope,
   --#                                Specification;
   --# post IsSubprogram (Subprogram, Dict);

   function ActualOfGenericFormalType (TheGenericFormalSym : Symbol;
                                       ActualSubprogramSym : Symbol) return Symbol;
   --# global in Dict;
   --# return S => IsTypeMark (S, Dict);
   -- returns the symbol that is the generic actual that matches the given generic formal for a
   -- given instantiation

   function ActualOfGenericFormalObject (TheGenericFormalSym : Symbol;
                                         ActualSubprogramSym : Symbol) return Symbol;
   --# global in Dict;
   --# return S => IsConstant (S, Dict);
   -- returns the symbol that is the generic actual that matches the given generic formal for a
   -- given instantiation

   function ActualOfGenericParameter (TheParameter        : Symbol;
                                      ActualSubprogramSym : Symbol) return Symbol;
   --# global in Dict;
   --# return S => IsSubprogramParameter (S, Dict);
   -- returns the symbol of the actual parameter that has the same posiiton number in the instantiated
   -- subprogram as the parameter symbol  has in the generic from which it comes

   function ActualOfParameterConstraint (TheParameter        : Symbol;
                                         ActualSubprogramSym : Symbol) return Symbol;
   --# global in Dict;
   --# return S => IsParameterConstraint (S, Dict);

   procedure AddSubprogramInstantiation
     (Name          : in     LexTokenManager.Lex_String;
      Comp_Unit     : in     ContextManager.UnitDescriptors;
      Declaration   : in     Location;
      TheGeneric    : in     Symbol;
      Specification : in     Location;
      Scope         : in     Scopes;
      Context       : in     Contexts;
      Subprogram    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         Subprogram        from Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                Name,
   --#                                Scope,
   --#                                Specification,
   --#                                TheGeneric &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Context,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope,
   --#                                Specification,
   --#                                TheGeneric;
   --# post IsSubprogram (Subprogram, Dict);

   function IsInstantiation (PackageOrSubProgram : Symbol) return Boolean;
   --# global in Dict;

   function GetGenericOfInstantiation (PackageOrSubProgram : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsSubprogram (S, Dict));

   -- Copies the parameters and return types from Generic to Instantiation substituting
   -- actual types as it goes (using generic association linked list of Instantiation)
   procedure InstantiateSubprogramParameters
     (ActualSubprogramSym : in Symbol;
      Comp_Unit           : in ContextManager.UnitDescriptors;
      Declaration         : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                ActualSubprogramSym,
   --#                                Comp_Unit,
   --#                                Declaration &
   --#         SPARK_IO.File_Sys from *,
   --#                                ActualSubprogramSym,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State;

   procedure SetSubprogramSignatureNotWellformed (Abstraction : in Abstractions;
                                                  Subprogram  : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Abstraction,
   --#                   Subprogram;

   procedure SetSubprogramIsEntry (Subprogram : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Subprogram;

   procedure Set_Package_Generic_Unit (Pack_Sym     : in Symbol;
                                       Generic_Unit : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Generic_Unit,
   --#                   Pack_Sym;

   procedure Set_Subprogram_Generic_Unit (Subprogram   : in Symbol;
                                          Generic_Unit : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Generic_Unit,
   --#                   Subprogram;

   procedure Set_Generic_Unit_Owning_Package (Generic_Unit : in Symbol;
                                              Pack_Sym     : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Generic_Unit,
   --#                   Pack_Sym;

   procedure Set_Generic_Unit_Owning_Subprogram (Generic_Unit : in Symbol;
                                                 Subprogram   : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Generic_Unit,
   --#                   Subprogram;

   -- Call this to record the fact that a procedure or task has an explicit
   -- derives annotation.
   procedure SetHasDerivesAnnotation (Task_Or_Proc : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Task_Or_Proc;

   procedure SetSubprogramEntryBarrier (Subprogram, TheBarrier : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Subprogram,
   --#                   TheBarrier;

   procedure SetIsInterruptHandler (Subprogram : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Subprogram;

   procedure SetHasDelayProperty (TheProcedure : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TheProcedure;

   procedure SetUsesUnprotectedVariables (Sym : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Sym;

   procedure SetUnprotectedReference (Variable : in Symbol;
                                      ByThread : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   ByThread,
   --#                   Variable;

   procedure SetSuspendsReference (Variable : in Symbol;
                                   ByThread : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   ByThread,
   --#                   Variable;

   procedure SetVirtualElementSeenByOwner (TheVariable : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TheVariable;

   procedure SetPriorityProperty (OwnVariable : in Symbol;
                                  TheValue    : in LexTokenManager.Lex_String);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   OwnVariable,
   --#                   TheValue;

   procedure SetIntegrityProperty (OwnVariable : in Symbol;
                                   TheValue    : in LexTokenManager.Lex_String);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   OwnVariable,
   --#                   TheValue;

   procedure SetIsSuspendable (Variable : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Variable;

   procedure SetHasInterruptProperty (Variable : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Variable;

   procedure MarkAccountsForDelay (TheProcedure : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TheProcedure;

   procedure MarkAccountsForSuspendsListItem (TheTaskOrProc : in Symbol;
                                              ThePOorSO     : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   ThePOorSO,
   --#                   TheTaskOrProc;

   procedure MarkAccountsForSuspendsListItems (TheTaskOrProc       : in Symbol;
                                               TheItemsInProcedure : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TheItemsInProcedure,
   --#                   TheTaskOrProc;

   procedure SetProtectedTypeElementsHidden (TheProtectedType : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TheProtectedType;

   procedure SetProtectedTypeEntry (TheProtectedType, TheEntry : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TheEntry,
   --#                   TheProtectedType;

   procedure SetTypeHasPragma (TheProtectedOrTaskType : in Symbol;
                               ThePragma              : in RavenscarPragmas);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   ThePragma,
   --#                   TheProtectedOrTaskType;

   procedure SetTypePragmaValue
     (TheProtectedOrTaskType : in Symbol;
      ThePragma              : in RavenscarPragmasWithValue;
      TheValue               : in LexTokenManager.Lex_String);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   ThePragma,
   --#                   TheProtectedOrTaskType,
   --#                   TheValue;

   procedure SetMainProgramPriority (TheValue : in LexTokenManager.Lex_String);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TheValue;

   procedure AddReturnType
     (TheFunction   : in Symbol;
      TypeMark      : in Symbol;
      Comp_Unit     : in ContextManager.UnitDescriptors;
      TypeReference : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                TheFunction,
   --#                                TypeMark,
   --#                                TypeReference &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                TheFunction,
   --#                                TypeMark,
   --#                                TypeReference;

   procedure AddImplicitReturnVariable
     (Abstraction : in     Abstractions;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Name        : in     LexTokenManager.Lex_String;
      TheFunction : in     Symbol;
      Variable    :    out Symbol);
   --# global in out Dict;
   --# derives Dict,
   --#         Variable from Abstraction,
   --#                       Comp_Unit,
   --#                       Declaration,
   --#                       Dict,
   --#                       Name,
   --#                       TheFunction;
   --# post IsImplicitReturnVariable (Variable, Dict);

   procedure AddSubprogramParameter
     (Name          : in LexTokenManager.Lex_String;
      Subprogram    : in Symbol;
      TypeMark      : in Symbol;
      TypeReference : in Location;
      Mode          : in Modes;
      Comp_Unit     : in ContextManager.UnitDescriptors;
      Specification : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                Mode,
   --#                                Name,
   --#                                Specification,
   --#                                Subprogram,
   --#                                TypeMark &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Mode,
   --#                                Name,
   --#                                Specification,
   --#                                Subprogram,
   --#                                TypeMark,
   --#                                TypeReference;

   procedure Add_Generic_Formal_Parameter
     (Comp_Unit    : in ContextManager.UnitDescriptors;
      Declaration  : in Location;
      Generic_Unit : in Symbol;
      The_Type     : in Symbol;
      The_Object   : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Comp_Unit,
   --#                   Declaration,
   --#                   Generic_Unit,
   --#                   The_Object,
   --#                   The_Type;

   procedure AddGenericTypeAssociation
     (SubprogramOrPackage : in Symbol;
      Comp_Unit           : in ContextManager.UnitDescriptors;
      Declaration         : in Location;
      FormalSym           : in Symbol;
      ActualSym           : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   ActualSym,
   --#                   Comp_Unit,
   --#                   Declaration,
   --#                   FormalSym,
   --#                   SubprogramOrPackage;

   procedure AddGenericObjectAssociation
     (SubprogramOrPackage : in Symbol;
      Comp_Unit           : in ContextManager.UnitDescriptors;
      Declaration         : in Location;
      FormalSym           : in Symbol;
      ActualSym           : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   ActualSym,
   --#                   Comp_Unit,
   --#                   Declaration,
   --#                   FormalSym,
   --#                   SubprogramOrPackage;

   procedure AddKnownDiscriminant
     (Name                : in LexTokenManager.Lex_String;
      Comp_Unit           : in ContextManager.UnitDescriptors;
      Declaration         : in Location;
      ProtectedOrTaskType : in Symbol;
      TypeMark            : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Comp_Unit,
   --#                   Declaration,
   --#                   Name,
   --#                   ProtectedOrTaskType,
   --#                   TypeMark;

   procedure SetDiscriminantSetsPriority (TheDiscriminant : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TheDiscriminant;

   procedure AddDiscriminantConstraintStaticValue
     (ProtectedOrTaskSubtype : in Symbol;
      Comp_Unit              : in ContextManager.UnitDescriptors;
      Declaration            : in Location;
      TheValue               : in LexTokenManager.Lex_String);

   --# global in out Dict;
   --# derives Dict from *,
   --#                   Comp_Unit,
   --#                   Declaration,
   --#                   ProtectedOrTaskSubtype,
   --#                   TheValue;

   procedure AddDiscriminantConstraintAccessedObject
     (ProtectedOrTaskSubtype : in Symbol;
      Comp_Unit              : in ContextManager.UnitDescriptors;
      Declaration            : in Location;
      TheObject              : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Comp_Unit,
   --#                   Declaration,
   --#                   ProtectedOrTaskSubtype,
   --#                   TheObject;

   procedure SetSubtypePriority (ProtectedOrTaskSubtype : in Symbol;
                                 ThePriority            : in LexTokenManager.Lex_String);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   ProtectedOrTaskSubtype,
   --#                   ThePriority;

   procedure AddBody
     (CompilationUnit : in Symbol;
      Comp_Unit       : in ContextManager.UnitDescriptors;
      TheBody         : in Location;
      Hidden          : in Boolean);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                CompilationUnit,
   --#                                Comp_Unit,
   --#                                Hidden,
   --#                                TheBody &
   --#         SPARK_IO.File_Sys from *,
   --#                                CompilationUnit,
   --#                                Comp_Unit,
   --#                                Dict,
   --#                                Hidden,
   --#                                LexTokenManager.State,
   --#                                TheBody;

   procedure AddBodyStub (CompilationUnit : in Symbol;
                          Comp_Unit       : in ContextManager.UnitDescriptors;
                          BodyStub        : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                BodyStub,
   --#                                CompilationUnit,
   --#                                Comp_Unit &
   --#         SPARK_IO.File_Sys from *,
   --#                                BodyStub,
   --#                                CompilationUnit,
   --#                                Comp_Unit,
   --#                                Dict,
   --#                                LexTokenManager.State;

   procedure AddMainProgram (Subprogram : in Symbol;
                             Annotation : in Location);
   --# global in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Subprogram &
   --#         SPARK_IO.File_Sys from *,
   --#                                Annotation,
   --#                                Dict,
   --#                                Subprogram;

   procedure AddDependencyRelation (Abstraction        : in Abstractions;
                                    TheProcedure       : in Symbol;
                                    DependencyRelation : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Abstraction,
   --#                                TheProcedure &
   --#         SPARK_IO.File_Sys from *,
   --#                                Abstraction,
   --#                                DependencyRelation,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                TheProcedure;

   procedure RenameSubprogram
     (Subprogram          : in Symbol;
      SubprogramReference : in Location;
      Comp_Unit           : in ContextManager.UnitDescriptors;
      Declaration         : in Location;
      Scope               : in Scopes);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Scope,
   --#                                Subprogram &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Scope,
   --#                                Subprogram,
   --#                                SubprogramReference;

   procedure RenameUnaryOperator
     (Name        : in     SP_Symbols.SP_Symbol;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Operand     : in     Symbol;
      Scope       : in     Scopes;
      Op_Sym      :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         Op_Sym            from Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Name,
   --#                                Operand,
   --#                                Scope &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Operand,
   --#                                Scope;
   --# post IsOperator (Op_Sym, Dict);

   procedure RenameBinaryOperator
     (Name        : in     SP_Symbols.SP_Symbol;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      Left        : in     Symbol;
      Right       : in     Symbol;
      Scope       : in     Scopes;
      Op_Sym      :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         Op_Sym            from Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Left,
   --#                                Name,
   --#                                Right,
   --#                                Scope &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Left,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Right,
   --#                                Scope;
   --# post IsOperator (Op_Sym, Dict);

   procedure AddGlobalAnnotation
     (Abstraction : in Abstractions;
      Subprogram  : in Symbol;
      Comp_Unit   : in ContextManager.UnitDescriptors;
      Annotation  : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Abstraction,
   --#                                Annotation,
   --#                                Comp_Unit,
   --#                                Subprogram &
   --#         SPARK_IO.File_Sys from *,
   --#                                Abstraction,
   --#                                Annotation,
   --#                                Comp_Unit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Subprogram;

   procedure AddGlobalVariable
     (Abstraction         : in     Abstractions;
      Subprogram          : in     Symbol;
      Variable            : in     Symbol;
      Mode                : in     Modes;
      PrefixNeeded        : in     Boolean;
      Comp_Unit           : in     ContextManager.UnitDescriptors;
      VariableReference   : in     Location;
      Global_Variable_Sym :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         Global_Variable_Sym from Abstraction,
   --#                                  Comp_Unit,
   --#                                  Dict,
   --#                                  Mode,
   --#                                  PrefixNeeded,
   --#                                  Subprogram,
   --#                                  Variable,
   --#                                  VariableReference &
   --#         SPARK_IO.File_Sys   from *,
   --#                                  Abstraction,
   --#                                  Comp_Unit,
   --#                                  Dict,
   --#                                  LexTokenManager.State,
   --#                                  Mode,
   --#                                  PrefixNeeded,
   --#                                  Subprogram,
   --#                                  Variable,
   --#                                  VariableReference;
   --# post IsGlobalVariable (Global_Variable_Sym, Dict);

   procedure AddExport
     (Abstraction     : in Abstractions;
      TheProcedure    : in Symbol;
      TheExport       : in Symbol;
      ExportReference : in Location;
      Annotation      : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Abstraction,
   --#                                TheExport,
   --#                                TheProcedure &
   --#         SPARK_IO.File_Sys from *,
   --#                                Abstraction,
   --#                                Annotation,
   --#                                Dict,
   --#                                ExportReference,
   --#                                LexTokenManager.State,
   --#                                TheExport,
   --#                                TheProcedure;

   procedure AddDependency
     (Abstraction     : in Abstractions;
      Comp_Unit       : in ContextManager.UnitDescriptors;
      TheProcedure    : in Symbol;
      TheExport       : in Symbol;
      TheImport       : in Symbol;
      ImportReference : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Abstraction,
   --#                                Comp_Unit,
   --#                                ImportReference,
   --#                                TheExport,
   --#                                TheImport,
   --#                                TheProcedure &
   --#         SPARK_IO.File_Sys from *,
   --#                                Abstraction,
   --#                                Comp_Unit,
   --#                                Dict,
   --#                                ImportReference,
   --#                                LexTokenManager.State,
   --#                                TheExport,
   --#                                TheImport,
   --#                                TheProcedure;

   procedure AddVirtualElement
     (ToProtectedType   : in Symbol;
      Comp_Unit         : in ContextManager.UnitDescriptors;
      Declaration       : in Location;
      TheVirtualElement : in Symbol;
      TheOwner          : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Comp_Unit,
   --#                   Declaration,
   --#                   TheOwner,
   --#                   TheVirtualElement,
   --#                   ToProtectedType;

   procedure AddPOorSOToSuspendsList
     (TheTaskOrProc : in Symbol;
      Comp_Unit     : in ContextManager.UnitDescriptors;
      Declaration   : in Location;
      ThePOorSO     : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Comp_Unit,
   --#                   Declaration,
   --#                   ThePOorSO,
   --#                   TheTaskOrProc;

   procedure AddInterruptStreamMapping
     (Subject             : in Symbol;
      Comp_Unit           : in ContextManager.UnitDescriptors;
      Declaration         : in Location;
      TheInterruptHandler : in LexTokenManager.Lex_String;
      TheInterruptStream  : in LexTokenManager.Lex_String);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Comp_Unit,
   --#                   Declaration,
   --#                   Subject,
   --#                   TheInterruptHandler,
   --#                   TheInterruptStream;

   procedure CopyDependencyList
     (Abstraction  : in Abstractions;
      TheProcedure : in Symbol;
      FromExport   : in Symbol;
      ToExport     : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Abstraction,
   --#                   FromExport,
   --#                   TheProcedure,
   --#                   ToExport;

   procedure ForceImport
     (Abstraction     : in Abstractions;
      TheProcedure    : in Symbol;
      TheImport       : in Symbol;
      ImportReference : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Abstraction,
   --#                                TheImport,
   --#                                TheProcedure &
   --#         SPARK_IO.File_Sys from *,
   --#                                Abstraction,
   --#                                Dict,
   --#                                ImportReference,
   --#                                LexTokenManager.State,
   --#                                TheImport,
   --#                                TheProcedure;

   procedure Add_Package
     (Name          : in     LexTokenManager.Lex_String;
      Comp_Unit     : in     ContextManager.UnitDescriptors;
      Specification : in     Location;
      Scope         : in     Scopes;
      ThePackage    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope,
   --#                                Specification &
   --#         ThePackage        from Comp_Unit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope,
   --#                                Specification;
   --# post IsPackage (ThePackage, Dict);

   procedure AddChildPackage
     (TheParent     : in     Symbol;
      Sort          : in     PackageSort;
      Name          : in     LexTokenManager.Lex_String;
      Comp_Unit     : in     ContextManager.UnitDescriptors;
      Specification : in     Location;
      Scope         : in     Scopes;
      ThePackage    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope,
   --#                                Sort,
   --#                                Specification,
   --#                                TheParent &
   --#         ThePackage        from Comp_Unit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope,
   --#                                Sort,
   --#                                Specification,
   --#                                TheParent;
   --# post IsPackage (ThePackage, Dict);

   procedure AddPrivatePackage
     (Name          : in     LexTokenManager.Lex_String;
      Comp_Unit     : in     ContextManager.UnitDescriptors;
      Specification : in     Location;
      Scope         : in     Scopes;
      ThePackage    :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope,
   --#                                Specification &
   --#         ThePackage        from Comp_Unit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Scope,
   --#                                Specification;
   --# post IsPackage (ThePackage, Dict);

   procedure AddPrivatePart (ThePackage  : in Symbol;
                             PrivatePart : in Location;
                             Hidden      : in Boolean);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Dict,
   --#                                Hidden,
   --#                                LexTokenManager.State,
   --#                                PrivatePart,
   --#                                ThePackage;

   procedure AddOwnAnnotation (ThePackage : in Symbol;
                               Annotation : in Location);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Annotation,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                ThePackage;

   procedure Add_Own_Variable
     (Name                : in     LexTokenManager.Lex_String;
      The_Package         : in     Symbol;
      Mode                : in     Modes;
      Is_Protected        : in     Boolean;
      Is_Interrupt_Stream : in     Boolean;
      Comp_Unit           : in     ContextManager.UnitDescriptors;
      Declaration         : in     Location;
      Var_Symbol          :    out Symbol);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict,
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Is_Interrupt_Stream,
   --#                                Is_Protected,
   --#                                LexTokenManager.State,
   --#                                Mode,
   --#                                Name,
   --#                                The_Package &
   --#         Var_Symbol        from Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Is_Interrupt_Stream,
   --#                                Is_Protected,
   --#                                LexTokenManager.State,
   --#                                Mode,
   --#                                Name,
   --#                                The_Package;
   --# post IsVariable (Var_Symbol, Dict);

   procedure AddOwnVariableType (OwnVariable   : in Symbol;
                                 TypeMark      : in Symbol;
                                 TypeReference : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                OwnVariable,
   --#                                TypeMark &
   --#         SPARK_IO.File_Sys from *,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                OwnVariable,
   --#                                TypeMark,
   --#                                TypeReference;

   procedure AddOwnTask
     (Name        : in     LexTokenManager.Lex_String;
      Comp_Unit   : in     ContextManager.UnitDescriptors;
      Declaration : in     Location;
      TypeMark    : in     Symbol;
      ThePackage  : in     Symbol;
      TaskSym     :    out Symbol);
   --# global in out Dict;
   --# derives Dict,
   --#         TaskSym from Comp_Unit,
   --#                      Declaration,
   --#                      Dict,
   --#                      Name,
   --#                      ThePackage,
   --#                      TypeMark;
   --# post IsVariable (TaskSym, Dict);

   procedure AddRefinementDefinition (ThePackage : in Symbol;
                                      Annotation : in Location);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Annotation,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                ThePackage;

   procedure AddConstituent
     (Name                 : in LexTokenManager.Lex_String;
      Subject              : in Symbol;
      Mode                 : in Modes;
      SubjectReference     : in Location;
      Comp_Unit            : in ContextManager.UnitDescriptors;
      ConstituentReference : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                ConstituentReference,
   --#                                Mode,
   --#                                Name,
   --#                                Subject &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                ConstituentReference,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Name,
   --#                                Subject,
   --#                                SubjectReference;

   procedure AddConstituentSym
     (ConstituentVariable  : in Symbol;
      Subject              : in Symbol;
      Comp_Unit            : in ContextManager.UnitDescriptors;
      ConstituentReference : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                ConstituentReference,
   --#                                ConstituentVariable,
   --#                                Subject &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                ConstituentReference,
   --#                                ConstituentVariable,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Subject;

   procedure AddEmbeddedConstituent
     (PackageName          : in LexTokenManager.Lex_String;
      VariableName         : in LexTokenManager.Lex_String;
      Subject              : in Symbol;
      Mode                 : in Modes;
      SubjectReference     : in Location;
      Comp_Unit            : in ContextManager.UnitDescriptors;
      ConstituentReference : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                ConstituentReference,
   --#                                LexTokenManager.State,
   --#                                Mode,
   --#                                PackageName,
   --#                                Subject,
   --#                                VariableName &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                ConstituentReference,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                PackageName,
   --#                                Subject,
   --#                                SubjectReference,
   --#                                VariableName;

   procedure AddChildConstituent
     (Variable             : in Symbol;
      Subject              : in Symbol;
      Mode                 : in Modes;
      SubjectReference     : in Location;
      Comp_Unit            : in ContextManager.UnitDescriptors;
      ConstituentReference : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                ConstituentReference,
   --#                                Mode,
   --#                                Subject,
   --#                                Variable &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                ConstituentReference,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Subject,
   --#                                SubjectReference,
   --#                                Variable;

   procedure AddInitializationSpecification (ThePackage : in Symbol;
                                             Annotation : in Location);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Annotation,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                ThePackage;

   procedure AddInitializedOwnVariable (Variable          : in Symbol;
                                        VariableReference : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Variable &
   --#         SPARK_IO.File_Sys from *,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Variable,
   --#                                VariableReference;

   procedure AddPackageInitialization (ThePackage     : in Symbol;
                                       Initialization : in Location;
                                       Hidden         : in Boolean);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Dict,
   --#                                Hidden,
   --#                                Initialization,
   --#                                LexTokenManager.State,
   --#                                ThePackage;

   procedure AddWithReference
     (The_Visibility    : in     Visibility;
      The_Unit          : in     Symbol;
      The_Withed_Symbol : in     Symbol;
      Explicit          : in     Boolean;
      Comp_Unit         : in     ContextManager.UnitDescriptors;
      Declaration       : in     Location;
      Already_Present   :    out Boolean);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Already_Present   from Dict,
   --#                                Explicit,
   --#                                The_Unit,
   --#                                The_Visibility,
   --#                                The_Withed_Symbol &
   --#         Dict              from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Explicit,
   --#                                The_Unit,
   --#                                The_Visibility,
   --#                                The_Withed_Symbol &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Explicit,
   --#                                LexTokenManager.State,
   --#                                The_Unit,
   --#                                The_Visibility,
   --#                                The_Withed_Symbol;

   procedure AddUseTypeReference
     (The_Visibility : in Visibility;
      The_Unit       : in Symbol;
      TheType        : in Symbol;
      Comp_Unit      : in ContextManager.UnitDescriptors;
      Declaration    : in Location);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Dict              from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                TheType,
   --#                                The_Unit,
   --#                                The_Visibility &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                TheType,
   --#                                The_Unit,
   --#                                The_Visibility;

   procedure AddInheritsReference
     (The_Unit             : in     Symbol;
      The_Inherited_Symbol : in     Symbol;
      Explicit             : in     Boolean;
      Comp_Unit            : in     ContextManager.UnitDescriptors;
      Declaration          : in     Location;
      Already_Present      :    out Boolean);
   --# global in     LexTokenManager.State;
   --#        in out Dict;
   --#        in out SPARK_IO.File_Sys;
   --# derives Already_Present   from Dict,
   --#                                Explicit,
   --#                                The_Inherited_Symbol,
   --#                                The_Unit &
   --#         Dict              from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Explicit,
   --#                                The_Inherited_Symbol,
   --#                                The_Unit &
   --#         SPARK_IO.File_Sys from *,
   --#                                Comp_Unit,
   --#                                Declaration,
   --#                                Dict,
   --#                                Explicit,
   --#                                LexTokenManager.State,
   --#                                The_Inherited_Symbol,
   --#                                The_Unit;

   procedure SetPackageElaborateBodyFound (ThePackage : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   ThePackage;

   procedure SetPackageAsExtendingAnother (ThePackage          : in Symbol;
                                           ThePackageItExtends : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   ThePackage,
   --#                   ThePackageItExtends;

   procedure AddWriteReference (Variable, CompilationUnit : in Symbol;
                                Reference                 : in Location);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                CompilationUnit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Reference,
   --#                                Variable;

   procedure AddReadReference (Object, CompilationUnit : in Symbol;
                               Reference               : in Location);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                CompilationUnit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Object,
   --#                                Reference;

   procedure AddSubprogramCall (Subprogram, CompilationUnit : in Symbol;
                                Call                        : in Location);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                Call,
   --#                                CompilationUnit,
   --#                                Dict,
   --#                                LexTokenManager.State,
   --#                                Subprogram;

   procedure AddOtherReference (Item, CompilationUnit : in Symbol;
                                Reference             : in Location);
   --# global in     Dict;
   --#        in     LexTokenManager.State;
   --#        in out SPARK_IO.File_Sys;
   --# derives SPARK_IO.File_Sys from *,
   --#                                CompilationUnit,
   --#                                Dict,
   --#                                Item,
   --#                                LexTokenManager.State,
   --#                                Reference;

   procedure AddUsesUncheckedConversion (TheUnit : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TheUnit;

   procedure AddAssignsFromExternal (TheUnit : in Symbol);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   TheUnit;

   --------------------------------------------------------------------------------
   --                             ACCESS FUNCTIONS                               --
   --------------------------------------------------------------------------------

   function SymbolRef (Item : Symbol) return ExaminerConstants.RefType;

   function ConvertSymbolRef (Ref : ExaminerConstants.RefType) return Symbol;

   function GetSimpleName (Item : Symbol) return LexTokenManager.Lex_String;
   --# global in Dict;

   function GetType (TheSymbol : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function Get_Unconstrained_Array_Index (TheSymbol : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsParameterConstraint (S, Dict));

   -- There is no need for a GetUnaryOperatorType function since the result type
   -- of every SPARK unary operator is the same as the operand type

   function GetAccess (TheProtectedType : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetScalarAttributeType (Name     : LexTokenManager.Lex_String;
                                    TypeMark : Symbol) return Symbol;
   --# global in Dict;
   --#        in LexTokenManager.State;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetArrayAttributeType
     (Name      : LexTokenManager.Lex_String;
      TypeMark  : Symbol;
      Dimension : Positive)
     return      Symbol;
   --# global in Dict;
   --#        in LexTokenManager.State;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetScalarAttributeValue
     (Base     : Boolean;
      Name     : LexTokenManager.Lex_String;
      TypeMark : Symbol)
     return     LexTokenManager.Lex_String;
   --# global in Dict;
   --#        in LexTokenManager.State;

   function GetArrayAttributeValue
     (Name      : LexTokenManager.Lex_String;
      TypeMark  : Symbol;
      Dimension : Positive)
     return      LexTokenManager.Lex_String;
   --# global in Dict;
   --#        in LexTokenManager.State;

   function GetEnumerationLiteral (EnumerationType : Symbol;
                                   Position        : LexTokenManager.Lex_String) return Symbol;
   --# global in Dict;
   --#        in LexTokenManager.State;

   function GetPositionNumber (Literal : Symbol) return LexTokenManager.Lex_String;
   --# global in Dict;

   function GetRecordType (Component : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   -- Predefined types -------------------------------------------------------------

   function GetUnknownTypeMark return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetUniversalIntegerType return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetUniversalRealType return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetUniversalFixedType return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function IsUniversalFixedType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function GetPredefinedBooleanType return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function IsPredefinedBooleanType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   -- The NullVariable is an out stream used as a data sink for null derives etc.
   function GetNullVariable return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsVariable (S, Dict));

   function Is_Null_Variable (TheVariable : Symbol) return Boolean;
   --# global in Dict;

   -- ThePartition is a subprogram symbol (predefined when Ravenscar profile is selected)
   -- that is used as place with which to associate the partition annotation.
   function GetThePartition return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsSubprogram (S, Dict));

   function GetFalse return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsEnumerationLiteral (S, Dict));

   function GetTrue return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsEnumerationLiteral (S, Dict));

   function GetPredefinedIntegerType return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetPredefinedLongIntegerType return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetPredefinedCharacterType return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetPredefinedStringType return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetPredefinedNaturalSubtype return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetPredefinedPositiveSubtype return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetPredefinedTimeType return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function IsPredefinedTimeSpanType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   -- Note: following function is to with getting the true base type
   --       of a type which is derived (from say root_integer).
   --       Use GetRootType to get the "first named subtype" of a subtype
   function GetBaseType (TypeMark : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetRootOfExtendedType (TypeMark : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));
   -- Applies to types extended from tagged types.  Gives the immediately

   -- Returns the type at the root of the "Parent" relation between
   -- subtypes and types.
   --
   -- For signed integer and floating point (sub)types,
   -- the root type is the first subtype of the
   -- anonymous type chosen by the compiler when a signed integer
   -- or floating point type is declared.  For example:
   --  type T is range 1 .. 10;
   --  subtype S is T range 2 .. 8;
   -- then
   --  GetRootType (T) = T -- identity
   --  GetRootType (S) = T
   --
   -- For array and record subtypes:
   --  type A is array (...) of ... ; -- full type declaration
   --  subtype A2 is A;
   -- then
   --  GetRootType (A) = A -- identity
   --  GetRootType (A2) = A
   function GetRootType (TypeMark : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   -- Returns the number of Dimensions of the given array
   -- type or subtype. GetRootType (see above) is
   -- used to step over any subtypes until the full
   -- parent type is found.
   function GetNumberOfDimensions (TypeMark : Symbol) return Positive;
   --# global in Dict;

   -- Returns the index type of the given Dimension for the given array
   -- type or subtype.  In the case of a full-range array subtype, the index
   -- type is obtained from the first constrained subtype.
   function GetArrayIndex (TypeMark  : Symbol;
                           Dimension : Positive) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetArrayComponent (TypeMark : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetNumberOfNonExtendedComponents (TheRecordType : Symbol) return Natural;
   --# global in Dict;
   -- Returns the number of record components in a record but does nor traverse a group of
   -- records modelling an extended tagged record.  The count includes the Inherit field of
   -- an extended record.

   function GetNumberOfActualComponents (TheRecordType : Symbol) return Natural;
   --# global in Dict;
   -- As above but ignore Inherit fields of extended tagged records

   function GetNumberOfComponents (TheRecordType : Symbol) return Natural;
   --# global in Dict;
   -- if the type is extended we get all the fields whether locally declared
   -- or inherited

   function GetNonExtendedRecordComponent (TheRecordType : Symbol;
                                           Number        : Positive) return Symbol;
   --# global in Dict;
   -- Returns field N of a single record (i.e ignores structured composition of records used to
   -- model tagged extended records.  If record is an extension, it cann return the "Inherit" field

   function GetRecordComponent (TheRecordType : Symbol;
                                Number        : Positive) return Symbol;
   --# global in Dict;
   -- Works for extended records as well as non-extended ones; does not ever return Inherit fields

   function GetInheritDepth (FieldName  : LexTokenManager.Lex_String;
                             RecordType : Symbol) return Natural;
   --# global in Dict;
   --#        in LexTokenManager.State;
   -- Assuming we have used LookUpSelectedItem and established that there is a field
   -- called FieldName in record RecordType we can use this function to find out
   -- how far FieldName is down a chain of inherit-from-root-type pointers.  So if
   -- R.F directly exists we return 0, and if R.F actually represents R.Inherit.F then we get
   -- 1 and so on

   function RecordComponentIsInherited (TheComponent : Symbol) return Boolean;
   --# global in Dict;
   -- returns true for extended types where a field is inherited rather than
   -- explicitly declared

   function GetVariableExpNode (Variable : Symbol) return ExaminerConstants.RefType;
   --# global in Dict;

   function GetConstantExpNode (TheConstant : Symbol) return ExaminerConstants.RefType;
   --# global in Dict;

   function ConstantExpIsWellformed (TheConstant : Symbol) return Boolean;
   --# global in Dict;

   function Get_Value (The_Constant : Symbol) return LexTokenManager.Lex_String;
   --# global in Dict;

   function GetConstantRulePolicy (TheConstant : Symbol;
                                   TheScope    : Scopes) return Rule_Policies;
   --# global in Dict;

   function IsConstantRulePolicyPresent (TheConstant : Symbol;
                                         TheScope    : Scopes) return Boolean;
   --# global in Dict;

   function TypeIsWellformed (TheType : Symbol) return Boolean;
   --# global in Dict;

   function GetPredefinedPackageStandard return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsPackage (S, Dict));

   function IsPredefinedPackageStandard (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function GetPredefinedPackageASCII return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsPackage (S, Dict));

   function GetOwner (Variable : Symbol) return Symbol;
   --# global in Dict;

   function LastMostEnclosingLoop (CompilationUnit : Symbol) return Symbol;
   --# global in Dict;

   function GetLoop (CompilationUnit : Symbol;
                     Number          : Positive) return Symbol;
   --# global in Dict;

   function GetLoopParameter (TheLoop : Symbol) return Symbol;
   --# global in Dict;

   -- Returns a Cells.Cell previously planted by the VCG and representing
   -- the exit expression of a for loop
   function GetLoopExitExpn (TheLoop : Symbol) return Natural;
   --# global in Dict;

   -- Returns a Cells.Cell previously planted by the VCG and representing
   -- the entry expression of a for loop
   function GetLoopEntryExpn (TheLoop : Symbol) return Natural;
   --# global in Dict;

   function GetLoopHasExits (TheLoop : Symbol) return Boolean;
   --# global in Dict;

   function LoopParameterHasStaticRange (TheLoopParameter : Symbol) return Boolean;
   --# global in Dict;

   function LoopParameterMovesInReverse (TheLoopParameter : Symbol) return Boolean;
   --# global in Dict;

   function GetScope (Item : Symbol) return Scopes;
   --# global in Dict;

   function GetEnclosingScope (Scope : Scopes) return Scopes;
   --# global in Dict;

   function GetEnclosingPackage (Scope : Scopes) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsPackage (S, Dict));

   function GetEnclosingProtectedRegion (Scope : Scopes) return Symbol;
   --# global in Dict;

   function IsOrIsInProtectedScope (Scope : Scopes) return Boolean;
   --# global in Dict;

   function SubprogramSignatureIsWellformed (Abstraction : Abstractions;
                                             Subprogram  : Symbol) return Boolean;
   --# global in Dict;

   function HasPrecondition (Abstraction : Abstractions;
                             Subprogram  : Symbol) return Boolean;
   --# global in Dict;
   -- NOTE: a task type is allowed but always returns False since tasks don't have preconditions

   function GetPrecondition (Abstraction : Abstractions;
                             Subprogram  : Symbol) return ExaminerConstants.RefType;
   --# global in Dict;
   -- NOTE: a task type is allowed but always returns 0 since tasks don't have preconditions

   function HasPostcondition (Abstraction : Abstractions;
                              Subprogram  : Symbol) return Boolean;
   --# global in Dict;

   function GetPostcondition (Abstraction : Abstractions;
                              Subprogram  : Symbol) return ExaminerConstants.RefType;
   --# global in Dict;

   function HasImplicitReturnVariable (Abstraction : Abstractions;
                                       TheFunction : Symbol) return Boolean;
   --# global in Dict;

   function GetImplicitReturnVariable (Abstraction : Abstractions;
                                       TheFunction : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsImplicitReturnVariable (S, Dict));

   function GetAdaFunction (ProofFunction : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsSubprogram (S, Dict));

   function GetImplicitProofFunction (Abstraction : Abstractions;
                                      TheFunction : Symbol) return Symbol;
   --# global in Dict;

   function GetSubprogramParameterNumber (Parameter : Symbol) return Positive;
   --# global in Dict;

   function GetSubprogramParameterMode (Parameter : Symbol) return Modes;
   --# global in Dict;

   function GetSubprogramParameterConstraint (Parameter : Symbol;
                                              Dimension : Positive) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsParameterConstraint (S, Dict));
   -- Returns the symbol for x__index_subtype__n where x is the paraeter and n the dimension number. This is
   -- a symbol with discriminant ParameterConstraintSymbol and which is used to pass information about
   -- unconstrained parameters between the wffs and the VCG.  Pseudo annotation describes normal behaviour; an
   -- illegal SPARK program might result in calls being made which violate the "precondition", in which case
   -- the unknown type mark is returned.

   function GetSubprogramParameterConstraintDimension (TheConstraint : Symbol) return Positive;
   --# global in Dict;

   function GetParameterAssociatedWithParameterConstraint (TheConstraint : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsSubprogramParameter (S, Dict));

   function GetNumberOfSubprogramParameters (Subprogram : Symbol) return Natural;
   --# global in Dict;

   function GetSubprogramParameter (Subprogram : Symbol;
                                    Number     : Positive) return Symbol;
   --# global in Dict;

   function GetNumberOfGlobalVariables (Abstraction : Abstractions;
                                        Subprogram  : Symbol) return Natural;
   --# global in Dict;

   function GetGlobalMode
     (Abstraction : Abstractions;
      Subprogram  : Symbol;
      Variable    : Symbol)
     return        Modes;
   --# global in Dict;

   function GetOwnVariableMode (Variable : Symbol) return Modes;
   --# global in Dict;

   function GetOwnVariableProtected (Variable : Symbol) return Boolean;
   --# global in Dict;

   function GetOwnVariableIsInterruptStream (Variable : Symbol) return Boolean;
   --# global in Dict;

   function GetOwnVariableTypeHere (OwnVariable : in Symbol;
                                    Scope       : in Scopes) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsTypeMark (S, Dict));

   function GetConstituentMode (Variable : Symbol) return Modes;
   --# global in Dict;

   function IsOwnVariableOrConstituentWithMode (Variable : Symbol) return Boolean;
   --# global in Dict;

   function GetProtectedTypeOwnVariable (TheProtectedType : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsVariable (S, Dict));
   --  return "the implicitly-declared abstract own variable that belongs to the PT"

   function IsUnmodedProtectedOwnVariable (Sym : Symbol) return Boolean;
   --# global in Dict;

   function GetProtectedImplicitInStream (TheProtectedOwnVar : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsImplicitInStream (S, Dict));
   -- Failure to observe precondtion will result in a null symbol being returned or dict crash.

   function GetProtectedTypeHasEntry (TheProtectedType : Symbol) return Boolean;
   --# global in Dict;

   function GetTypeHasPragma (TheProtectedOrTaskType : in Symbol;
                              ThePragma              : in RavenscarPragmas) return Boolean;
   --# global in Dict;

   function GetTypePragmaValue
     (TheProtectedOrTaskType : in Symbol;
      ThePragma              : in RavenscarPragmasWithValue)
     return                   LexTokenManager.Lex_String;
   --# global in Dict;

   function GetTypePriority (TheProtectedOrTaskType : in Symbol) return LexTokenManager.Lex_String;
   --# global in Dict;

   function GetPriorityProperty (OwnVariable : in Symbol) return LexTokenManager.Lex_String;
   --# global in Dict;

   -- If IsOwnVariable (S), then returns the Integrity of that
   -- own var (which could be of a library package, nested package,
   -- or private child package.) Otherwise, returns Null_String.
   function GetIntegrityProperty (S : in Symbol) return LexTokenManager.Lex_String;
   --# global in Dict;

   -- Implements information flow policy checking based on the Integrity
   -- property of the given import and export symbol.  CommandLineData is
   -- used to determine which info flow policy (if any) if being checked.
   function RelationViolatesInfoFlowPolicy (TheExport : in Symbol;
                                            TheImport : in Symbol) return Boolean;
   --# global in CommandLineData.Content;
   --#        in Dict;
   --#        in LexTokenManager.State;

   function GetIsSuspendable (Variable : in Symbol) return Boolean;
   --# global in Dict;

   function GetHasInterruptProperty (Variable : in Symbol) return Boolean;
   --# global in Dict;

   function GetVirtualElementOwner (Variable : in Symbol) return Symbol;
   --# global in Dict;

   function IsVirtualElement (Variable : in Symbol) return Boolean;
   --# global in Dict;

   function IsVirtualElementForType (TheVariable      : in Symbol;
                                     TheProtectedType : in Symbol) return Boolean;
   --# global in Dict;

   function VirtualElementSeenByOwner (Variable : in Symbol) return Boolean;
   --# global in Dict;

   function GetMainProgram return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsSubprogram (S, Dict));

   function GetMainProgramPriority return  LexTokenManager.Lex_String;
   --# global in Dict;

   function GetAbstraction (Subprogram : Symbol;
                            Scope      : Scopes) return Abstractions;
   --# global in Dict;

   function GetConstraintAbstraction (Subprogram : Symbol;
                                      Scope      : Scopes) return Abstractions;
   --# global in Dict;
   -- Similar above but selects which subprgoram constraint to use.  May return different
   -- result to GetAbstraction because a subprogram may have only one flow annotation
   -- but have two proof contexts (if private type refinement is involved).

   procedure AdjustTypeUpperBound (TypeMark : Symbol;
                                   NewBound : LexTokenManager.Lex_String);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   NewBound,
   --#                   TypeMark;

   procedure AdjustTypeLowerBound (TypeMark : Symbol;
                                   NewBound : LexTokenManager.Lex_String);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   NewBound,
   --#                   TypeMark;

   procedure AdjustTypeErrorBound (TypeMark : Symbol;
                                   NewBound : LexTokenManager.Lex_String);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   NewBound,
   --#                   TypeMark;

   -- **********************************************************************
   -- NB: the three above operations are not intended for general use,
   --     and are present for the benefit of the ConfigFile package.
   -- **********************************************************************

   --------------------------------------------------------------------------------
   --                              QUERY FUNCTIONS                               --
   --------------------------------------------------------------------------------

   function IsObject (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function Is_Declared (Item : Symbol) return Boolean;
   --# global in Dict;

   function Is_Constant (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function Is_Variable (TheSymbol : Symbol) return Boolean;
   --# global in Dict;
   -- Note, returns false for a record subcomponent

   function IsVariableOrSubcomponent (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function GetFirstRecordSubcomponent (TheSymbol : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsSubcomponent (S, Dict));

   function GetNextRecordSubcomponent (TheSubcomponent : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsSubcomponent (S, Dict));

   function VariableIsInitialized (Variable : Symbol) return Boolean;
   --# global in Dict;

   function VariableHasAddressClause (Variable : Symbol) return Boolean;
   --# global in Dict;

   function VariableHasPragmaImport (Variable : Symbol) return Boolean;
   --# global in Dict;

   function TypeSizeAttribute (TypeMark : Symbol) return LexTokenManager.Lex_String;
   --# global in Dict;

   function VariableIsAliased (Variable : Symbol) return Boolean;
   --# global in Dict;

   procedure SetVariableMarkedValid (Variable : in Symbol;
                                     Val      : in Boolean);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Val,
   --#                   Variable;

   function VariableIsMarkedValid (TheVariable : Symbol) return Boolean;
   --# global in Dict;

   procedure SetSubcomponentMarkedValid (Subcomponent : in Symbol;
                                         Val          : in Boolean);
   --# global in out Dict;
   --# derives Dict from *,
   --#                   Subcomponent,
   --#                   Val;

   function SubcomponentIsMarkedValid (TheSubcomponent : Symbol) return Boolean;
   --# global in Dict;

   function VariableOrSubcomponentIsMarkedValid (TheSym : Symbol) return Boolean;
   --# global in Dict;

   function IsAtomic (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsPragmaAtomic (TheSymbol : Symbol) return Boolean;
   --# global in CommandLineData.Content;
   --#        in Dict;

   function IsDeferredConstant (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function ConstantIsDeferredHere (TheConstant : Symbol;
                                    Scope       : Scopes) return Boolean;
   --# global in Dict;

   function IsUnknownTypeMark (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsUniversalIntegerType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsUniversalRealType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   -- True iff IsTypeMark (TheSymbol) and ISN'T UnknownType and
   -- ISN'T a subtype
   function IsType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsSubtype (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsTaskType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsProtectedType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsProtectedTypeMark (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsProtectedFunction (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function CompatibleTypes
     (Scope : Scopes;
      Left  : Symbol;
      Right : Symbol)
     return  Boolean;
   --# global in Dict;

   function IsScalarTypeMark (TheSymbol : Symbol;
                              Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsDiscreteTypeMark (TheSymbol : Symbol;
                                Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsIntegerTypeMark (TheSymbol : Symbol;
                               Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsModularTypeMark (TheSymbol : Symbol;
                               Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsRealTypeMark (TheSymbol : Symbol;
                            Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsFixedPointTypeMark (TheSymbol : Symbol;
                                  Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsFloatingPointTypeMark (TheSymbol : Symbol;
                                     Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsArrayTypeMark (TheSymbol : Symbol;
                             Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsRecordTypeMark (TheSymbol : Symbol;
                              Scope     : Scopes) return Boolean;
   --# global in Dict;

   function TypeIsBoolean (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsCharacter (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsEnumeration (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsInteger (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsModular (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsDiscrete (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsFixedPoint (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsFloatingPoint (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsReal (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsNumeric (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsScalar (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsRecord (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsAbstractProof (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsArray (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsAnnounced (TheType : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsPrivate (TheType : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsTagged (TheType : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsExtendedTagged (TheType : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsTask (TheType : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsAccess (TheType : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsGeneric (TheType : Symbol) return Boolean;
   --# global in Dict;

   function ExtendedTaggedHasPrivateAncestors (TheType : Symbol;
                                               Scope   : Scopes) return Boolean;
   --# global in Dict;

   function IsAnExtensionOf (RootType, ExtendedType : Symbol) return Boolean;
   --# global in Dict;

   function NoFieldsBelowThisRecord (RecordSym : Symbol) return Boolean;
   --# global in Dict;
   -- Returns true for an extended record if all its inherited records are null
   -- extensions or null records

   function RecordHasSomeFields (RecordSym : Symbol) return Boolean;
   --# global in Dict;
   -- return true if a record either has soem fields itself or it inherits some from an
   -- ancestor type

   function ContainsFloat (TypeMark : Symbol) return Boolean;
   --# global in Dict;

   function GetEnclosingCompilationUnit (Scope : Scopes) return Symbol;
   --# global in Dict;

   function LoopHasName (TheLoop : Symbol) return Boolean;
   --# global in Dict;
   --#        in LexTokenManager.State;

   function GetLoopNumber (TheLoop : Symbol) return Positive;
   --# global in Dict;

   function IsPrivateTypeMark (TheSymbol : Symbol;
                               Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsPrivateType (TheSymbol : Symbol;
                           Scope     : Scopes) return Boolean;
   --# global in Dict;

   -- Returns True iff the given Type is INCOMPLETE
   -- the point of view of the given Scope.
   function TypeIsIncompleteHere (TypeMark : Symbol;
                                  Scope    : Scopes) return Boolean;
   --# global in Dict;

   function IsLimitedPrivateType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function TypeIsLimited (TypeMark : Symbol;
                           Scope    : Scopes) return Boolean;
   --# global in Dict;

   function TypeIsOwnAbstractHere (TypeMark : in Symbol;
                                   Scope    : in Scopes) return Boolean;
   --# global in Dict;

   function IsStatic (Item  : Symbol;
                      Scope : Scopes) return Boolean;
   --# global in Dict;

   function IsScalarType (TheSymbol : Symbol;
                          Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsNumericType (TheSymbol : Symbol;
                           Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsIntegerType (TheSymbol : Symbol;
                           Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsModularType (TheSymbol : Symbol;
                           Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsFixedPointType (TheSymbol : Symbol;
                              Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsFloatingPointType (TheSymbol : Symbol;
                                 Scope     : Scopes) return Boolean;
   --# global in Dict;

   function Is_Constrained_Array_Type_Mark (TheSymbol : Symbol;
                                            Scope     : Scopes) return Boolean;
   --# global in Dict;

   function Is_Unconstrained_Array_Type_Mark (TheSymbol : Symbol;
                                              Scope     : Scopes) return Boolean;
   --# global in Dict;

   function IsUnconstrainedArrayType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsUnconstrainedTaskType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsUnconstrainedProtectedType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsRecordComponent (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function GetEnclosingObject (Object : Symbol) return Symbol;
   --# global in Dict;

   function GetMostEnclosingObject (Object : Symbol) return Symbol;
   --# global in Dict;

   function DefinedInPackageStandard (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsPredefined (TheSymbol : Symbol) return Boolean;
   --# global in CommandLineData.Content;
   --#        in Dict;
   -- Returns true if the scope of the symbol is the visible scope of any of the
   -- following predefined packages:
   -- STANDARD
   -- ASCII
   -- Ada                           -- Ada95
   -- Ada.Characters                -- Ada95
   -- Ada.Characters.Latin_1        -- Ada95
   -- Ada.Real_Time                 -- Ravenscar
   -- Ada.Synchronous_Task_Control, -- Ravenscar
   -- Ada.Interrupts                -- Ravenscar

   function IsPredefinedIntegerType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsPredefinedFloatType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsPredefinedCharacterType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsPredefinedStringType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsPredefinedTimeType (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsPredefinedSuspensionObjectType (TheSymbol : Symbol) return Boolean;
   --# global in CommandLineData.Content;
   --#        in Dict;

   function IsPredefinedSuspendUntilTrueOperation (TheProcedure : Symbol) return Boolean;
   --# global in Dict;

   function IsPredefinedRealTimeClockOperation (TheProcedure : Symbol) return Boolean;
   --# global in Dict;

   function IsCompilationUnit (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function Is_Withed (The_Withed_Symbol : Symbol;
                       Scope             : Scopes) return Boolean;
   --# global in Dict;

   function Is_Withed_Locally (The_Withed_Symbol : Symbol;
                               Scope             : Scopes) return Boolean;
   --# global in Dict;

   function IsUsedLocally (TheType : Symbol;
                           Scope   : Scopes) return Boolean;
   --# global in Dict;

   function IsInherited (ThePackage, CompilationUnit : Symbol) return Boolean;
   --# global in Dict;

   function Is_Generic_Subprogram (The_Symbol : Symbol) return Boolean;
   --# global in Dict;

   function IsFunction (TheSymbol : Symbol) return Boolean;
   --# global in Dict;
   --# return S => (S -> Is_Subprogram (TheSymbol, Dict));

   function IsEntry (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function GetSubprogramEntryBarrier (Subprogram : Symbol) return Symbol;
   --# global in Dict;
   -- return Entries Booelan variable barrier symbol if there is one, else null sym

   function IsInterruptHandler (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsAnUncheckedConversion (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function UsesUncheckedConversion (TheUnit : Symbol) return Boolean;
   --# global in Dict;

   function AssignsFromExternal (TheUnit : Symbol) return Boolean;
   --# global in Dict;

   function IsProcedure (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsProofConstant (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsAdaFunction (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsProofFunction (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function Is_Renamed (Subprogram : Symbol;
                        Scope      : Scopes) return Boolean;
   --# global in Dict;

   function SetsPriority (TheDiscriminant : Symbol) return Boolean;
   --# global in Dict;

   function IsFormalParameter (Subprogram, Parameter : Symbol) return Boolean;
   --# global in Dict;

   function IsGenericFormalParameter (TheGeneric, Parameter : Symbol) return Boolean;
   --# global in Dict;

   function HasBody (CompilationUnit : Symbol) return Boolean;
   --# global in Dict;

   function HasBodyStub (CompilationUnit : Symbol) return Boolean;
   --# global in Dict;

   function Is_Global_Variable
     (Abstraction : Abstractions;
      Subprogram  : Symbol;
      Variable    : Symbol)
     return        Boolean;
   --# global in Dict;

   function IsImportExport
     (Abstraction  : Abstractions;
      TheProcedure : Symbol;
      Variable     : Symbol)
     return         Boolean;
   --# global in Dict;

   function IsExport
     (Abstraction  : Abstractions;
      TheProcedure : Symbol;
      Variable     : Symbol)
     return         Boolean;
   --# global in Dict;

   function IsImport
     (Abstraction  : Abstractions;
      TheProcedure : Symbol;
      Variable     : Symbol)
     return         Boolean;
   --# global in Dict;

   function IsArrayAttribute (Name     : LexTokenManager.Lex_String;
                              TypeMark : Symbol) return Boolean;
   --# global in Dict;
   --#        in LexTokenManager.State;

   function IsEmbeddedPackage (TheSymbol : Symbol) return Boolean;
   --# global in Dict;

   function IsOwnVariable (Variable : Symbol) return Boolean;
   --# global in Dict;

   function IsOwnTask (Variable : Symbol) return Boolean;
   --# global in Dict;

   function IsRefinedOwnVariable (Variable : Symbol) return Boolean;
   --# global in Dict;

   function OwnVariableHasType (OwnVariable : Symbol;
                                Scope       : Scopes) return Boolean;
   --# global in Dict;

   function OwnVariableIsAnnounced (Variable : Symbol) return Boolean;
   --# global in Dict;

   function OwnVariableIsInitialized (Variable : Symbol) return Boolean;
   --# global in Dict;

   function OwnVariableHasConstituents (Variable : Symbol) return Boolean;
   --# global in Dict;

   function IsConcreteOwnVariable (Variable : Symbol) return Boolean;
   --# global in Dict;

   function IsRefinement (Subject, Constituent : Symbol) return Boolean;
   --# global in Dict;

   function IsRefinementConstituent (ThePackage, Variable : Symbol) return Boolean;
   --# global in Dict;

   function IsConstituent (Variable : Symbol) return Boolean;
   --# global in Dict;

   function GetSubject (Constituent : Symbol) return Symbol;
   --# global in Dict;
   --# return S => (Is_Null_Symbol (S) or IsVariable (S, Dict));

   function HasDelayProperty (TheProcedure : Symbol) return Boolean;
   --# global in Dict;

   function DelayPropertyIsAccountedFor (TheProcedure : Symbol) return Boolean;
   --# global in Dict;

   function HasValidPriorityProperty (OwnVariable : Symbol) return Boolean;
   --# global in Dict;

   function IsThread (Sym : in Symbol) return Boolean;
   --# global in Dict;

   function UsesUnprotectedVariables (Sym : in Symbol) return Boolean;
   --# global in Dict;

   function GetUnprotectedReference (Variable : in Symbol) return Symbol;
   --# global in Dict;

   function GetSuspendsReference (Variable : in Symbol) return Symbol;
   --# global in Dict;

   function SuspendsOn (TheTaskOrProc : Symbol;
                        ThePOorSO     : Symbol) return Boolean;
   --# global in Dict;

   function SuspendsListItemIsAccountedFor (TheTaskOrProc : Symbol;
                                            ThePOorSO     : Symbol) return Boolean;
   --# global in Dict;

   function SuspendsListIsPropagated (FromProcedure : Symbol;
                                      ToTaskOrProc  : Symbol) return Boolean;
   --# global in Dict;

   function SubprogramMayBlock (Subprogram : Symbol) return Boolean;
   --# global in Dict;

   function BodyIsHidden (Sym : Symbol) return Boolean;
   --# global in Dict;

   -- Returns true to indicate that a procedure or task has an explicit
   -- derives annotation (rather than a synthesised one).
   function GetHasDerivesAnnotation (Task_Or_Proc : Symbol) return Boolean;
   --# global in Dict;

   function IsMainProgram (Subprogram : Symbol) return Boolean;
   --# global in Dict;

   function IsThePartition (Subprogram : Symbol) return Boolean;
   --# global in Dict;

   -- Returns True iff Sym is a program unit as defined by
   -- Ada95 LRM Annex N.31.  Used to check the legality of
   -- adddress representation clauses.  This definition also
   -- seems to be consistent with that given in Ada83 LRM 13.1(4).
   function IsProgramUnit (Sym : Symbol) return Boolean;
   --# global in Dict;

   function MainProgramExists return Boolean;
   --# global in Dict;

   function MainProgramPrioritySupplied return Boolean;
   --# global in Dict;

   function PackageRequiresBody (ThePackage : Symbol) return Boolean;
   --# global in CommandLineData.Content;
   --#        in Dict;

   function GetInterruptStreamVariable (ProtectedObject  : in Symbol;
                                        InterruptHandler : in Symbol) return Symbol;
   --# global in CommandLineData.Content;
   --#        in Dict;
   --#        in LexTokenManager.State;

   --------------------------------------------------------------------------------
   --                                 ITERATORS                                  --
   --------------------------------------------------------------------------------

   function CurrentSymbol (CurrentIterator : Iterator) return Symbol;
   --# global in Dict;

   function NextSymbol (Previous : Iterator) return Iterator;
   --# global in Dict;

   function IsNullIterator (Current : Iterator) return Boolean;

   function First_Deferred_Constant (The_Package : Symbol) return Iterator;
   --# global in Dict;

   function FirstArrayIndex (TypeMark : Symbol) return Iterator;
   --# global in Dict;

   function First_Undeclared_Type (The_Package : Symbol) return Iterator;
   --# global in Dict;

   function First_Private_Type (The_Package : Symbol) return Iterator;
   --# global in Dict;

   function FirstEnumerationLiteral (EnumerationType : Symbol) return Iterator;
   --# global in Dict;

   function FirstRecordComponent (TheRecordType : Symbol) return Iterator;
   --# global in Dict;
   -- N.B. This iterator works over a single record; if you want to iterate
   --      over a group of records modelling extension of tagged types then
   --      use the following function instead.

   function FirstExtendedRecordComponent (TheRecordType : Symbol) return Iterator;
   --# global in Dict;

   function First_Visible_Subprogram (The_Package_Or_Type : Symbol) return Iterator;
   --# global in Dict;

   function First_Private_Subprogram (The_Package : Symbol) return Iterator;
   --# global in Dict;

   function First_Visible_Task_Type (The_Package : Symbol) return Iterator;
   --# global in Dict;

   function First_Private_Task_Type (The_Package : Symbol) return Iterator;
   --# global in Dict;

   function FirstOwnTask (ThePackage : Symbol) return Iterator;
   --# global in Dict;

   function First_Visible_Protected_Type (The_Package : Symbol) return Iterator;
   --# global in Dict;

   function First_Private_Protected_Type (The_Package : Symbol) return Iterator;
   --# global in Dict;

   function FirstSubprogramParameter (Subprogram : Symbol) return Iterator;
   --# global in Dict;

   function FirstGenericFormalParameter (TheGeneric : Symbol) return Iterator;
   --# global in Dict;

   function GetNumberOfGenericFormalParameters (TheGeneric : Symbol) return Natural;
   --# global in Dict;

   function GetGenericFormalParameterKind (TheGenericFormalParameter : Symbol) return Generic_Parameter_Kind;
   --# global in Dict;

   function FirstKnownDiscriminant (ProtectedOrTaskType : Symbol) return Iterator;
   --# global in Dict;

   function FirstGlobalVariable (Abstraction : Abstractions;
                                 Subprogram  : Symbol) return Iterator;
   --# global in Dict;

   function First_Local_Variable (Subprogram : Symbol) return Iterator;
   --# global in Dict;

   function First_Initialized_Variable (Subprogram : Symbol) return Iterator;
   --# global in Dict;

   function FirstProtectedElement (The_Protected_Type : Symbol) return Iterator;
   --# global in Dict;

   function FirstImportExport (Abstraction  : Abstractions;
                               TheProcedure : Symbol) return Iterator;
   --# global in Dict;

   function FirstExport (Abstraction  : Abstractions;
                         TheProcedure : Symbol) return Iterator;
   --# global in Dict;

   function FirstImport (Abstraction  : Abstractions;
                         TheProcedure : Symbol) return Iterator;
   --# global in Dict;

   function FirstDependency
     (Abstraction  : Abstractions;
      TheProcedure : Symbol;
      TheExport    : Symbol)
     return         Iterator;
   --# global in Dict;

   function FirstSuspendsListItem (TheTaskOrProc : Symbol) return Iterator;
   --# global in Dict;

   function FirstVirtualElement (TheProtectedType : Symbol) return Iterator;
   --# global in Dict;

   function FirstOwnedPackage (ThePackage : Symbol) return Iterator;
   --# global in Dict;

   function First_Embedded_Package (Compilation_Unit : Symbol) return Iterator;
   --# global in Dict;

   function FirstOwnVariable (ThePackage : Symbol) return Iterator;
   --# global in Dict;

   function FirstInitializedOwnVariable (ThePackage : Symbol) return Iterator;
   --# global in Dict;

   function FirstConstituent (Subject : Symbol) return Iterator;
   --# global in Dict;

   function FirstInheritsClause (Sym : Symbol) return Iterator;
   --# global in Dict;

   function FirstInterruptStreamMapping (Sym : Symbol) return Iterator;
   --# global in Dict;

   function FirstLoopOnEntryVar (TheLoop : Symbol) return Iterator;
   --# global in Dict;
   -- returns first variable used in exit expression of for loop

   function GetInterruptStreamMappingHandler (TheMapping : in Symbol) return LexTokenManager.Lex_String;

   function GetInterruptStreamMappingStream (TheMapping : in Symbol) return LexTokenManager.Lex_String;

   --------------------------------------------------------------------------------

private
   --  We allocate SymbolTableSize entries for user-defined Symbols,
   --  plus sentinel value 0 for NullSymbol
   type Symbol is range 0 .. Natural'Last;
   --# assert Symbol'Base is Integer;

   NullSymbol : constant Symbol := Symbol'First;

   type IteratorDiscriminant is (
                                 NullSymIterator,
                                 DeclarativeItemIterator,
                                 DeferredConstantIterator,
                                 ArrayIndexIterator,
                                 LoopIterator,
                                 UndeclaredTypeIterator,
                                 PrivateTypeIterator,
                                 EnumerationLiteralIterator,
                                 RecordComponentIterator,
                                 ExtendedRecordComponentIterator,
                                 LibraryUnitIterator,
                                 WithedPackageIterator,
                                 InheritedPackageIterator,
                                 VisibleSubprogramIterator,
                                 PrivateSubprogramIterator,
                                 TaskTypeIterator,
                                 OwnTaskIterator,
                                 ProtectedTypeIterator,
                                 SubprogramParameterIterator,
                                 GenericFormalParameterIterator,
                                 KnownDiscriminantIterator,
                                 DiscriminantConstraintIterator,
                                 ImplicitProofFunctionParameterIterator,
                                 ImplicitProofFunctionGlobalIterator,
                                 GlobalVariableIterator,
                                 LocalVariableIterator,
                                 InitializedVariableIterator,
                                 ImportExportIterator,
                                 ExportIterator,
                                 ImportIterator,
                                 DependencyIterator,
                                 InterruptStreamMappingIterator,
                                 SuspendsListItemIterator,
                                 VirtualElementIterator,
                                 OwnedPackageIterator,
                                 ProtectedElementIterator,
                                 LoopOnEntryVarIterator,
                                 EmbeddedPackageIterator,
                                 -- see Dictionary.CurrentSymbol before adding to this list, position matters
                                 OwnVariableIterator,
                                 InitializedOwnVariableIterator,
                                 AbstractOwnVariableIterator,
                                 -- see Dictionary.CurrentSymbol before adding to this list, position matters
                                 ConstituentIterator);

   type Iterator is record
      Discriminant : IteratorDiscriminant;
      Abstraction  : Abstractions;
      Current      : Symbol;
      Context      : Symbol;
   end record;

   NullIterator : constant Iterator := Iterator'(NullSymIterator, IsAbstract, NullSymbol, NullSymbol);

   --  If you change this, please also change
   --  Cells.Utility.Create_Scope_Cell and
   --  Cells.Utility.Scope_Cell_Get_Scope.
   type Scopes is record
      The_Visibility : Visibility;
      The_Unit       : Symbol;
   end record;

   NullScope : constant Scopes := Scopes'(The_Visibility => Visible,
                                          The_Unit       => NullSymbol);
end Dictionary;