aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/ada/acats-4/support/special.a
blob: c1fd605e8ab5af581df3bb5b16d5a16aaaadc9c6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
-- SPECIAL.A
--
--                             Grant of Unlimited Rights
--
--     The Ada Conformity Assessment Authority (ACAA) holds unlimited
--     rights in the software and documentation contained herein. Unlimited
--     rights are the same as those granted by the U.S. Government for older
--     parts of the Ada Conformity Assessment Test Suite, and are defined
--     in DFAR 252.227-7013(a)(19). By making this public release, the ACAA
--     intends to confer upon all recipients unlimited rights equal to those
--     held by the ACAA. These rights include rights to use, duplicate,
--     release or disclose the released technical data and computer software
--     in whole or in part, in any manner and for any purpose whatsoever, and
--     to have or permit others to do so.
--
--                                    DISCLAIMER
--
--     ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR
--     DISCLOSED ARE AS IS. THE ACAA MAKES NO EXPRESS OR IMPLIED
--     WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE
--     SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE
--     OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A
--     PARTICULAR PURPOSE OF SAID MATERIAL.
--
--                                     Notice
--
--     The ACAA has created and maintains the Ada Conformity Assessment Test
--     Suite for the purpose of conformity assessments conducted in accordance
--     with the International Standard ISO/IEC 18009 - Ada: Conformity
--     assessment of a language processor. This test suite should not be used
--     to make claims of conformance unless used in accordance with
--     ISO/IEC 18009 and any applicable ACAA procedures.
--
--*
--
-- PURPOSE:
--      This package provides information about tests that require
--      special handling by the test summary (Summary.A).
--      This information is maintained by the ACAA; please report
--      any suggested changes to the ACAA at agent@ada-auth.org.
--
-- CHANGE HISTORY:
--     20 May 2016   RLB  Split from Summary tool.
--     22 May 2016   RLB  Added Do_Special.
--     23 Mar 2017   RLB  Added test BA21005 to the optional unit list.
--     13 Feb 2018   RLB  Added additional tests to the optional unit list.
--                        Also, fixed some comments.
--     15 Feb 2018   RLB  Added a new test to the optional unit list.
--     13 Jun 2018   RLB  Added some existing tests to the optional unit list.
--     06 Sep 2018   RLB  Added a new test to the optional unit list.

with Trace, Test_Summary, Ada.Text_IO;
package Special_Handling is

   function Optional_Unit_for_Test
               (Source_Name : Trace.Name_Subtype;
                Unit_Name   : Test_Summary.Comp_Unit_Name;
                Unit_Kind   : Test_Summary.Compilation_Unit_Kinds)
      return Boolean;
      -- Returns True if the test in the source file Source_Name
      -- has an optional unit Unit_Name with Unit_Kind according to the
      -- Optional_Unit_List. Returns False otherwise.


   type Special_Kind is (Not_Special, No_Parse, Fully_Manual);
   type Acc_WSR is access procedure (Rec : in Test_Summary.Info_Record);

   function Do_Special_for_Test_File
               (Source_Name  : Trace.Name_Subtype;
                Summary_File : Ada.Text_IO.File_Type)
      return Special_Kind;
      -- Checks if Source_Name needs special handling; if so, writes the
      -- needed records to Summary_File and returns the appropriate Kind.
      -- If this routine returns Not_Special, the unit should be parsed
      -- normally. If this routine returns No_Parse, the unit should not be
      -- parsed, but it should be split into tokens (so the error tags are
      -- processed). This is used for tests which are lexically fine, but have
      -- severe parse errors that the summary tool cannot handle. This routine
      -- will have written the compilation unit records for the test file.
      -- If this routine returns Fully_Manual, no processing should be done on
      -- the unit. This is used for tests with lexical errors that the summary
      -- tool cannot handle. This routine will have written the entire summary
      -- for the test file.

end Special_Handling;

package body Special_Handling is

   -- Unit whose processing is optional:

   MAX_OPT_UNIT : constant := 1_000;
      -- We have to use a constant as there is no reasonable way to find
      -- out how many records are in an optional unit file short of reading
      -- the entire file an extra time.
   type Optional_Unit_Count is range 0 .. MAX_OPT_UNIT;
   subtype Optional_Unit_Index is Optional_Unit_Count range
                                                      1 .. MAX_OPT_UNIT;

   type Optional_Unit_Rec is record
      Source_Name : Trace.Name_Subtype;
      Unit_Name   : Test_Summary.Comp_Unit_Name;
      Unit_Kind   : Test_Summary.Compilation_Unit_Kinds;
   end record;

   type Optional_Unit_Array is array (Optional_Unit_Index range <>) of
      Optional_Unit_Rec;

   Optional_Unit_List : constant Optional_Unit_Array :=
      (   1 => (Source_Name => "BA150031.A  ",
                Unit_Name   => "BA150031" &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Package_Body),
          2 => (Source_Name => "BA150038.A  ",
                Unit_Name   => "BA150038" &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Package_Body),
          3 => (Source_Name => "BA150039.A  ",
                Unit_Name   => "BA150039" &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Package_Body),
          4 => (Source_Name => "BA15003A.A  ",
                Unit_Name   => "BA15003A" &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Package_Body),
          5 => (Source_Name => "B611002.A   ",
                Unit_Name   => "SPEC2   " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Subunit),
          6 => (Source_Name => "B611002.A   ",
                Unit_Name   => "SPEC6   " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Subunit),
          7 => (Source_Name => "B611002.A   ",
                Unit_Name   => "B611002 " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
          8 => (Source_Name => "B611004.A   ",
                Unit_Name   => "SPEC2   " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Subunit),
          9 => (Source_Name => "B611004.A   ",
                Unit_Name   => "SPEC6   " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Subunit),
         10 => (Source_Name => "B611004.A   ",
                Unit_Name   => "B611004 " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
         11 => (Source_Name => "BA210057.AM ",
                Unit_Name   => "BA210057" &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
         12 => (Source_Name => "BA1001D.ADA ",
                Unit_Name   => "BA1001D " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
         13 => (Source_Name => "BA1020F2.ADA",
                Unit_Name   => "BA1020F2M" &
                               (10..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
         14 => (Source_Name => "BA110134.AM ",
                Unit_Name   => "BA11013 " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
         15 => (Source_Name => "BA110134.AM ",
                Unit_Name   => "BA11013A" &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Package_Body),
         16 => (Source_Name => "BA140016.A  ",
                Unit_Name   => "BA14001H" &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
         17 => (Source_Name => "BA140018.A  ",
                Unit_Name   => "BA14001A.DAUGHTER" &
                               (18..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Function_Body),
         18 => (Source_Name => "BA140024.A  ",
                Unit_Name   => "BA14002H" &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
         19 => (Source_Name => "B854001.A   ",
                Unit_Name   => "B854001 " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
         20 => (Source_Name => "BDD2002.A   ",
                Unit_Name   => "BDD2002 " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
         21 => (Source_Name => "B370001.A   ",
                Unit_Name   => "B370001 " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
         22 => (Source_Name => "B7400032.AM ",
                Unit_Name   => "B7400032" &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body),
         23 => (Source_Name => "B854003.A   ",
                Unit_Name   => "B854003 " &
                               (9..Test_Summary.Comp_Unit_Name'Last => ' '),
                Unit_Kind   => Test_Summary.Procedure_Body));

       -- Note: This list is maintained by the ACAA as part of the ACATS.
       -- Please report any units that should be on this list but are not to
       -- the ACAA at agent@ada-auth.org.

   Last_Optional_Unit : Optional_Unit_Count := Optional_Unit_List'Last;
      -- A list of optional units in source files. The grading tool
      -- will not require compilation of such units (these typically are
      -- part of B-Tests). Note that this list is part of the ACATS and is
      -- not created/modified by the user.

   function Optional_Unit_for_Test
               (Source_Name : Trace.Name_Subtype;
                Unit_Name   : Test_Summary.Comp_Unit_Name;
                Unit_Kind   : Test_Summary.Compilation_Unit_Kinds)
      return Boolean is
      -- Returns True if the test in the source file Source_Name
      -- has an optional unit Unit_Name with Unit_Kind according to the
      -- Optional_Unit_List. Returns False otherwise.
      use type Test_Summary.Compilation_Unit_Kinds;
   begin
      for Man in 1 .. Last_Optional_Unit loop
         if Optional_Unit_List(Man).Source_Name = Source_Name and then
            Optional_Unit_List(Man).Unit_Name = Unit_Name and then
            Optional_Unit_List(Man).Unit_Kind = Unit_Kind then
            return True; -- The source/unit/kind is on the optional unit list.
         -- else not this test, continue checking.
         end if;
      end loop;
      return False;
   end Optional_Unit_for_Test;

   Special_Unit_Info : constant array (Positive range <>) of
        Test_Summary.Info_Record :=
      (1 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B53001A.ADA ",
             Start_Line     => 31,
             Start_Position =>  1,
             End_Line       => 58,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B53001A" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
       2 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B55A01J.ADA ",
             Start_Line     => 35,
             Start_Position =>  1,
             End_Line       => 46,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B55A01J" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
       3 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B55A01K.ADA ",
             Start_Line     => 35,
             Start_Position =>  1,
             End_Line       => 45,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B55A01K" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
       4 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B55A01L.ADA ",
             Start_Line     => 35,
             Start_Position =>  1,
             End_Line       => 45,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B55A01L" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
       5 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B56001D.ADA ",
             Start_Line     => 29,
             Start_Position =>  1,
             End_Line       => 35,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B56001D" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
       6 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B56001H.ADA ",
             Start_Line     => 29,
             Start_Position =>  1,
             End_Line       => 41,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B56001H" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
       7 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "BD4003A.ADA ",
             Start_Line     => 42,
             Start_Position =>  1,
             End_Line       => 115,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "BD4003A" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
       8 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "BD4003B.ADA ",
             Start_Line     => 35,
             Start_Position =>  1,
             End_Line       => 72,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "BD4003B" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
       9 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B67001H.ADA ",
             Start_Line     => 32,
             Start_Position =>  1,
             End_Line       => 55,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B67001H" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      10 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B67001J.ADA ",
             Start_Line     => 32,
             Start_Position =>  1,
             End_Line       => 53,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B67001J" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      11 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B67001K.ADA ",
             Start_Line     => 34,
             Start_Position =>  1,
             End_Line       => 70,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B67001K" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      12 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B29001A.ADA ",
             Start_Line     => 32,
             Start_Position =>  1,
             End_Line       => 185,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B29001A" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      13 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B91001B.ADA ",
             Start_Line     => 31,
             Start_Position =>  1,
             End_Line       => 42,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B91001B" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      14 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B91001D.ADA ",
             Start_Line     => 31,
             Start_Position =>  1,
             End_Line       => 33,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body, -- Really junk.
             Unit_Name      => "B91001D" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      15 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B91001E.ADA ",
             Start_Line     => 31,
             Start_Position =>  1,
             End_Line       => 33,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body, -- Really junk.
             Unit_Name      => "B91001E" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      16 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B91002F.ADA ",
             Start_Line     => 33,
             Start_Position =>  1,
             End_Line       => 53,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B91002F" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      17 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B95006D.ADA ",
             Start_Line     => 32,
             Start_Position =>  1,
             End_Line       => 50,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B95006D" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      18 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B952002.A   ",
             Start_Line     => 46,
             Start_Position =>  1,
             End_Line       => 91,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B952002" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      19 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B952003.A   ",
             Start_Line     => 40,
             Start_Position =>  1,
             End_Line       => 84,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B952003" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      20 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B97103E.ADA ",
             Start_Line     => 33,
             Start_Position =>  1,
             End_Line       => 72,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B97103E" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      21 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "B91001C.ADA ",
             Start_Line     => 32,
             Start_Position =>  1,
             End_Line       => 39,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "B91001C" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False),
      22 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "C250002.AU  ",
             Start_Line     => 48,
             Start_Position =>  1,
             End_Line       => 61,
             End_Position   => 15,
             Unit_Kind      => Test_Summary.Package_Specification,
             Unit_Name      => "C250002_0" &
                               (10..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => False,
             Optional       => False),
      23 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "C250002.AU  ",
             Start_Line     => 61,
             Start_Position =>  1,
             End_Line       => 81,
             End_Position   => 15,
             Unit_Kind      => Test_Summary.Package_Specification,
             Unit_Name      => "C250002_" & Character'Val(193) &
                               (10..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => False,
             Optional       => False),
      24 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "C250002.AU  ",
             Start_Line     => 85,
             Start_Position =>  1,
             End_Line       => 92,
             End_Position   => 15,
             Unit_Kind      => Test_Summary.Package_Body,
             Unit_Name      => "C250002_" & Character'Val(193) &
                               (10..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => False,
             Optional       => False),
      25 => (Kind           => Test_Summary.Compilation_Unit,
             Source_Name    => "C250002.AU  ",
             Start_Line     => 96,
             Start_Position =>  1,
             End_Line       => 174,
             End_Position   => 13,
             Unit_Kind      => Test_Summary.Procedure_Body,
             Unit_Name      => "C250002" &
                               (8..Test_Summary.Comp_Unit_Name'Last => ' '),
             Is_Main        => True,
             Optional       => False));

   function Do_Special_for_Test_File
               (Source_Name  : Trace.Name_Subtype;
                Summary_File : Ada.Text_IO.File_Type)
      return Special_Kind is
      -- Checks if Source_Name needs special handling; if so, uses
      -- uses Write_Rec to write the needed records and returns the appropriate
      -- Kind.
      -- If this routine returns Not_Special, the unit should be parsed
      -- normally. If this routine returns No_Parse, the unit should not be
      -- parsed, but it should be split into tokens (so the error tags are
      -- processed). This is used for tests which are lexically fine, but have
      -- severe parse errors that the summary tool cannot handle. This routine
      -- will have written the compilation unit records for the test file.
      -- If this routine returns Fully_Manual, no processing should be done on
      -- the unit. This is used for tests with lexical errors that the summary
      -- tool cannot handle. This routine will have written the entire summary
      -- for the test file.
   begin
      if Source_Name = "B53001A.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File, Special_Unit_Info(1));
         return No_Parse;
      elsif Source_Name = "B55A01J.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File, Special_Unit_Info(2));
         return No_Parse;
      elsif Source_Name = "B55A01K.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File, Special_Unit_Info(3));
         return No_Parse;
      elsif Source_Name = "B55A01L.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File, Special_Unit_Info(4));
         return No_Parse;
      elsif Source_Name = "B56001D.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File, Special_Unit_Info(5));
         return No_Parse;
      elsif Source_Name = "B56001H.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File, Special_Unit_Info(6));
         return No_Parse;
      elsif Source_Name = "BD4003A.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File, Special_Unit_Info(7));
         return No_Parse;
      elsif Source_Name = "BD4003B.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File, Special_Unit_Info(8));
         return No_Parse;
      elsif Source_Name = "B67001H.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File, Special_Unit_Info(9));
         return No_Parse;
      elsif Source_Name = "B67001J.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(10));
         return No_Parse;
      elsif Source_Name = "B67001K.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(11));
         return No_Parse;
      elsif Source_Name = "B29001A.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(12));
         return No_Parse;
      elsif Source_Name = "B91001B.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(13));
         return No_Parse;
      elsif Source_Name = "B91001D.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(14));
         return No_Parse;
      elsif Source_Name = "B91001E.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(15));
         return No_Parse;
      elsif Source_Name = "B91002F.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(16));
         return No_Parse;
      elsif Source_Name = "B95006D.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(17));
         return No_Parse;
      elsif Source_Name = "B952002.A   " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(18));
         return No_Parse;
      elsif Source_Name = "B952003.A   " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(19));
         return No_Parse;
      elsif Source_Name = "B97103E.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(20));
         return No_Parse;
      elsif Source_Name = "B91001C.ADA " then
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(21));
         return No_Parse;
      elsif Source_Name = "C250002.AU  " then
         -- Note: We won't need this one if we implement UTF-8 in this tool.
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(22));
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(23));
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(24));
         Test_Summary.Write_Summary_Record(Summary_File,Special_Unit_Info(25));
         return No_Parse;
      end if;
      return Not_Special;
   end Do_Special_for_Test_File;

end Special_Handling;