~ubuntu-branches/debian/lenny/fpc/lenny

« back to all changes in this revision

Viewing changes to fpcsrc/tests/test/cg/tcalobj8.pp

  • Committer: Bazaar Package Importer
  • Author(s): Mazen Neifer, Torsten Werner, Mazen Neifer
  • Date: 2008-05-17 17:12:11 UTC
  • mfrom: (3.1.9 intrepid)
  • Revision ID: james.westby@ubuntu.com-20080517171211-9qi33xhd9evfa0kg
Tags: 2.2.0-dfsg1-9
[ Torsten Werner ]
* Add Mazen Neifer to Uploaders field.

[ Mazen Neifer ]
* Moved FPC sources into a version dependent directory from /usr/share/fpcsrc
  to /usr/share/fpcsrc/${FPCVERSION}. This allow installing more than on FPC
  release.
* Fixed far call issue in compiler preventing building huge binearies.
  (closes: #477743)
* Updated building dependencies, recomennded and suggested packages.
* Moved fppkg to fp-utils as it is just a helper tool and is not required by
  compiler.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
{ %maxversion=1.9.4 }
 
2
 
 
3
{****************************************************************}
 
4
{  CODE GENERATOR TEST PROGRAM                                   }
 
5
{  Copyright (c) 2002 Carl Eric Codere                           }
 
6
{****************************************************************}
 
7
{ NODE TESTED : secondcalln()                                    }
 
8
{****************************************************************}
 
9
{ PRE-REQUISITES: secondload()                                   }
 
10
{                 secondassign()                                 }
 
11
{                 secondtypeconv()                               }
 
12
{                 secondtryexcept()                              }
 
13
{****************************************************************}
 
14
{ DEFINES:                                                       }
 
15
{            FPC     = Target is FreePascal compiler             }
 
16
{****************************************************************}
 
17
{ REMARKS: This tests secondcalln(), genentrycode() and          }
 
18
{ genexitcode() for standard object with the saveregisters       }
 
19
{ calling convention.                                            }
 
20
{                                                                }
 
21
{****************************************************************}
 
22
program tcalobj8;
 
23
{$STATIC ON}
 
24
{$R+}
 
25
 
 
26
 const
 
27
 { should be defined depending on CPU target }
 
28
 {$ifdef cpu68k}
 
29
   BIG_INDEX = 8000;
 
30
   SMALL_INDEX  = 13;
 
31
 {$else}
 
32
   BIG_INDEX = 33000;
 
33
   SMALL_INDEX = 13;     { value should not be aligned! }
 
34
 {$endif}
 
35
   RESULT_U8BIT = $55;
 
36
   RESULT_U16BIT = 2*RESULT_U8BIT;
 
37
   RESULT_S32BIT = $500F0000;
 
38
   RESULT_S64BIT = $500F0000;
 
39
   RESULT_S32REAL = 1777.12;
 
40
   RESULT_S64REAL = 3444.24;
 
41
   RESULT_BOOL8BIT = 1;
 
42
   RESULT_BOOL16BIT = 1;
 
43
   RESULT_BOOL32BIT = 1;
 
44
   RESULT_PCHAR = 'Hello world';
 
45
   RESULT_BIGSTRING = 'Hello world';
 
46
   RESULT_SMALLSTRING = 'H';
 
47
   RESULT_CHAR = 'I';
 
48
   RESULT_BOOLEAN = TRUE;
 
49
 
 
50
 type
 
51
 
 
52
   tprocedure = procedure;
 
53
 
 
54
   tsmallrecord = packed record
 
55
     b: byte;
 
56
     w: word;
 
57
   end;
 
58
 
 
59
   tlargerecord = packed record
 
60
     b: array[1..BIG_INDEX] of byte;
 
61
   end;
 
62
 
 
63
   tsmallarray = packed array[1..SMALL_INDEX] of byte;
 
64
 
 
65
   tsmallsetenum =
 
66
   (A_A,A_B,A_C,A_D);
 
67
 
 
68
   tsmallset = set of tsmallsetenum;
 
69
   tlargeset = set of char;
 
70
 
 
71
   tsmallstring = string[2];
 
72
 
 
73
 
 
74
 var
 
75
  global_u8bit : byte;
 
76
  global_u16bit : word;
 
77
  global_s32bit : longint;
 
78
  global_s32real : single;
 
79
  global_s64real : double;
 
80
  global_ptr : pchar;
 
81
  global_proc : tprocedure;
 
82
  global_bigstring : shortstring;
 
83
  global_boolean : boolean;
 
84
  global_char : char;
 
85
  global_s64bit : int64;
 
86
  value_s64bit : int64;
 
87
  value_ansistring : ansistring;
 
88
  value_u8bit : byte;
 
89
  value_u16bit : word;
 
90
  value_s32bit : longint;
 
91
  value_s32real : single;
 
92
  value_s64real  : double;
 
93
  value_proc : tprocedure;
 
94
  value_ptr : pchar;
 
95
  value_smallrec : tsmallrecord;
 
96
  value_largerec : tlargerecord;
 
97
  value_smallset : tsmallset;
 
98
  value_smallstring : tsmallstring;
 
99
  value_bigstring   : shortstring;
 
100
  value_largeset : tlargeset;
 
101
  value_smallarray : tsmallarray;
 
102
  value_boolean : boolean;
 
103
  value_char : char;
 
104
 
 
105
     procedure fail;
 
106
     begin
 
107
       WriteLn('Failure.');
 
108
       halt(1);
 
109
     end;
 
110
 
 
111
 
 
112
     procedure clear_globals;
 
113
      begin
 
114
       global_u8bit := 0;
 
115
       global_u16bit := 0;
 
116
       global_s32bit := 0;
 
117
       global_s32real := 0.0;
 
118
       global_s64real := 0.0;
 
119
       global_ptr := nil;
 
120
       global_proc := nil;
 
121
       global_bigstring := '';
 
122
       global_boolean := false;
 
123
       global_char := #0;
 
124
       global_s64bit := 0;
 
125
      end;
 
126
 
 
127
 
 
128
     procedure clear_values;
 
129
      begin
 
130
       value_u8bit := 0;
 
131
       value_u16bit := 0;
 
132
       value_s32bit := 0;
 
133
       value_s32real := 0.0;
 
134
       value_s64real  := 0.0;
 
135
       value_proc := nil;
 
136
       value_ptr := nil;
 
137
       fillchar(value_smallrec, sizeof(value_smallrec), #0);
 
138
       fillchar(value_largerec, sizeof(value_largerec), #0);
 
139
       value_smallset := [];
 
140
       value_smallstring := '';
 
141
       value_bigstring   := '';
 
142
       value_largeset := [];
 
143
       fillchar(value_smallarray, sizeof(value_smallarray), #0);
 
144
       value_boolean := false;
 
145
       value_char:=#0;
 
146
       value_ansistring := '';
 
147
       value_s64bit := 0;
 
148
      end;
 
149
 
 
150
 
 
151
      function getu8: byte;
 
152
       begin
 
153
         getu8 := RESULT_U8BIT;
 
154
       end;
 
155
 
 
156
 
 
157
type
 
158
 
 
159
 { object without vmt }
 
160
 pnovmtobject = ^tnovmtobject;
 
161
 tnovmtobject = object
 
162
 public
 
163
   object_bigstring : shortstring;
 
164
   object_u16bit : word;
 
165
   { no parameter testing }
 
166
   procedure method_public_none;saveregisters;
 
167
   procedure method_public_static_none; static;saveregisters;
 
168
   procedure method_call_private_none;saveregisters;
 
169
   procedure method_call_private_static_none; static;saveregisters;
 
170
   { simple value parameter testing }
 
171
   procedure method_public_u8(x : byte);saveregisters;
 
172
   procedure method_public_static_u8(x: byte); static;saveregisters;
 
173
   procedure method_call_private_u8(x: byte);saveregisters;
 
174
   procedure method_call_private_static_u8(x: byte); static;saveregisters;
 
175
   function  func_array_mixed_nested(b: byte): tsmallarray;saveregisters;
 
176
 private
 
177
   procedure method_private_none;saveregisters;
 
178
   procedure method_private_static_none; static;saveregisters;
 
179
   function func_getu16bit : word;saveregisters;
 
180
   { simple value parameter testing }
 
181
   procedure method_private_u8(x: byte);saveregisters;
 
182
   procedure method_private_static_u8(x: byte); static;saveregisters;
 
183
 end;
 
184
 
 
185
 
 
186
 { object with vmt }
 
187
 pvmtobject = ^tvmtobject;
 
188
 tvmtobject = object
 
189
 public
 
190
   object_u8bit : byte;
 
191
   object_u16bit : word;
 
192
   object_bigstring : shortstring;
 
193
   object_s32bit : longint;
 
194
   object_s64bit : int64;
 
195
   constructor constructor_params_mixed(u8 :byte; u16: word;
 
196
      bigstring: shortstring; s32: longint; s64: int64);
 
197
   constructor constructor_init;
 
198
   destructor destructor_params_done;
 
199
   procedure method_normal_params_mixed(u8 :byte; u16: word;
 
200
      bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
201
   procedure method_virtual_params_mixed(u8 :byte; u16: word;
 
202
      bigstring: shortstring; s32: longint; s64: int64);virtual;saveregisters;
 
203
   procedure method_virtual_overriden_params_mixed(u8 :byte; u16: word;
 
204
      bigstring: shortstring; s32: longint; s64: int64);virtual;saveregisters;
 
205
   procedure method_static_params_mixed(u8 :byte; u16: word;
 
206
      bigstring: shortstring; s32: longint; s64: int64);static;saveregisters;
 
207
   procedure method_normal_call_inherited_params_mixed(
 
208
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
209
 
 
210
   { virtual methods which call other methods }
 
211
   procedure method_virtual_call_static_params_mixed(
 
212
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);virtual;saveregisters;
 
213
   procedure method_virtual_call_virtual_params_mixed(
 
214
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);virtual;saveregisters;
 
215
   procedure method_virtual_call_overriden_params_mixed(
 
216
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);virtual;saveregisters;
 
217
   procedure method_virtual_call_normal_params_mixed(
 
218
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);virtual;saveregisters;
 
219
   procedure method_virtual_call_constructor_params_mixed(
 
220
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);virtual;saveregisters;
 
221
   procedure method_virtual_call_inherited_params_mixed(
 
222
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);virtual;saveregisters;
 
223
 
 
224
 end;
 
225
 
 
226
 pheritedvmtobject = ^theritedvmtobject;
 
227
 theritedvmtobject = object(tvmtobject)
 
228
   constructor constructor_params_mixed_call_virtual(u8 :byte; u16: word;
 
229
      bigstring: shortstring; s32: longint; s64: int64);
 
230
   constructor constructor_params_mixed_call_overriden(u8 :byte; u16: word;
 
231
      bigstring: shortstring; s32: longint; s64: int64);
 
232
   constructor constructor_params_mixed_call_static(u8 :byte; u16: word;
 
233
      bigstring: shortstring; s32: longint; s64: int64);
 
234
   constructor constructor_params_mixed_call_normal(u8 :byte; u16: word;
 
235
      bigstring: shortstring; s32: longint; s64: int64);
 
236
   constructor constructor_params_mixed_call_inherited(u8 :byte; u16: word;
 
237
      bigstring: shortstring; s32: longint; s64: int64);
 
238
   procedure method_virtual_overriden_params_mixed(
 
239
    u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);virtual;saveregisters;
 
240
 
 
241
   { normal methods which call other methods }
 
242
   procedure method_normal_call_static_params_mixed(
 
243
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
244
   procedure method_normal_call_virtual_params_mixed(
 
245
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
246
   procedure method_normal_call_overriden_params_mixed(
 
247
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
248
   procedure method_normal_call_normal_params_mixed(
 
249
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
250
   procedure method_normal_call_constructor_params_mixed(
 
251
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
252
   procedure method_normal_call_inherited_params_mixed(
 
253
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
254
 
 
255
   { virtual methods which call other methods }
 
256
   procedure method_virtual_call_inherited_params_mixed(
 
257
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);virtual;saveregisters;
 
258
 
 
259
 end;
 
260
 
 
261
 pfailvmtobject = ^tfailvmtobject;
 
262
 tfailvmtobject = object(tvmtobject)
 
263
 public
 
264
    constructor constructor_public_none;
 
265
 end;
 
266
 
 
267
 
 
268
 
 
269
{**************************************************************************}
 
270
{                             NO VMT OBJECT                                }
 
271
{**************************************************************************}
 
272
 
 
273
  {****************** NO PARAMETERS ******************}
 
274
 procedure tnovmtobject.method_public_none;saveregisters;
 
275
  begin
 
276
    global_u8bit := RESULT_U8BIT;
 
277
  end;
 
278
 
 
279
 
 
280
 procedure tnovmtobject.method_public_static_none;saveregisters;
 
281
  begin
 
282
    global_u8bit := RESULT_U8BIT;
 
283
  end;
 
284
 
 
285
 
 
286
 procedure tnovmtobject.method_call_private_none;saveregisters;
 
287
   begin
 
288
       method_private_none;
 
289
       method_private_static_none;
 
290
   end;
 
291
 
 
292
 procedure tnovmtobject.method_call_private_static_none;saveregisters;
 
293
   begin
 
294
     method_private_static_none;
 
295
   end;
 
296
 
 
297
 
 
298
 procedure tnovmtobject.method_private_none;saveregisters;
 
299
  begin
 
300
    Inc(global_u16bit, RESULT_U8BIT);
 
301
  end;
 
302
 
 
303
 
 
304
 procedure tnovmtobject.method_private_static_none;saveregisters;
 
305
  begin
 
306
    Inc(global_u16bit, RESULT_U8BIT);
 
307
  end;
 
308
 
 
309
  {******************** PARAMETERS ******************}
 
310
 
 
311
  procedure tnovmtobject.method_public_u8(x : byte);saveregisters;
 
312
   begin
 
313
     global_u8bit := x;
 
314
   end;
 
315
 
 
316
  procedure tnovmtobject.method_public_static_u8(x: byte);saveregisters;
 
317
   begin
 
318
     global_u8bit := x;
 
319
   end;
 
320
 
 
321
  procedure tnovmtobject.method_call_private_u8(x: byte);saveregisters;
 
322
   begin
 
323
     method_private_static_u8(x);
 
324
     method_private_u8(x);
 
325
   end;
 
326
 
 
327
  procedure tnovmtobject. method_call_private_static_u8(x: byte);saveregisters;
 
328
   begin
 
329
     method_private_static_u8(x);
 
330
   end;
 
331
 
 
332
   procedure tnovmtobject.method_private_u8(x: byte);saveregisters;
 
333
    begin
 
334
      Inc(global_u16bit,x);
 
335
    end;
 
336
 
 
337
   procedure tnovmtobject.method_private_static_u8(x: byte);saveregisters;
 
338
    begin
 
339
      Inc(global_u16bit,x);
 
340
    end;
 
341
 
 
342
 
 
343
  function tnovmtobject.func_getu16bit : word;saveregisters;
 
344
   begin
 
345
     func_getu16bit := object_u16bit;
 
346
   end;
 
347
 
 
348
  {
 
349
    complex testing, nested field access, with parameters and
 
350
    comple return value.
 
351
 
 
352
    On exit : global_u8bit := x;
 
353
              global_u16bit := object_u16bit (from func_getu16bit);
 
354
              global_s32bit :=  RESULT_S32BIT
 
355
              global_bigstring := object_bigstring
 
356
              global_s64bit := x;
 
357
  }
 
358
  function tnovmtobject.func_array_mixed_nested(b: byte): tsmallarray;saveregisters;
 
359
 
 
360
    procedure nested_one_proc(l: longint);
 
361
     begin
 
362
       global_u16bit := func_getu16bit;
 
363
       global_s32bit := l;
 
364
     end;
 
365
 
 
366
    procedure nested_two_proc(l : longint);
 
367
     begin
 
368
       global_s64bit := l;
 
369
     end;
 
370
 
 
371
 
 
372
 
 
373
   function nested_one_func(level1_b : byte; s: shortstring): byte;
 
374
     var
 
375
      s1 : shortstring;
 
376
 
 
377
      function nested_two_func(level2_b : byte; s :shortstring): byte;
 
378
        begin
 
379
          nested_two_func:=level2_b;
 
380
          global_bigstring := s;
 
381
          nested_one_proc(RESULT_S32BIT);
 
382
        end;
 
383
 
 
384
    begin
 
385
      s1:=s;
 
386
      nested_one_func := nested_two_func(level1_b,s1);
 
387
      nested_two_proc(level1_b);
 
388
    end;
 
389
 
 
390
 
 
391
 var
 
392
  local_b: byte;
 
393
  smallarray: tsmallarray;
 
394
 begin
 
395
  fillchar(smallarray, sizeof(smallarray), #0);
 
396
  smallarray[1] := RESULT_U8BIT;
 
397
  smallarray[SMALL_INDEX] := RESULT_U8BIT;
 
398
  func_array_mixed_nested := smallarray;
 
399
  local_b:=b;
 
400
  global_u8bit := nested_one_func(local_b, object_bigstring);
 
401
 end;
 
402
 
 
403
{**************************************************************************}
 
404
{                             FAILED OBJECT                                }
 
405
{**************************************************************************}
 
406
constructor tfailvmtobject.constructor_public_none;
 
407
 begin
 
408
    { this calls the constructor fail special keyword }
 
409
    fail;
 
410
 end;
 
411
 
 
412
{**************************************************************************}
 
413
{                               VMT  OBJECT                                }
 
414
{**************************************************************************}
 
415
constructor tvmtobject.constructor_params_mixed(u8 :byte; u16: word;
 
416
   bigstring: shortstring; s32: longint; s64: int64);
 
417
 begin
 
418
   object_u8bit := u8;
 
419
   object_u16bit := u16;
 
420
   object_bigstring := bigstring;
 
421
   object_s32bit := s32;
 
422
   object_s64bit := s64;
 
423
 end;
 
424
 
 
425
 
 
426
constructor tvmtobject.constructor_init;
 
427
 begin
 
428
   object_u8bit := 0;
 
429
   object_u16bit := 0;
 
430
   object_bigstring := '';
 
431
   object_s32bit := 0;
 
432
   object_s64bit := 0;
 
433
 end;
 
434
 
 
435
destructor tvmtobject.destructor_params_done;
 
436
 begin
 
437
   object_u8bit := 0;
 
438
   object_u16bit := 0;
 
439
   object_bigstring := '';
 
440
   object_s32bit := 0;
 
441
   object_s64bit := 0;
 
442
 end;
 
443
 
 
444
 
 
445
procedure tvmtobject.method_normal_params_mixed(
 
446
    u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
447
 begin
 
448
   object_u8bit := u8;
 
449
   object_u16bit := u16;
 
450
   object_bigstring := bigstring;
 
451
   object_s32bit := s32;
 
452
   object_s64bit := s64;
 
453
 end;
 
454
 
 
455
procedure tvmtobject.method_virtual_params_mixed(
 
456
    u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
457
 begin
 
458
   object_u8bit := u8;
 
459
   object_u16bit := u16;
 
460
   object_bigstring := bigstring;
 
461
   object_s32bit := s32;
 
462
   object_s64bit := s64;
 
463
 end;
 
464
 
 
465
{ this one should be overriden }
 
466
procedure tvmtobject.method_virtual_overriden_params_mixed(
 
467
    u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
468
 begin
 
469
    RunError(211);
 
470
 end;
 
471
 
 
472
{ can't access field of instances in static methods }
 
473
procedure tvmtobject.method_static_params_mixed(
 
474
    u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
475
 begin
 
476
   global_u8bit := u8;
 
477
   global_u16bit := u16;
 
478
   global_bigstring := bigstring;
 
479
   global_s32bit := s32;
 
480
   global_s64bit := s64;
 
481
 end;
 
482
 
 
483
procedure tvmtobject.method_normal_call_inherited_params_mixed(
 
484
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
485
  begin
 
486
   object_u8bit := u8;
 
487
   object_u16bit := u16;
 
488
   object_bigstring := bigstring;
 
489
   object_s32bit := s32;
 
490
   object_s64bit := s64;
 
491
  end;
 
492
 
 
493
 
 
494
procedure tvmtobject.method_virtual_call_static_params_mixed(
 
495
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
496
  begin
 
497
    method_static_params_mixed(u8, u16, bigstring, s32, s64);
 
498
  end;
 
499
 
 
500
procedure tvmtobject.method_virtual_call_virtual_params_mixed(
 
501
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
502
   begin
 
503
    method_virtual_params_mixed(u8, u16, bigstring, s32, s64);
 
504
   end;
 
505
 
 
506
procedure tvmtobject.method_virtual_call_overriden_params_mixed(
 
507
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
508
   begin
 
509
    method_virtual_overriden_params_mixed(u8, u16, bigstring, s32, s64);
 
510
   end;
 
511
 
 
512
 
 
513
procedure tvmtobject.method_virtual_call_normal_params_mixed(
 
514
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
515
   begin
 
516
    method_normal_params_mixed(u8, u16, bigstring, s32, s64);
 
517
   end;
 
518
 
 
519
procedure tvmtobject.method_virtual_call_constructor_params_mixed(
 
520
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
521
   begin
 
522
     constructor_params_mixed(u8, u16, bigstring, s32, s64);
 
523
   end;
 
524
 
 
525
procedure tvmtobject.method_virtual_call_inherited_params_mixed(
 
526
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
527
  begin
 
528
   object_u8bit := u8;
 
529
   object_u16bit := u16;
 
530
   object_bigstring := bigstring;
 
531
   object_s32bit := s32;
 
532
   object_s64bit := s64;
 
533
  end;
 
534
 
 
535
 
 
536
{**************************************************************************}
 
537
{                          INHERITED VMT OBJECT                            }
 
538
{**************************************************************************}
 
539
constructor theritedvmtobject.constructor_params_mixed_call_virtual(
 
540
   u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);
 
541
 begin
 
542
   object_u8bit := 0;
 
543
   object_u16bit := 0;
 
544
   object_bigstring := '';
 
545
   object_s32bit := 0;
 
546
   object_s64bit := 0;
 
547
   method_virtual_params_mixed(u8, u16, bigstring, s32, s64);
 
548
 end;
 
549
 
 
550
constructor theritedvmtobject.constructor_params_mixed_call_overriden(
 
551
   u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);
 
552
 begin
 
553
   object_u8bit := 0;
 
554
   object_u16bit := 0;
 
555
   object_bigstring := '';
 
556
   object_s32bit := 0;
 
557
   object_s64bit := 0;
 
558
   method_virtual_overriden_params_mixed(u8, u16, bigstring, s32, s64);
 
559
 end;
 
560
 
 
561
constructor theritedvmtobject.constructor_params_mixed_call_static(
 
562
    u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);
 
563
 begin
 
564
   object_u8bit := 0;
 
565
   object_u16bit := 0;
 
566
   object_bigstring := '';
 
567
   object_s32bit := 0;
 
568
   object_s64bit := 0;
 
569
   method_static_params_mixed(u8, u16, bigstring, s32, s64);
 
570
 end;
 
571
 
 
572
constructor theritedvmtobject.constructor_params_mixed_call_normal(
 
573
    u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);
 
574
 begin
 
575
   object_u8bit := 0;
 
576
   object_u16bit := 0;
 
577
   object_bigstring := '';
 
578
   object_s32bit := 0;
 
579
   object_s64bit := 0;
 
580
   method_normal_params_mixed(u8, u16, bigstring, s32, s64);
 
581
 end;
 
582
 
 
583
constructor theritedvmtobject.constructor_params_mixed_call_inherited
 
584
   (u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);
 
585
 begin
 
586
   object_u8bit := 0;
 
587
   object_u16bit := 0;
 
588
   object_bigstring := '';
 
589
   object_s32bit := 0;
 
590
   object_s64bit := 0;
 
591
   inherited constructor_params_mixed(u8, u16, bigstring, s32, s64);
 
592
 end;
 
593
 
 
594
{ this one should be overriden }
 
595
procedure theritedvmtobject.method_virtual_overriden_params_mixed(
 
596
    u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);
 
597
 begin
 
598
   object_u8bit := u8;
 
599
   object_u16bit := u16;
 
600
   object_bigstring := bigstring;
 
601
   object_s32bit := s32;
 
602
   object_s64bit := s64;
 
603
 end;
 
604
 
 
605
procedure theritedvmtobject.method_normal_call_static_params_mixed(
 
606
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
607
  begin
 
608
    method_static_params_mixed(u8, u16, bigstring, s32, s64);
 
609
  end;
 
610
 
 
611
procedure theritedvmtobject.method_normal_call_virtual_params_mixed(
 
612
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
613
   begin
 
614
    method_virtual_params_mixed(u8, u16, bigstring, s32, s64);
 
615
   end;
 
616
 
 
617
procedure theritedvmtobject.method_normal_call_overriden_params_mixed(
 
618
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
619
   begin
 
620
    method_virtual_overriden_params_mixed(u8, u16, bigstring, s32, s64);
 
621
   end;
 
622
 
 
623
 
 
624
procedure theritedvmtobject.method_normal_call_normal_params_mixed(
 
625
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
626
   begin
 
627
    method_normal_params_mixed(u8, u16, bigstring, s32, s64);
 
628
   end;
 
629
 
 
630
procedure theritedvmtobject.method_normal_call_constructor_params_mixed(
 
631
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
632
   begin
 
633
     constructor_params_mixed(u8, u16, bigstring, s32, s64);
 
634
   end;
 
635
 
 
636
procedure theritedvmtobject.method_normal_call_inherited_params_mixed(
 
637
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
638
  begin
 
639
   Inherited method_normal_call_inherited_params_mixed(u8, u16, bigstring,
 
640
     s32, s64);
 
641
  end;
 
642
 
 
643
procedure theritedvmtobject.method_virtual_call_inherited_params_mixed(
 
644
      u8 :byte; u16: word; bigstring: shortstring; s32: longint; s64: int64);saveregisters;
 
645
  begin
 
646
   Inherited method_virtual_call_inherited_params_mixed(u8, u16, bigstring,
 
647
     s32, s64);
 
648
  end;
 
649
 
 
650
 
 
651
procedure testnovmtobject;
 
652
var
 
653
  novmtobject : tnovmtobject;
 
654
  failed : boolean;
 
655
begin
 
656
  {******************** STATIC / METHOD SIMPLE CALL **********************}
 
657
  Write('No parameter / method call testing...');
 
658
  failed := false;
 
659
 
 
660
  clear_globals;
 
661
  clear_values;
 
662
 
 
663
  tnovmtobject.method_public_static_none;
 
664
  if global_u8bit <> RESULT_U8BIT then
 
665
    failed := true;
 
666
 
 
667
  clear_globals;
 
668
  clear_values;
 
669
  novmtobject.method_public_static_none;
 
670
  if global_u8bit <> RESULT_U8BIT then
 
671
    failed := true;
 
672
 
 
673
  clear_globals;
 
674
  clear_values;
 
675
 
 
676
  tnovmtobject.method_call_private_static_none;
 
677
  if global_u16bit <> RESULT_U8BIT then
 
678
    failed := true;
 
679
 
 
680
  clear_globals;
 
681
  clear_values;
 
682
 
 
683
  novmtobject.method_call_private_static_none;
 
684
  if global_u16bit <> RESULT_U8BIT then
 
685
    failed := true;
 
686
 
 
687
  clear_globals;
 
688
  clear_values;
 
689
 
 
690
  novmtobject.method_public_none;
 
691
  if global_u8bit <> RESULT_U8BIT then
 
692
    failed := true;
 
693
 
 
694
  clear_globals;
 
695
  clear_values;
 
696
 
 
697
  novmtobject.method_call_private_none;
 
698
  if global_u16bit <> (RESULT_U16BIT) then
 
699
    failed := true;
 
700
 
 
701
  if failed then
 
702
    fail
 
703
  else
 
704
    WriteLn('Passed!');
 
705
 
 
706
  Write('Simple parameter (LOC_CONSTANT) / method call testing...');
 
707
  failed := false;
 
708
 
 
709
  clear_globals;
 
710
  clear_values;
 
711
 
 
712
  { parameter is LOC_CONSTANT }
 
713
  novmtobject.method_public_u8(RESULT_U8BIT);
 
714
  if global_u8bit <> RESULT_U8BIT then
 
715
    failed := true;
 
716
 
 
717
  clear_globals;
 
718
  clear_values;
 
719
 
 
720
  tnovmtobject.method_public_static_u8(RESULT_U8BIT);
 
721
  if global_u8bit <> RESULT_U8BIT then
 
722
    failed := true;
 
723
 
 
724
  clear_globals;
 
725
  clear_values;
 
726
 
 
727
  novmtobject.method_public_static_u8(RESULT_U8BIT);
 
728
  if global_u8bit <> RESULT_U8BIT then
 
729
    failed := true;
 
730
 
 
731
  clear_globals;
 
732
  clear_values;
 
733
 
 
734
  novmtobject.method_call_private_u8(RESULT_U8BIT);
 
735
  if global_u16bit <> (RESULT_U16BIT) then
 
736
    failed := true;
 
737
 
 
738
  clear_globals;
 
739
  clear_values;
 
740
 
 
741
  novmtobject.method_call_private_static_u8(RESULT_U8BIT);
 
742
  if global_u16bit <> (RESULT_U8BIT) then
 
743
    failed := true;
 
744
 
 
745
 
 
746
  if failed then
 
747
    fail
 
748
  else
 
749
    WriteLn('Passed!');
 
750
 
 
751
 
 
752
  Write('Simple parameter (LOC_REFERENCE) / method call testing...');
 
753
  failed := false;
 
754
 
 
755
  clear_globals;
 
756
  clear_values;
 
757
 
 
758
  value_u8bit := RESULT_U8BIT;
 
759
  novmtobject.method_public_u8(value_u8bit);
 
760
  if global_u8bit <> RESULT_U8BIT then
 
761
    failed := true;
 
762
 
 
763
  clear_globals;
 
764
  clear_values;
 
765
 
 
766
  value_u8bit := RESULT_U8BIT;
 
767
  tnovmtobject.method_public_static_u8(value_u8bit);
 
768
  if global_u8bit <> RESULT_U8BIT then
 
769
    failed := true;
 
770
 
 
771
  clear_globals;
 
772
  clear_values;
 
773
 
 
774
  value_u8bit := RESULT_U8BIT;
 
775
  novmtobject.method_public_static_u8(value_u8bit);
 
776
  if global_u8bit <> RESULT_U8BIT then
 
777
    failed := true;
 
778
 
 
779
  clear_globals;
 
780
  clear_values;
 
781
 
 
782
  value_u8bit := RESULT_U8BIT;
 
783
  novmtobject.method_call_private_u8(value_u8bit);
 
784
  if global_u16bit <> (RESULT_U16BIT) then
 
785
    failed := true;
 
786
 
 
787
  clear_globals;
 
788
  clear_values;
 
789
 
 
790
  value_u8bit := RESULT_U8BIT;
 
791
  novmtobject.method_call_private_static_u8(value_u8bit);
 
792
  if global_u16bit <> (RESULT_U8BIT) then
 
793
    failed := true;
 
794
 
 
795
  if failed then
 
796
    fail
 
797
  else
 
798
    WriteLn('Passed!');
 
799
 
 
800
  Write('Simple parameter (LOC_REGISTER) / method call testing...');
 
801
  failed := false;
 
802
 
 
803
  clear_globals;
 
804
  clear_values;
 
805
 
 
806
  novmtobject.method_public_u8(getu8);
 
807
  if global_u8bit <> RESULT_U8BIT then
 
808
    failed := true;
 
809
 
 
810
  clear_globals;
 
811
  clear_values;
 
812
 
 
813
  tnovmtobject.method_public_static_u8(getu8);
 
814
  if global_u8bit <> RESULT_U8BIT then
 
815
    failed := true;
 
816
 
 
817
  clear_globals;
 
818
  clear_values;
 
819
 
 
820
  novmtobject.method_public_static_u8(getu8);
 
821
  if global_u8bit <> RESULT_U8BIT then
 
822
    failed := true;
 
823
 
 
824
  clear_globals;
 
825
  clear_values;
 
826
 
 
827
  novmtobject.method_call_private_u8(getu8);
 
828
  if global_u16bit <> (RESULT_U16BIT) then
 
829
    failed := true;
 
830
 
 
831
  clear_globals;
 
832
  clear_values;
 
833
 
 
834
  novmtobject.method_call_private_static_u8(getu8);
 
835
  if global_u16bit <> (RESULT_U8BIT) then
 
836
    failed := true;
 
837
 
 
838
 if failed then
 
839
   fail
 
840
 else
 
841
   WriteLn('Passed!');
 
842
 
 
843
  Write('Simple parameter / complex return / nested method access testing...');
 
844
 
 
845
  clear_globals;
 
846
  clear_values;
 
847
  failed := false;
 
848
  novmtobject.object_bigstring := RESULT_BIGSTRING;
 
849
  novmtobject.object_u16bit := RESULT_U16BIT;
 
850
 
 
851
  value_smallarray := novmtobject.func_array_mixed_nested(RESULT_U8BIT);
 
852
  if (value_smallarray[1] <> RESULT_U8BIT) or (value_smallarray[SMALL_INDEX] <> RESULT_U8BIT) then
 
853
    failed := true;
 
854
  if global_u8bit <> RESULT_U8BIT then
 
855
    failed := true;
 
856
  if global_bigstring <> RESULT_BIGSTRING then
 
857
    failed := true;
 
858
  if global_u16bit <> RESULT_U16BIT then
 
859
    failed := true;
 
860
  if global_s32bit <> RESULT_S32BIT then
 
861
    failed := true;
 
862
  if global_s64bit <> RESULT_U8BIT then
 
863
    failed := true;
 
864
 
 
865
  if failed then
 
866
    fail
 
867
  else
 
868
    WriteLn('Passed!');
 
869
end;
 
870
 
 
871
 
 
872
procedure testfailedobject;
 
873
var
 
874
  failedobject : tfailvmtobject;
 
875
 begin
 
876
  Write('Testing constructor return value...');
 
877
  if failedobject.constructor_public_none then
 
878
    fail
 
879
  else
 
880
    Writeln('Passed!');
 
881
 end;
 
882
 
 
883
 
 
884
 procedure testvmtobject;
 
885
  var
 
886
   vmtobject : tvmtobject;
 
887
   failed : boolean;
 
888
  begin
 
889
 
 
890
    clear_globals;
 
891
    clear_values;
 
892
    failed := false;
 
893
 
 
894
    Write('Testing mixed parameter (LOC_CONSTANT) constructor call...');
 
895
    vmtobject.constructor_params_mixed(RESULT_U8BIT, RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
896
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
897
      failed := true;
 
898
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
899
      failed := true;
 
900
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
901
      failed := true;
 
902
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
903
      failed := true;
 
904
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
905
      failed := true;
 
906
    vmtobject.destructor_params_done;
 
907
 
 
908
    if failed then
 
909
      fail
 
910
    else
 
911
      Writeln('Passed!');
 
912
 
 
913
    clear_globals;
 
914
    clear_values;
 
915
    failed := false;
 
916
 
 
917
    Write('Testing mixed parameter (LOC_REFERENCE) constructor call...');
 
918
    value_u8bit := RESULT_U8BIT;
 
919
    value_u16bit := RESULT_U16BIT;
 
920
    value_bigstring := RESULT_BIGSTRING;
 
921
    value_s32bit := RESULT_S32BIT;
 
922
    value_s64bit := RESULT_S64BIT;
 
923
    vmtobject.constructor_params_mixed(value_u8bit, value_u16bit, value_bigstring,
 
924
       value_s32bit, value_s64bit);
 
925
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
926
      failed := true;
 
927
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
928
      failed := true;
 
929
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
930
      failed := true;
 
931
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
932
      failed := true;
 
933
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
934
      failed := true;
 
935
    vmtobject.destructor_params_done;
 
936
 
 
937
    if failed then
 
938
      fail
 
939
    else
 
940
      Writeln('Passed!');
 
941
 
 
942
  end;
 
943
 
 
944
 
 
945
 procedure testheritedvmtobject;
 
946
  var
 
947
   vmtobject : theritedvmtobject;
 
948
   failed : boolean;
 
949
  begin
 
950
    {********************** CONSTRUCTOR TESTING ************************}
 
951
    {********************** DESTRUCTOR  TESTING ************************}
 
952
    clear_globals;
 
953
    clear_values;
 
954
    failed := false;
 
955
 
 
956
    Write('Testing mixed parameter (LOC_CONSTANT) inherited constructor call...');
 
957
    vmtobject.constructor_params_mixed_call_inherited(RESULT_U8BIT, RESULT_U16BIT, RESULT_BIGSTRING,
 
958
       RESULT_S32BIT, RESULT_S64BIT);
 
959
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
960
      failed := true;
 
961
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
962
      failed := true;
 
963
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
964
      failed := true;
 
965
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
966
      failed := true;
 
967
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
968
      failed := true;
 
969
    vmtobject.destructor_params_done;
 
970
 
 
971
    if failed then
 
972
      fail
 
973
    else
 
974
      Writeln('Passed!');
 
975
 
 
976
    clear_globals;
 
977
    clear_values;
 
978
    failed := false;
 
979
 
 
980
    Write('Testing mixed parameter (LOC_REFERENCE) inherited constructor call...');
 
981
    value_u8bit := RESULT_U8BIT;
 
982
    value_u16bit := RESULT_U16BIT;
 
983
    value_bigstring := RESULT_BIGSTRING;
 
984
    value_s32bit := RESULT_S32BIT;
 
985
    value_s64bit := RESULT_S64BIT;
 
986
    vmtobject.constructor_params_mixed_call_inherited(value_u8bit,
 
987
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
988
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
989
      failed := true;
 
990
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
991
      failed := true;
 
992
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
993
      failed := true;
 
994
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
995
      failed := true;
 
996
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
997
      failed := true;
 
998
    vmtobject.destructor_params_done;
 
999
 
 
1000
    if failed then
 
1001
      fail
 
1002
    else
 
1003
      Writeln('Passed!');
 
1004
 
 
1005
    clear_globals;
 
1006
    clear_values;
 
1007
    failed := false;
 
1008
 
 
1009
    Write('Testing mixed parameter (LOC_CONSTANT) constructor call w/virtual call...');
 
1010
    vmtobject.constructor_params_mixed_call_virtual(RESULT_U8BIT,
 
1011
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1012
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1013
      failed := true;
 
1014
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1015
      failed := true;
 
1016
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1017
      failed := true;
 
1018
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1019
      failed := true;
 
1020
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1021
      failed := true;
 
1022
    vmtobject.destructor_params_done;
 
1023
 
 
1024
    if failed then
 
1025
      fail
 
1026
    else
 
1027
      Writeln('Passed!');
 
1028
 
 
1029
    clear_globals;
 
1030
    clear_values;
 
1031
    failed := false;
 
1032
 
 
1033
    Write('Testing mixed parameter (LOC_REFERENCE) constructor call w/virtual call...');
 
1034
    value_u8bit := RESULT_U8BIT;
 
1035
    value_u16bit := RESULT_U16BIT;
 
1036
    value_bigstring := RESULT_BIGSTRING;
 
1037
    value_s32bit := RESULT_S32BIT;
 
1038
    value_s64bit := RESULT_S64BIT;
 
1039
    vmtobject.constructor_params_mixed_call_virtual(value_u8bit,
 
1040
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1041
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1042
      failed := true;
 
1043
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1044
      failed := true;
 
1045
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1046
      failed := true;
 
1047
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1048
      failed := true;
 
1049
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1050
      failed := true;
 
1051
    vmtobject.destructor_params_done;
 
1052
 
 
1053
    if failed then
 
1054
      fail
 
1055
    else
 
1056
      Writeln('Passed!');
 
1057
 
 
1058
    clear_globals;
 
1059
    clear_values;
 
1060
    failed := false;
 
1061
 
 
1062
    Write('Testing mixed parameter (LOC_CONSTANT) constructor call w/virtual call...');
 
1063
    vmtobject.constructor_params_mixed_call_overriden(RESULT_U8BIT,
 
1064
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1065
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1066
      failed := true;
 
1067
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1068
      failed := true;
 
1069
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1070
      failed := true;
 
1071
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1072
      failed := true;
 
1073
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1074
      failed := true;
 
1075
    vmtobject.destructor_params_done;
 
1076
 
 
1077
    if failed then
 
1078
      fail
 
1079
    else
 
1080
      Writeln('Passed!');
 
1081
 
 
1082
    clear_globals;
 
1083
    clear_values;
 
1084
    failed := false;
 
1085
 
 
1086
    Write('Testing mixed parameter (LOC_REFERENCE) constructor call w/virtual call...');
 
1087
    value_u8bit := RESULT_U8BIT;
 
1088
    value_u16bit := RESULT_U16BIT;
 
1089
    value_bigstring := RESULT_BIGSTRING;
 
1090
    value_s32bit := RESULT_S32BIT;
 
1091
    value_s64bit := RESULT_S64BIT;
 
1092
    vmtobject.constructor_params_mixed_call_overriden(value_u8bit,
 
1093
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1094
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1095
      failed := true;
 
1096
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1097
      failed := true;
 
1098
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1099
      failed := true;
 
1100
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1101
      failed := true;
 
1102
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1103
      failed := true;
 
1104
    vmtobject.destructor_params_done;
 
1105
 
 
1106
    if failed then
 
1107
      fail
 
1108
    else
 
1109
      Writeln('Passed!');
 
1110
 
 
1111
    clear_globals;
 
1112
    clear_values;
 
1113
    failed := false;
 
1114
 
 
1115
    Write('Testing mixed parameter (LOC_CONSTANT) constructor call w/method call...');
 
1116
    vmtobject.constructor_params_mixed_call_normal(RESULT_U8BIT,
 
1117
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1118
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1119
      failed := true;
 
1120
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1121
      failed := true;
 
1122
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1123
      failed := true;
 
1124
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1125
      failed := true;
 
1126
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1127
      failed := true;
 
1128
    vmtobject.destructor_params_done;
 
1129
 
 
1130
    if failed then
 
1131
      fail
 
1132
    else
 
1133
      Writeln('Passed!');
 
1134
 
 
1135
    clear_globals;
 
1136
    clear_values;
 
1137
    failed := false;
 
1138
 
 
1139
    Write('Testing mixed parameter (LOC_REFERENCE) constructor call w/method call...');
 
1140
    value_u8bit := RESULT_U8BIT;
 
1141
    value_u16bit := RESULT_U16BIT;
 
1142
    value_bigstring := RESULT_BIGSTRING;
 
1143
    value_s32bit := RESULT_S32BIT;
 
1144
    value_s64bit := RESULT_S64BIT;
 
1145
    vmtobject.constructor_params_mixed_call_normal(value_u8bit,
 
1146
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1147
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1148
      failed := true;
 
1149
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1150
      failed := true;
 
1151
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1152
      failed := true;
 
1153
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1154
      failed := true;
 
1155
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1156
      failed := true;
 
1157
    vmtobject.destructor_params_done;
 
1158
 
 
1159
    if failed then
 
1160
      fail
 
1161
    else
 
1162
      Writeln('Passed!');
 
1163
 
 
1164
    clear_globals;
 
1165
    clear_values;
 
1166
    failed := false;
 
1167
 
 
1168
    Write('Testing mixed parameter (LOC_CONSTANT) constructor call w/static call...');
 
1169
    vmtobject.constructor_params_mixed_call_static(RESULT_U8BIT,
 
1170
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1171
    if global_u8bit <> RESULT_U8BIT then
 
1172
      failed := true;
 
1173
    if global_u16bit <> RESULT_U16BIT then
 
1174
      failed := true;
 
1175
    if global_s32bit <> RESULT_S32BIT then
 
1176
      failed := true;
 
1177
    if global_s64bit <> RESULT_S64BIT then
 
1178
      failed := true;
 
1179
    if global_bigstring <> RESULT_BIGSTRING then
 
1180
      failed := true;
 
1181
    vmtobject.destructor_params_done;
 
1182
 
 
1183
    if failed then
 
1184
      fail
 
1185
    else
 
1186
      Writeln('Passed!');
 
1187
 
 
1188
    clear_globals;
 
1189
    clear_values;
 
1190
    failed := false;
 
1191
 
 
1192
    Write('Testing mixed parameter (LOC_REFERENCE) constructor call w/static call...');
 
1193
    value_u8bit := RESULT_U8BIT;
 
1194
    value_u16bit := RESULT_U16BIT;
 
1195
    value_bigstring := RESULT_BIGSTRING;
 
1196
    value_s32bit := RESULT_S32BIT;
 
1197
    value_s64bit := RESULT_S64BIT;
 
1198
    vmtobject.constructor_params_mixed_call_static(value_u8bit,
 
1199
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1200
    if global_u8bit <> RESULT_U8BIT then
 
1201
      failed := true;
 
1202
    if global_u16bit <> RESULT_U16BIT then
 
1203
      failed := true;
 
1204
    if global_s32bit <> RESULT_S32BIT then
 
1205
      failed := true;
 
1206
    if global_s64bit <> RESULT_S64BIT then
 
1207
      failed := true;
 
1208
    if global_bigstring <> RESULT_BIGSTRING then
 
1209
      failed := true;
 
1210
    vmtobject.destructor_params_done;
 
1211
 
 
1212
    if failed then
 
1213
      fail
 
1214
    else
 
1215
      Writeln('Passed!');
 
1216
 
 
1217
    {************************* METHOD TESTING **************************}
 
1218
    clear_globals;
 
1219
    clear_values;
 
1220
    failed := false;
 
1221
 
 
1222
    vmtobject.constructor_init;
 
1223
    Write('Testing mixed parameter (LOC_CONSTANT) virtual method call...');
 
1224
    vmtobject.method_virtual_params_mixed(RESULT_U8BIT,
 
1225
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1226
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1227
      failed := true;
 
1228
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1229
      failed := true;
 
1230
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1231
      failed := true;
 
1232
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1233
      failed := true;
 
1234
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1235
      failed := true;
 
1236
    vmtobject.destructor_params_done;
 
1237
 
 
1238
    if failed then
 
1239
      fail
 
1240
    else
 
1241
      Writeln('Passed!');
 
1242
 
 
1243
    clear_globals;
 
1244
    clear_values;
 
1245
    failed := false;
 
1246
 
 
1247
    vmtobject.constructor_init;
 
1248
    Write('Testing mixed parameter (LOC_REFERENCE) virtual method call...');
 
1249
    value_u8bit := RESULT_U8BIT;
 
1250
    value_u16bit := RESULT_U16BIT;
 
1251
    value_bigstring := RESULT_BIGSTRING;
 
1252
    value_s32bit := RESULT_S32BIT;
 
1253
    value_s64bit := RESULT_S64BIT;
 
1254
    vmtobject.method_virtual_params_mixed(value_u8bit,
 
1255
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1256
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1257
      failed := true;
 
1258
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1259
      failed := true;
 
1260
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1261
      failed := true;
 
1262
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1263
      failed := true;
 
1264
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1265
      failed := true;
 
1266
    vmtobject.destructor_params_done;
 
1267
 
 
1268
    if failed then
 
1269
      fail
 
1270
    else
 
1271
      Writeln('Passed!');
 
1272
 
 
1273
    clear_globals;
 
1274
    clear_values;
 
1275
    failed := false;
 
1276
 
 
1277
    vmtobject.constructor_init;
 
1278
    Write('Testing mixed parameter (LOC_CONSTANT) virtual method call...');
 
1279
    vmtobject.method_virtual_overriden_params_mixed(RESULT_U8BIT,
 
1280
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1281
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1282
      failed := true;
 
1283
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1284
      failed := true;
 
1285
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1286
      failed := true;
 
1287
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1288
      failed := true;
 
1289
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1290
      failed := true;
 
1291
    vmtobject.destructor_params_done;
 
1292
 
 
1293
    if failed then
 
1294
      fail
 
1295
    else
 
1296
      Writeln('Passed!');
 
1297
 
 
1298
    clear_globals;
 
1299
    clear_values;
 
1300
    failed := false;
 
1301
 
 
1302
    vmtobject.constructor_init;
 
1303
    Write('Testing mixed parameter (LOC_REFERENCE) virtual method call...');
 
1304
    value_u8bit := RESULT_U8BIT;
 
1305
    value_u16bit := RESULT_U16BIT;
 
1306
    value_bigstring := RESULT_BIGSTRING;
 
1307
    value_s32bit := RESULT_S32BIT;
 
1308
    value_s64bit := RESULT_S64BIT;
 
1309
    vmtobject.method_virtual_overriden_params_mixed(value_u8bit,
 
1310
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1311
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1312
      failed := true;
 
1313
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1314
      failed := true;
 
1315
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1316
      failed := true;
 
1317
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1318
      failed := true;
 
1319
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1320
      failed := true;
 
1321
    vmtobject.destructor_params_done;
 
1322
 
 
1323
    if failed then
 
1324
      fail
 
1325
    else
 
1326
      Writeln('Passed!');
 
1327
 
 
1328
    clear_globals;
 
1329
    clear_values;
 
1330
    failed := false;
 
1331
 
 
1332
    vmtobject.constructor_init;
 
1333
    Write('Testing mixed parameter (LOC_CONSTANT) method call...');
 
1334
    vmtobject.method_normal_params_mixed(RESULT_U8BIT,
 
1335
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1336
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1337
      failed := true;
 
1338
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1339
      failed := true;
 
1340
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1341
      failed := true;
 
1342
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1343
      failed := true;
 
1344
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1345
      failed := true;
 
1346
    vmtobject.destructor_params_done;
 
1347
 
 
1348
    if failed then
 
1349
      fail
 
1350
    else
 
1351
      Writeln('Passed!');
 
1352
 
 
1353
    clear_globals;
 
1354
    clear_values;
 
1355
    failed := false;
 
1356
 
 
1357
    vmtobject.constructor_init;
 
1358
    Write('Testing mixed parameter (LOC_REFERENCE) method call...');
 
1359
    value_u8bit := RESULT_U8BIT;
 
1360
    value_u16bit := RESULT_U16BIT;
 
1361
    value_bigstring := RESULT_BIGSTRING;
 
1362
    value_s32bit := RESULT_S32BIT;
 
1363
    value_s64bit := RESULT_S64BIT;
 
1364
    vmtobject.method_normal_params_mixed(value_u8bit,
 
1365
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1366
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1367
      failed := true;
 
1368
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1369
      failed := true;
 
1370
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1371
      failed := true;
 
1372
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1373
      failed := true;
 
1374
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1375
      failed := true;
 
1376
    vmtobject.destructor_params_done;
 
1377
 
 
1378
    if failed then
 
1379
      fail
 
1380
    else
 
1381
      Writeln('Passed!');
 
1382
 
 
1383
    clear_globals;
 
1384
    clear_values;
 
1385
    failed := false;
 
1386
 
 
1387
    vmtobject.constructor_init;
 
1388
    Write('Testing mixed parameter (LOC_CONSTANT) static method call...');
 
1389
    vmtobject.method_static_params_mixed(RESULT_U8BIT,
 
1390
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1391
    if global_u8bit <> RESULT_U8BIT then
 
1392
      failed := true;
 
1393
    if global_u16bit <> RESULT_U16BIT then
 
1394
      failed := true;
 
1395
    if global_s32bit <> RESULT_S32BIT then
 
1396
      failed := true;
 
1397
    if global_s64bit <> RESULT_S64BIT then
 
1398
      failed := true;
 
1399
    if global_bigstring <> RESULT_BIGSTRING then
 
1400
      failed := true;
 
1401
    vmtobject.destructor_params_done;
 
1402
 
 
1403
    if failed then
 
1404
      fail
 
1405
    else
 
1406
      Writeln('Passed!');
 
1407
 
 
1408
    clear_globals;
 
1409
    clear_values;
 
1410
    failed := false;
 
1411
 
 
1412
    vmtobject.constructor_init;
 
1413
    Write('Testing mixed parameter (LOC_REFERENCE) static method call...');
 
1414
    value_u8bit := RESULT_U8BIT;
 
1415
    value_u16bit := RESULT_U16BIT;
 
1416
    value_bigstring := RESULT_BIGSTRING;
 
1417
    value_s32bit := RESULT_S32BIT;
 
1418
    value_s64bit := RESULT_S64BIT;
 
1419
    vmtobject.method_static_params_mixed(value_u8bit,
 
1420
      value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1421
    if global_u8bit <> RESULT_U8BIT then
 
1422
      failed := true;
 
1423
    if global_u16bit <> RESULT_U16BIT then
 
1424
      failed := true;
 
1425
    if global_s32bit <> RESULT_S32BIT then
 
1426
      failed := true;
 
1427
    if global_s64bit <> RESULT_S64BIT then
 
1428
      failed := true;
 
1429
    if global_bigstring <> RESULT_BIGSTRING then
 
1430
      failed := true;
 
1431
    vmtobject.destructor_params_done;
 
1432
 
 
1433
    if failed then
 
1434
      fail
 
1435
    else
 
1436
      Writeln('Passed!');
 
1437
 
 
1438
    { ********************************************************************
 
1439
      This calls methods which in turn call other methods, or a constructor
 
1440
      or a destructor.
 
1441
      *********************************************************************
 
1442
    }
 
1443
    clear_globals;
 
1444
    clear_values;
 
1445
    failed := false;
 
1446
    { Calls the ancestor virtual method }
 
1447
    vmtobject.constructor_init;
 
1448
    Write('Testing mixed parameter (LOC_CONSTANT) method call w/virtual call...');
 
1449
    vmtobject.method_normal_call_virtual_params_mixed(RESULT_U8BIT,
 
1450
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1451
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1452
      failed := true;
 
1453
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1454
      failed := true;
 
1455
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1456
      failed := true;
 
1457
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1458
      failed := true;
 
1459
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1460
      failed := true;
 
1461
    vmtobject.destructor_params_done;
 
1462
 
 
1463
    if failed then
 
1464
      fail
 
1465
    else
 
1466
      Writeln('Passed!');
 
1467
 
 
1468
    clear_globals;
 
1469
    clear_values;
 
1470
    failed := false;
 
1471
 
 
1472
    vmtobject.constructor_init;
 
1473
    Write('Testing mixed parameter (LOC_REFERENCE) method call w/virtual call...');
 
1474
    value_u8bit := RESULT_U8BIT;
 
1475
    value_u16bit := RESULT_U16BIT;
 
1476
    value_bigstring := RESULT_BIGSTRING;
 
1477
    value_s32bit := RESULT_S32BIT;
 
1478
    value_s64bit := RESULT_S64BIT;
 
1479
    vmtobject.method_normal_call_virtual_params_mixed(value_u8bit,
 
1480
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1481
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1482
      failed := true;
 
1483
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1484
      failed := true;
 
1485
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1486
      failed := true;
 
1487
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1488
      failed := true;
 
1489
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1490
      failed := true;
 
1491
    vmtobject.destructor_params_done;
 
1492
 
 
1493
    if failed then
 
1494
      fail
 
1495
    else
 
1496
      Writeln('Passed!');
 
1497
 
 
1498
    { The virtual method has been overriden by the object in this case }
 
1499
    vmtobject.constructor_init;
 
1500
    Write('Testing mixed parameter (LOC_CONSTANT) method call w/virtual call...');
 
1501
    vmtobject.method_normal_call_overriden_params_mixed(RESULT_U8BIT,
 
1502
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1503
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1504
      failed := true;
 
1505
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1506
      failed := true;
 
1507
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1508
      failed := true;
 
1509
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1510
      failed := true;
 
1511
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1512
      failed := true;
 
1513
    vmtobject.destructor_params_done;
 
1514
 
 
1515
    if failed then
 
1516
      fail
 
1517
    else
 
1518
      Writeln('Passed!');
 
1519
 
 
1520
    clear_globals;
 
1521
    clear_values;
 
1522
    failed := false;
 
1523
 
 
1524
    vmtobject.constructor_init;
 
1525
    Write('Testing mixed parameter (LOC_REFERENCE) method call w/virtual call...');
 
1526
    value_u8bit := RESULT_U8BIT;
 
1527
    value_u16bit := RESULT_U16BIT;
 
1528
    value_bigstring := RESULT_BIGSTRING;
 
1529
    value_s32bit := RESULT_S32BIT;
 
1530
    value_s64bit := RESULT_S64BIT;
 
1531
    vmtobject.method_normal_call_overriden_params_mixed(value_u8bit,
 
1532
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1533
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1534
      failed := true;
 
1535
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1536
      failed := true;
 
1537
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1538
      failed := true;
 
1539
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1540
      failed := true;
 
1541
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1542
      failed := true;
 
1543
    vmtobject.destructor_params_done;
 
1544
 
 
1545
    if failed then
 
1546
      fail
 
1547
    else
 
1548
      Writeln('Passed!');
 
1549
 
 
1550
    clear_globals;
 
1551
    clear_values;
 
1552
    failed := false;
 
1553
 
 
1554
    vmtobject.constructor_init;
 
1555
    Write('Testing mixed parameter (LOC_CONSTANT) method call w/normal call...');
 
1556
    vmtobject.method_normal_call_normal_params_mixed(RESULT_U8BIT,
 
1557
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1558
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1559
      failed := true;
 
1560
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1561
      failed := true;
 
1562
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1563
      failed := true;
 
1564
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1565
      failed := true;
 
1566
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1567
      failed := true;
 
1568
    vmtobject.destructor_params_done;
 
1569
 
 
1570
    if failed then
 
1571
      fail
 
1572
    else
 
1573
      Writeln('Passed!');
 
1574
 
 
1575
    clear_globals;
 
1576
    clear_values;
 
1577
    failed := false;
 
1578
 
 
1579
    vmtobject.constructor_init;
 
1580
    Write('Testing mixed parameter (LOC_REFERENCE) method call w/normal call...');
 
1581
    value_u8bit := RESULT_U8BIT;
 
1582
    value_u16bit := RESULT_U16BIT;
 
1583
    value_bigstring := RESULT_BIGSTRING;
 
1584
    value_s32bit := RESULT_S32BIT;
 
1585
    value_s64bit := RESULT_S64BIT;
 
1586
    vmtobject.method_normal_call_normal_params_mixed(value_u8bit,
 
1587
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1588
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1589
      failed := true;
 
1590
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1591
      failed := true;
 
1592
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1593
      failed := true;
 
1594
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1595
      failed := true;
 
1596
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1597
      failed := true;
 
1598
    vmtobject.destructor_params_done;
 
1599
 
 
1600
    if failed then
 
1601
      fail
 
1602
    else
 
1603
      Writeln('Passed!');
 
1604
 
 
1605
    (* constructor call inside a normal method *)
 
1606
 
 
1607
    clear_globals;
 
1608
    clear_values;
 
1609
    failed := false;
 
1610
 
 
1611
    vmtobject.constructor_init;
 
1612
    Write('Testing mixed parameter (LOC_CONSTANT) method call w/constructor call...');
 
1613
    vmtobject.method_normal_call_constructor_params_mixed(RESULT_U8BIT,
 
1614
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1615
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1616
      failed := true;
 
1617
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1618
      failed := true;
 
1619
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1620
      failed := true;
 
1621
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1622
      failed := true;
 
1623
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1624
      failed := true;
 
1625
    vmtobject.destructor_params_done;
 
1626
 
 
1627
    if failed then
 
1628
      fail
 
1629
    else
 
1630
      Writeln('Passed!');
 
1631
 
 
1632
    clear_globals;
 
1633
    clear_values;
 
1634
    failed := false;
 
1635
 
 
1636
    vmtobject.constructor_init;
 
1637
    Write('Testing mixed parameter (LOC_REFERENCE) method call w/constructor call...');
 
1638
    value_u8bit := RESULT_U8BIT;
 
1639
    value_u16bit := RESULT_U16BIT;
 
1640
    value_bigstring := RESULT_BIGSTRING;
 
1641
    value_s32bit := RESULT_S32BIT;
 
1642
    value_s64bit := RESULT_S64BIT;
 
1643
    vmtobject.method_normal_call_constructor_params_mixed(value_u8bit,
 
1644
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1645
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1646
      failed := true;
 
1647
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1648
      failed := true;
 
1649
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1650
      failed := true;
 
1651
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1652
      failed := true;
 
1653
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1654
      failed := true;
 
1655
    vmtobject.destructor_params_done;
 
1656
 
 
1657
    if failed then
 
1658
      fail
 
1659
    else
 
1660
      Writeln('Passed!');
 
1661
 
 
1662
    { static method call }
 
1663
    clear_globals;
 
1664
    clear_values;
 
1665
    failed := false;
 
1666
 
 
1667
    vmtobject.constructor_init;
 
1668
    Write('Testing mixed parameter (LOC_CONSTANT) method call w/static call...');
 
1669
    vmtobject.method_normal_call_static_params_mixed(RESULT_U8BIT,
 
1670
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1671
    if global_u8bit <> RESULT_U8BIT then
 
1672
      failed := true;
 
1673
    if global_u16bit <> RESULT_U16BIT then
 
1674
      failed := true;
 
1675
    if global_s32bit <> RESULT_S32BIT then
 
1676
      failed := true;
 
1677
    if global_s64bit <> RESULT_S64BIT then
 
1678
      failed := true;
 
1679
    if global_bigstring <> RESULT_BIGSTRING then
 
1680
      failed := true;
 
1681
    vmtobject.destructor_params_done;
 
1682
 
 
1683
    if failed then
 
1684
      fail
 
1685
    else
 
1686
      Writeln('Passed!');
 
1687
 
 
1688
    clear_globals;
 
1689
    clear_values;
 
1690
    failed := false;
 
1691
 
 
1692
    vmtobject.constructor_init;
 
1693
    Write('Testing mixed parameter (LOC_REFERENCE) method call w/static call...');
 
1694
    value_u8bit := RESULT_U8BIT;
 
1695
    value_u16bit := RESULT_U16BIT;
 
1696
    value_bigstring := RESULT_BIGSTRING;
 
1697
    value_s32bit := RESULT_S32BIT;
 
1698
    value_s64bit := RESULT_S64BIT;
 
1699
    vmtobject.method_normal_call_static_params_mixed(value_u8bit,
 
1700
      value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1701
    if global_u8bit <> RESULT_U8BIT then
 
1702
      failed := true;
 
1703
    if global_u16bit <> RESULT_U16BIT then
 
1704
      failed := true;
 
1705
    if global_s32bit <> RESULT_S32BIT then
 
1706
      failed := true;
 
1707
    if global_s64bit <> RESULT_S64BIT then
 
1708
      failed := true;
 
1709
    if global_bigstring <> RESULT_BIGSTRING then
 
1710
      failed := true;
 
1711
    vmtobject.destructor_params_done;
 
1712
 
 
1713
    if failed then
 
1714
      fail
 
1715
    else
 
1716
      Writeln('Passed!');
 
1717
 
 
1718
    (* calls the inherited method *)
 
1719
    clear_globals;
 
1720
    clear_values;
 
1721
    failed := false;
 
1722
    { Calls the ancestor virtual method }
 
1723
    vmtobject.constructor_init;
 
1724
    Write('Testing mixed parameter (LOC_CONSTANT) method call w/inherited call...');
 
1725
    vmtobject.method_normal_call_inherited_params_mixed(RESULT_U8BIT,
 
1726
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1727
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1728
      failed := true;
 
1729
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1730
      failed := true;
 
1731
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1732
      failed := true;
 
1733
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1734
      failed := true;
 
1735
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1736
      failed := true;
 
1737
    vmtobject.destructor_params_done;
 
1738
 
 
1739
    if failed then
 
1740
      fail
 
1741
    else
 
1742
      Writeln('Passed!');
 
1743
 
 
1744
    clear_globals;
 
1745
    clear_values;
 
1746
    failed := false;
 
1747
 
 
1748
    vmtobject.constructor_init;
 
1749
    Write('Testing mixed parameter (LOC_REFERENCE) method call w/inherited call...');
 
1750
    value_u8bit := RESULT_U8BIT;
 
1751
    value_u16bit := RESULT_U16BIT;
 
1752
    value_bigstring := RESULT_BIGSTRING;
 
1753
    value_s32bit := RESULT_S32BIT;
 
1754
    value_s64bit := RESULT_S64BIT;
 
1755
    vmtobject.method_normal_call_inherited_params_mixed(value_u8bit,
 
1756
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1757
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1758
      failed := true;
 
1759
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1760
      failed := true;
 
1761
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1762
      failed := true;
 
1763
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1764
      failed := true;
 
1765
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1766
      failed := true;
 
1767
    vmtobject.destructor_params_done;
 
1768
 
 
1769
    if failed then
 
1770
      fail
 
1771
    else
 
1772
      Writeln('Passed!');
 
1773
 
 
1774
 { ********************************************************************
 
1775
      This calls virtual methods which in turn call other methods,
 
1776
      or a constructor  or a destructor.
 
1777
   *********************************************************************
 
1778
    }
 
1779
    clear_globals;
 
1780
    clear_values;
 
1781
    failed := false;
 
1782
    { Calls the ancestor virtual method }
 
1783
    vmtobject.constructor_init;
 
1784
    Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/virtual call...');
 
1785
    vmtobject.method_virtual_call_virtual_params_mixed(RESULT_U8BIT,
 
1786
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1787
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1788
      failed := true;
 
1789
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1790
      failed := true;
 
1791
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1792
      failed := true;
 
1793
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1794
      failed := true;
 
1795
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1796
      failed := true;
 
1797
    vmtobject.destructor_params_done;
 
1798
 
 
1799
    if failed then
 
1800
      fail
 
1801
    else
 
1802
      Writeln('Passed!');
 
1803
 
 
1804
    clear_globals;
 
1805
    clear_values;
 
1806
    failed := false;
 
1807
 
 
1808
    vmtobject.constructor_init;
 
1809
    Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/virtual call...');
 
1810
    value_u8bit := RESULT_U8BIT;
 
1811
    value_u16bit := RESULT_U16BIT;
 
1812
    value_bigstring := RESULT_BIGSTRING;
 
1813
    value_s32bit := RESULT_S32BIT;
 
1814
    value_s64bit := RESULT_S64BIT;
 
1815
    vmtobject.method_virtual_call_virtual_params_mixed(value_u8bit,
 
1816
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1817
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1818
      failed := true;
 
1819
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1820
      failed := true;
 
1821
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1822
      failed := true;
 
1823
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1824
      failed := true;
 
1825
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1826
      failed := true;
 
1827
    vmtobject.destructor_params_done;
 
1828
 
 
1829
    if failed then
 
1830
      fail
 
1831
    else
 
1832
      Writeln('Passed!');
 
1833
 
 
1834
    { The virtual method has been overriden by the object in this case }
 
1835
    vmtobject.constructor_init;
 
1836
    Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/virtual call...');
 
1837
    vmtobject.method_virtual_call_overriden_params_mixed(RESULT_U8BIT,
 
1838
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1839
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1840
      failed := true;
 
1841
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1842
      failed := true;
 
1843
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1844
      failed := true;
 
1845
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1846
      failed := true;
 
1847
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1848
      failed := true;
 
1849
    vmtobject.destructor_params_done;
 
1850
 
 
1851
    if failed then
 
1852
      fail
 
1853
    else
 
1854
      Writeln('Passed!');
 
1855
 
 
1856
    clear_globals;
 
1857
    clear_values;
 
1858
    failed := false;
 
1859
 
 
1860
    vmtobject.constructor_init;
 
1861
    Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/virtual call...');
 
1862
    value_u8bit := RESULT_U8BIT;
 
1863
    value_u16bit := RESULT_U16BIT;
 
1864
    value_bigstring := RESULT_BIGSTRING;
 
1865
    value_s32bit := RESULT_S32BIT;
 
1866
    value_s64bit := RESULT_S64BIT;
 
1867
    vmtobject.method_virtual_call_overriden_params_mixed(value_u8bit,
 
1868
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1869
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1870
      failed := true;
 
1871
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1872
      failed := true;
 
1873
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1874
      failed := true;
 
1875
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1876
      failed := true;
 
1877
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1878
      failed := true;
 
1879
    vmtobject.destructor_params_done;
 
1880
 
 
1881
    if failed then
 
1882
      fail
 
1883
    else
 
1884
      Writeln('Passed!');
 
1885
 
 
1886
    clear_globals;
 
1887
    clear_values;
 
1888
    failed := false;
 
1889
 
 
1890
    vmtobject.constructor_init;
 
1891
    Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/normal call...');
 
1892
    vmtobject.method_virtual_call_normal_params_mixed(RESULT_U8BIT,
 
1893
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1894
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1895
      failed := true;
 
1896
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1897
      failed := true;
 
1898
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1899
      failed := true;
 
1900
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1901
      failed := true;
 
1902
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1903
      failed := true;
 
1904
    vmtobject.destructor_params_done;
 
1905
 
 
1906
    if failed then
 
1907
      fail
 
1908
    else
 
1909
      Writeln('Passed!');
 
1910
 
 
1911
    clear_globals;
 
1912
    clear_values;
 
1913
    failed := false;
 
1914
 
 
1915
    vmtobject.constructor_init;
 
1916
    Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/normal call...');
 
1917
    value_u8bit := RESULT_U8BIT;
 
1918
    value_u16bit := RESULT_U16BIT;
 
1919
    value_bigstring := RESULT_BIGSTRING;
 
1920
    value_s32bit := RESULT_S32BIT;
 
1921
    value_s64bit := RESULT_S64BIT;
 
1922
    vmtobject.method_virtual_call_normal_params_mixed(value_u8bit,
 
1923
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1924
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1925
      failed := true;
 
1926
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1927
      failed := true;
 
1928
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1929
      failed := true;
 
1930
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1931
      failed := true;
 
1932
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1933
      failed := true;
 
1934
    vmtobject.destructor_params_done;
 
1935
 
 
1936
    if failed then
 
1937
      fail
 
1938
    else
 
1939
      Writeln('Passed!');
 
1940
 
 
1941
    (* constructor call inside a normal method *)
 
1942
 
 
1943
    clear_globals;
 
1944
    clear_values;
 
1945
    failed := false;
 
1946
 
 
1947
    vmtobject.constructor_init;
 
1948
    Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/constructor call...');
 
1949
    vmtobject.method_virtual_call_constructor_params_mixed(RESULT_U8BIT,
 
1950
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
1951
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1952
      failed := true;
 
1953
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1954
      failed := true;
 
1955
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1956
      failed := true;
 
1957
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1958
      failed := true;
 
1959
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1960
      failed := true;
 
1961
    vmtobject.destructor_params_done;
 
1962
 
 
1963
    if failed then
 
1964
      fail
 
1965
    else
 
1966
      Writeln('Passed!');
 
1967
 
 
1968
    clear_globals;
 
1969
    clear_values;
 
1970
    failed := false;
 
1971
 
 
1972
    vmtobject.constructor_init;
 
1973
    Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/constructor call...');
 
1974
    value_u8bit := RESULT_U8BIT;
 
1975
    value_u16bit := RESULT_U16BIT;
 
1976
    value_bigstring := RESULT_BIGSTRING;
 
1977
    value_s32bit := RESULT_S32BIT;
 
1978
    value_s64bit := RESULT_S64BIT;
 
1979
    vmtobject.method_virtual_call_constructor_params_mixed(value_u8bit,
 
1980
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
1981
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
1982
      failed := true;
 
1983
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
1984
      failed := true;
 
1985
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
1986
      failed := true;
 
1987
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
1988
      failed := true;
 
1989
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
1990
      failed := true;
 
1991
    vmtobject.destructor_params_done;
 
1992
 
 
1993
    if failed then
 
1994
      fail
 
1995
    else
 
1996
      Writeln('Passed!');
 
1997
 
 
1998
    { static virtual call }
 
1999
    clear_globals;
 
2000
    clear_values;
 
2001
    failed := false;
 
2002
 
 
2003
    vmtobject.constructor_init;
 
2004
    Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/static call...');
 
2005
    vmtobject.method_virtual_call_static_params_mixed(RESULT_U8BIT,
 
2006
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2007
    if global_u8bit <> RESULT_U8BIT then
 
2008
      failed := true;
 
2009
    if global_u16bit <> RESULT_U16BIT then
 
2010
      failed := true;
 
2011
    if global_s32bit <> RESULT_S32BIT then
 
2012
      failed := true;
 
2013
    if global_s64bit <> RESULT_S64BIT then
 
2014
      failed := true;
 
2015
    if global_bigstring <> RESULT_BIGSTRING then
 
2016
      failed := true;
 
2017
    vmtobject.destructor_params_done;
 
2018
 
 
2019
    if failed then
 
2020
      fail
 
2021
    else
 
2022
      Writeln('Passed!');
 
2023
 
 
2024
    clear_globals;
 
2025
    clear_values;
 
2026
    failed := false;
 
2027
 
 
2028
    vmtobject.constructor_init;
 
2029
    Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/static call...');
 
2030
    value_u8bit := RESULT_U8BIT;
 
2031
    value_u16bit := RESULT_U16BIT;
 
2032
    value_bigstring := RESULT_BIGSTRING;
 
2033
    value_s32bit := RESULT_S32BIT;
 
2034
    value_s64bit := RESULT_S64BIT;
 
2035
    vmtobject.method_virtual_call_static_params_mixed(value_u8bit,
 
2036
      value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2037
    if global_u8bit <> RESULT_U8BIT then
 
2038
      failed := true;
 
2039
    if global_u16bit <> RESULT_U16BIT then
 
2040
      failed := true;
 
2041
    if global_s32bit <> RESULT_S32BIT then
 
2042
      failed := true;
 
2043
    if global_s64bit <> RESULT_S64BIT then
 
2044
      failed := true;
 
2045
    if global_bigstring <> RESULT_BIGSTRING then
 
2046
      failed := true;
 
2047
    vmtobject.destructor_params_done;
 
2048
 
 
2049
    if failed then
 
2050
      fail
 
2051
    else
 
2052
      Writeln('Passed!');
 
2053
 
 
2054
    (* calls the inherited method *)
 
2055
    clear_globals;
 
2056
    clear_values;
 
2057
    failed := false;
 
2058
    { Calls the ancestor virtual method }
 
2059
    vmtobject.constructor_init;
 
2060
    Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/inherited call...');
 
2061
    vmtobject.method_virtual_call_inherited_params_mixed(RESULT_U8BIT,
 
2062
       RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2063
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
2064
      failed := true;
 
2065
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
2066
      failed := true;
 
2067
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
2068
      failed := true;
 
2069
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
2070
      failed := true;
 
2071
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
2072
      failed := true;
 
2073
    vmtobject.destructor_params_done;
 
2074
 
 
2075
    if failed then
 
2076
      fail
 
2077
    else
 
2078
      Writeln('Passed!');
 
2079
 
 
2080
    clear_globals;
 
2081
    clear_values;
 
2082
    failed := false;
 
2083
 
 
2084
    vmtobject.constructor_init;
 
2085
    Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/inherited call...');
 
2086
    value_u8bit := RESULT_U8BIT;
 
2087
    value_u16bit := RESULT_U16BIT;
 
2088
    value_bigstring := RESULT_BIGSTRING;
 
2089
    value_s32bit := RESULT_S32BIT;
 
2090
    value_s64bit := RESULT_S64BIT;
 
2091
    vmtobject.method_virtual_call_inherited_params_mixed(value_u8bit,
 
2092
       value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2093
    if vmtobject.object_u8bit <> RESULT_U8BIT then
 
2094
      failed := true;
 
2095
    if vmtobject.object_u16bit <> RESULT_U16BIT then
 
2096
      failed := true;
 
2097
    if vmtobject.object_s32bit <> RESULT_S32BIT then
 
2098
      failed := true;
 
2099
    if vmtobject.object_s64bit <> RESULT_S64BIT then
 
2100
      failed := true;
 
2101
    if vmtobject.object_bigstring <> RESULT_BIGSTRING then
 
2102
      failed := true;
 
2103
    vmtobject.destructor_params_done;
 
2104
 
 
2105
    if failed then
 
2106
      fail
 
2107
    else
 
2108
      Writeln('Passed!');
 
2109
 
 
2110
 
 
2111
  end;
 
2112
 
 
2113
 
 
2114
  { same as testvmtherited, except uses with statement }
 
2115
  procedure testwith;
 
2116
  var
 
2117
   vmtobject : theritedvmtobject;
 
2118
   failed : boolean;
 
2119
  begin
 
2120
    with vmtobject do
 
2121
     begin
 
2122
        {********************** CONSTRUCTOR TESTING ************************}
 
2123
        {********************** DESTRUCTOR  TESTING ************************}
 
2124
        clear_globals;
 
2125
        clear_values;
 
2126
        failed := false;
 
2127
 
 
2128
        Write('Testing mixed parameter (LOC_CONSTANT) inherited constructor call...');
 
2129
        constructor_params_mixed_call_inherited(RESULT_U8BIT, RESULT_U16BIT, RESULT_BIGSTRING,
 
2130
           RESULT_S32BIT, RESULT_S64BIT);
 
2131
        if object_u8bit <> RESULT_U8BIT then
 
2132
          failed := true;
 
2133
        if object_u16bit <> RESULT_U16BIT then
 
2134
          failed := true;
 
2135
        if object_s32bit <> RESULT_S32BIT then
 
2136
          failed := true;
 
2137
        if object_s64bit <> RESULT_S64BIT then
 
2138
          failed := true;
 
2139
        if object_bigstring <> RESULT_BIGSTRING then
 
2140
          failed := true;
 
2141
        destructor_params_done;
 
2142
 
 
2143
        if failed then
 
2144
          fail
 
2145
        else
 
2146
          Writeln('Passed!');
 
2147
 
 
2148
        clear_globals;
 
2149
        clear_values;
 
2150
        failed := false;
 
2151
 
 
2152
        Write('Testing mixed parameter (LOC_REFERENCE) inherited constructor call...');
 
2153
        value_u8bit := RESULT_U8BIT;
 
2154
        value_u16bit := RESULT_U16BIT;
 
2155
        value_bigstring := RESULT_BIGSTRING;
 
2156
        value_s32bit := RESULT_S32BIT;
 
2157
        value_s64bit := RESULT_S64BIT;
 
2158
        constructor_params_mixed_call_inherited(value_u8bit,
 
2159
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2160
        if object_u8bit <> RESULT_U8BIT then
 
2161
          failed := true;
 
2162
        if object_u16bit <> RESULT_U16BIT then
 
2163
          failed := true;
 
2164
        if object_s32bit <> RESULT_S32BIT then
 
2165
          failed := true;
 
2166
        if object_s64bit <> RESULT_S64BIT then
 
2167
          failed := true;
 
2168
        if object_bigstring <> RESULT_BIGSTRING then
 
2169
          failed := true;
 
2170
        destructor_params_done;
 
2171
 
 
2172
        if failed then
 
2173
          fail
 
2174
        else
 
2175
          Writeln('Passed!');
 
2176
 
 
2177
        clear_globals;
 
2178
        clear_values;
 
2179
        failed := false;
 
2180
 
 
2181
        Write('Testing mixed parameter (LOC_CONSTANT) constructor call w/virtual call...');
 
2182
        constructor_params_mixed_call_virtual(RESULT_U8BIT,
 
2183
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2184
        if object_u8bit <> RESULT_U8BIT then
 
2185
          failed := true;
 
2186
        if object_u16bit <> RESULT_U16BIT then
 
2187
          failed := true;
 
2188
        if object_s32bit <> RESULT_S32BIT then
 
2189
          failed := true;
 
2190
        if object_s64bit <> RESULT_S64BIT then
 
2191
          failed := true;
 
2192
        if object_bigstring <> RESULT_BIGSTRING then
 
2193
          failed := true;
 
2194
        destructor_params_done;
 
2195
 
 
2196
        if failed then
 
2197
          fail
 
2198
        else
 
2199
          Writeln('Passed!');
 
2200
 
 
2201
        clear_globals;
 
2202
        clear_values;
 
2203
        failed := false;
 
2204
 
 
2205
        Write('Testing mixed parameter (LOC_REFERENCE) constructor call w/virtual call...');
 
2206
        value_u8bit := RESULT_U8BIT;
 
2207
        value_u16bit := RESULT_U16BIT;
 
2208
        value_bigstring := RESULT_BIGSTRING;
 
2209
        value_s32bit := RESULT_S32BIT;
 
2210
        value_s64bit := RESULT_S64BIT;
 
2211
        constructor_params_mixed_call_virtual(value_u8bit,
 
2212
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2213
        if object_u8bit <> RESULT_U8BIT then
 
2214
          failed := true;
 
2215
        if object_u16bit <> RESULT_U16BIT then
 
2216
          failed := true;
 
2217
        if object_s32bit <> RESULT_S32BIT then
 
2218
          failed := true;
 
2219
        if object_s64bit <> RESULT_S64BIT then
 
2220
          failed := true;
 
2221
        if object_bigstring <> RESULT_BIGSTRING then
 
2222
          failed := true;
 
2223
        destructor_params_done;
 
2224
 
 
2225
        if failed then
 
2226
          fail
 
2227
        else
 
2228
          Writeln('Passed!');
 
2229
 
 
2230
        clear_globals;
 
2231
        clear_values;
 
2232
        failed := false;
 
2233
 
 
2234
        Write('Testing mixed parameter (LOC_CONSTANT) constructor call w/virtual call...');
 
2235
        constructor_params_mixed_call_overriden(RESULT_U8BIT,
 
2236
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2237
        if object_u8bit <> RESULT_U8BIT then
 
2238
          failed := true;
 
2239
        if object_u16bit <> RESULT_U16BIT then
 
2240
          failed := true;
 
2241
        if object_s32bit <> RESULT_S32BIT then
 
2242
          failed := true;
 
2243
        if object_s64bit <> RESULT_S64BIT then
 
2244
          failed := true;
 
2245
        if object_bigstring <> RESULT_BIGSTRING then
 
2246
          failed := true;
 
2247
        destructor_params_done;
 
2248
 
 
2249
        if failed then
 
2250
          fail
 
2251
        else
 
2252
          Writeln('Passed!');
 
2253
 
 
2254
        clear_globals;
 
2255
        clear_values;
 
2256
        failed := false;
 
2257
 
 
2258
        Write('Testing mixed parameter (LOC_REFERENCE) constructor call w/virtual call...');
 
2259
        value_u8bit := RESULT_U8BIT;
 
2260
        value_u16bit := RESULT_U16BIT;
 
2261
        value_bigstring := RESULT_BIGSTRING;
 
2262
        value_s32bit := RESULT_S32BIT;
 
2263
        value_s64bit := RESULT_S64BIT;
 
2264
        constructor_params_mixed_call_overriden(value_u8bit,
 
2265
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2266
        if object_u8bit <> RESULT_U8BIT then
 
2267
          failed := true;
 
2268
        if object_u16bit <> RESULT_U16BIT then
 
2269
          failed := true;
 
2270
        if object_s32bit <> RESULT_S32BIT then
 
2271
          failed := true;
 
2272
        if object_s64bit <> RESULT_S64BIT then
 
2273
          failed := true;
 
2274
        if object_bigstring <> RESULT_BIGSTRING then
 
2275
          failed := true;
 
2276
        destructor_params_done;
 
2277
 
 
2278
        if failed then
 
2279
          fail
 
2280
        else
 
2281
          Writeln('Passed!');
 
2282
 
 
2283
        clear_globals;
 
2284
        clear_values;
 
2285
        failed := false;
 
2286
 
 
2287
        Write('Testing mixed parameter (LOC_CONSTANT) constructor call w/method call...');
 
2288
        constructor_params_mixed_call_normal(RESULT_U8BIT,
 
2289
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2290
        if object_u8bit <> RESULT_U8BIT then
 
2291
          failed := true;
 
2292
        if object_u16bit <> RESULT_U16BIT then
 
2293
          failed := true;
 
2294
        if object_s32bit <> RESULT_S32BIT then
 
2295
          failed := true;
 
2296
        if object_s64bit <> RESULT_S64BIT then
 
2297
          failed := true;
 
2298
        if object_bigstring <> RESULT_BIGSTRING then
 
2299
          failed := true;
 
2300
        destructor_params_done;
 
2301
 
 
2302
        if failed then
 
2303
          fail
 
2304
        else
 
2305
          Writeln('Passed!');
 
2306
 
 
2307
        clear_globals;
 
2308
        clear_values;
 
2309
        failed := false;
 
2310
 
 
2311
        Write('Testing mixed parameter (LOC_REFERENCE) constructor call w/method call...');
 
2312
        value_u8bit := RESULT_U8BIT;
 
2313
        value_u16bit := RESULT_U16BIT;
 
2314
        value_bigstring := RESULT_BIGSTRING;
 
2315
        value_s32bit := RESULT_S32BIT;
 
2316
        value_s64bit := RESULT_S64BIT;
 
2317
        constructor_params_mixed_call_normal(value_u8bit,
 
2318
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2319
        if object_u8bit <> RESULT_U8BIT then
 
2320
          failed := true;
 
2321
        if object_u16bit <> RESULT_U16BIT then
 
2322
          failed := true;
 
2323
        if object_s32bit <> RESULT_S32BIT then
 
2324
          failed := true;
 
2325
        if object_s64bit <> RESULT_S64BIT then
 
2326
          failed := true;
 
2327
        if object_bigstring <> RESULT_BIGSTRING then
 
2328
          failed := true;
 
2329
        destructor_params_done;
 
2330
 
 
2331
        if failed then
 
2332
          fail
 
2333
        else
 
2334
          Writeln('Passed!');
 
2335
 
 
2336
        clear_globals;
 
2337
        clear_values;
 
2338
        failed := false;
 
2339
 
 
2340
        Write('Testing mixed parameter (LOC_CONSTANT) constructor call w/static call...');
 
2341
        constructor_params_mixed_call_static(RESULT_U8BIT,
 
2342
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2343
        if global_u8bit <> RESULT_U8BIT then
 
2344
          failed := true;
 
2345
        if global_u16bit <> RESULT_U16BIT then
 
2346
          failed := true;
 
2347
        if global_s32bit <> RESULT_S32BIT then
 
2348
          failed := true;
 
2349
        if global_s64bit <> RESULT_S64BIT then
 
2350
          failed := true;
 
2351
        if global_bigstring <> RESULT_BIGSTRING then
 
2352
          failed := true;
 
2353
        destructor_params_done;
 
2354
 
 
2355
        if failed then
 
2356
          fail
 
2357
        else
 
2358
          Writeln('Passed!');
 
2359
 
 
2360
        clear_globals;
 
2361
        clear_values;
 
2362
        failed := false;
 
2363
 
 
2364
        Write('Testing mixed parameter (LOC_REFERENCE) constructor call w/static call...');
 
2365
        value_u8bit := RESULT_U8BIT;
 
2366
        value_u16bit := RESULT_U16BIT;
 
2367
        value_bigstring := RESULT_BIGSTRING;
 
2368
        value_s32bit := RESULT_S32BIT;
 
2369
        value_s64bit := RESULT_S64BIT;
 
2370
        constructor_params_mixed_call_static(value_u8bit,
 
2371
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2372
        if global_u8bit <> RESULT_U8BIT then
 
2373
          failed := true;
 
2374
        if global_u16bit <> RESULT_U16BIT then
 
2375
          failed := true;
 
2376
        if global_s32bit <> RESULT_S32BIT then
 
2377
          failed := true;
 
2378
        if global_s64bit <> RESULT_S64BIT then
 
2379
          failed := true;
 
2380
        if global_bigstring <> RESULT_BIGSTRING then
 
2381
          failed := true;
 
2382
        destructor_params_done;
 
2383
 
 
2384
        if failed then
 
2385
          fail
 
2386
        else
 
2387
          Writeln('Passed!');
 
2388
 
 
2389
        {************************* METHOD TESTING **************************}
 
2390
        clear_globals;
 
2391
        clear_values;
 
2392
        failed := false;
 
2393
 
 
2394
        constructor_init;
 
2395
        Write('Testing mixed parameter (LOC_CONSTANT) virtual method call...');
 
2396
        method_virtual_params_mixed(RESULT_U8BIT,
 
2397
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2398
        if object_u8bit <> RESULT_U8BIT then
 
2399
          failed := true;
 
2400
        if object_u16bit <> RESULT_U16BIT then
 
2401
          failed := true;
 
2402
        if object_s32bit <> RESULT_S32BIT then
 
2403
          failed := true;
 
2404
        if object_s64bit <> RESULT_S64BIT then
 
2405
          failed := true;
 
2406
        if object_bigstring <> RESULT_BIGSTRING then
 
2407
          failed := true;
 
2408
        destructor_params_done;
 
2409
 
 
2410
        if failed then
 
2411
          fail
 
2412
        else
 
2413
          Writeln('Passed!');
 
2414
 
 
2415
        clear_globals;
 
2416
        clear_values;
 
2417
        failed := false;
 
2418
 
 
2419
        constructor_init;
 
2420
        Write('Testing mixed parameter (LOC_REFERENCE) virtual method call...');
 
2421
        value_u8bit := RESULT_U8BIT;
 
2422
        value_u16bit := RESULT_U16BIT;
 
2423
        value_bigstring := RESULT_BIGSTRING;
 
2424
        value_s32bit := RESULT_S32BIT;
 
2425
        value_s64bit := RESULT_S64BIT;
 
2426
        method_virtual_params_mixed(value_u8bit,
 
2427
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2428
        if object_u8bit <> RESULT_U8BIT then
 
2429
          failed := true;
 
2430
        if object_u16bit <> RESULT_U16BIT then
 
2431
          failed := true;
 
2432
        if object_s32bit <> RESULT_S32BIT then
 
2433
          failed := true;
 
2434
        if object_s64bit <> RESULT_S64BIT then
 
2435
          failed := true;
 
2436
        if object_bigstring <> RESULT_BIGSTRING then
 
2437
          failed := true;
 
2438
        destructor_params_done;
 
2439
 
 
2440
        if failed then
 
2441
          fail
 
2442
        else
 
2443
          Writeln('Passed!');
 
2444
 
 
2445
        clear_globals;
 
2446
        clear_values;
 
2447
        failed := false;
 
2448
 
 
2449
        constructor_init;
 
2450
        Write('Testing mixed parameter (LOC_CONSTANT) virtual method call...');
 
2451
        method_virtual_overriden_params_mixed(RESULT_U8BIT,
 
2452
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2453
        if object_u8bit <> RESULT_U8BIT then
 
2454
          failed := true;
 
2455
        if object_u16bit <> RESULT_U16BIT then
 
2456
          failed := true;
 
2457
        if object_s32bit <> RESULT_S32BIT then
 
2458
          failed := true;
 
2459
        if object_s64bit <> RESULT_S64BIT then
 
2460
          failed := true;
 
2461
        if object_bigstring <> RESULT_BIGSTRING then
 
2462
          failed := true;
 
2463
        destructor_params_done;
 
2464
 
 
2465
        if failed then
 
2466
          fail
 
2467
        else
 
2468
          Writeln('Passed!');
 
2469
 
 
2470
        clear_globals;
 
2471
        clear_values;
 
2472
        failed := false;
 
2473
 
 
2474
        constructor_init;
 
2475
        Write('Testing mixed parameter (LOC_REFERENCE) virtual method call...');
 
2476
        value_u8bit := RESULT_U8BIT;
 
2477
        value_u16bit := RESULT_U16BIT;
 
2478
        value_bigstring := RESULT_BIGSTRING;
 
2479
        value_s32bit := RESULT_S32BIT;
 
2480
        value_s64bit := RESULT_S64BIT;
 
2481
        method_virtual_overriden_params_mixed(value_u8bit,
 
2482
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2483
        if object_u8bit <> RESULT_U8BIT then
 
2484
          failed := true;
 
2485
        if object_u16bit <> RESULT_U16BIT then
 
2486
          failed := true;
 
2487
        if object_s32bit <> RESULT_S32BIT then
 
2488
          failed := true;
 
2489
        if object_s64bit <> RESULT_S64BIT then
 
2490
          failed := true;
 
2491
        if object_bigstring <> RESULT_BIGSTRING then
 
2492
          failed := true;
 
2493
        destructor_params_done;
 
2494
 
 
2495
        if failed then
 
2496
          fail
 
2497
        else
 
2498
          Writeln('Passed!');
 
2499
 
 
2500
        clear_globals;
 
2501
        clear_values;
 
2502
        failed := false;
 
2503
 
 
2504
        constructor_init;
 
2505
        Write('Testing mixed parameter (LOC_CONSTANT) method call...');
 
2506
        method_normal_params_mixed(RESULT_U8BIT,
 
2507
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2508
        if object_u8bit <> RESULT_U8BIT then
 
2509
          failed := true;
 
2510
        if object_u16bit <> RESULT_U16BIT then
 
2511
          failed := true;
 
2512
        if object_s32bit <> RESULT_S32BIT then
 
2513
          failed := true;
 
2514
        if object_s64bit <> RESULT_S64BIT then
 
2515
          failed := true;
 
2516
        if object_bigstring <> RESULT_BIGSTRING then
 
2517
          failed := true;
 
2518
        destructor_params_done;
 
2519
 
 
2520
        if failed then
 
2521
          fail
 
2522
        else
 
2523
          Writeln('Passed!');
 
2524
 
 
2525
        clear_globals;
 
2526
        clear_values;
 
2527
        failed := false;
 
2528
 
 
2529
        constructor_init;
 
2530
        Write('Testing mixed parameter (LOC_REFERENCE) method call...');
 
2531
        value_u8bit := RESULT_U8BIT;
 
2532
        value_u16bit := RESULT_U16BIT;
 
2533
        value_bigstring := RESULT_BIGSTRING;
 
2534
        value_s32bit := RESULT_S32BIT;
 
2535
        value_s64bit := RESULT_S64BIT;
 
2536
        method_normal_params_mixed(value_u8bit,
 
2537
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2538
        if object_u8bit <> RESULT_U8BIT then
 
2539
          failed := true;
 
2540
        if object_u16bit <> RESULT_U16BIT then
 
2541
          failed := true;
 
2542
        if object_s32bit <> RESULT_S32BIT then
 
2543
          failed := true;
 
2544
        if object_s64bit <> RESULT_S64BIT then
 
2545
          failed := true;
 
2546
        if object_bigstring <> RESULT_BIGSTRING then
 
2547
          failed := true;
 
2548
        destructor_params_done;
 
2549
 
 
2550
        if failed then
 
2551
          fail
 
2552
        else
 
2553
          Writeln('Passed!');
 
2554
 
 
2555
        clear_globals;
 
2556
        clear_values;
 
2557
        failed := false;
 
2558
 
 
2559
        constructor_init;
 
2560
        Write('Testing mixed parameter (LOC_CONSTANT) static method call...');
 
2561
        method_static_params_mixed(RESULT_U8BIT,
 
2562
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2563
        if global_u8bit <> RESULT_U8BIT then
 
2564
          failed := true;
 
2565
        if global_u16bit <> RESULT_U16BIT then
 
2566
          failed := true;
 
2567
        if global_s32bit <> RESULT_S32BIT then
 
2568
          failed := true;
 
2569
        if global_s64bit <> RESULT_S64BIT then
 
2570
          failed := true;
 
2571
        if global_bigstring <> RESULT_BIGSTRING then
 
2572
          failed := true;
 
2573
        destructor_params_done;
 
2574
 
 
2575
        if failed then
 
2576
          fail
 
2577
        else
 
2578
          Writeln('Passed!');
 
2579
 
 
2580
        clear_globals;
 
2581
        clear_values;
 
2582
        failed := false;
 
2583
 
 
2584
        constructor_init;
 
2585
        Write('Testing mixed parameter (LOC_REFERENCE) static method call...');
 
2586
        value_u8bit := RESULT_U8BIT;
 
2587
        value_u16bit := RESULT_U16BIT;
 
2588
        value_bigstring := RESULT_BIGSTRING;
 
2589
        value_s32bit := RESULT_S32BIT;
 
2590
        value_s64bit := RESULT_S64BIT;
 
2591
        method_static_params_mixed(value_u8bit,
 
2592
          value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2593
        if global_u8bit <> RESULT_U8BIT then
 
2594
          failed := true;
 
2595
        if global_u16bit <> RESULT_U16BIT then
 
2596
          failed := true;
 
2597
        if global_s32bit <> RESULT_S32BIT then
 
2598
          failed := true;
 
2599
        if global_s64bit <> RESULT_S64BIT then
 
2600
          failed := true;
 
2601
        if global_bigstring <> RESULT_BIGSTRING then
 
2602
          failed := true;
 
2603
        destructor_params_done;
 
2604
 
 
2605
        if failed then
 
2606
          fail
 
2607
        else
 
2608
          Writeln('Passed!');
 
2609
 
 
2610
        { ********************************************************************
 
2611
          This calls methods which in turn call other methods, or a constructor
 
2612
          or a destructor.
 
2613
          *********************************************************************
 
2614
        }
 
2615
        clear_globals;
 
2616
        clear_values;
 
2617
        failed := false;
 
2618
        { Calls the ancestor virtual method }
 
2619
        constructor_init;
 
2620
        Write('Testing mixed parameter (LOC_CONSTANT) method call w/virtual call...');
 
2621
        method_normal_call_virtual_params_mixed(RESULT_U8BIT,
 
2622
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2623
        if object_u8bit <> RESULT_U8BIT then
 
2624
          failed := true;
 
2625
        if object_u16bit <> RESULT_U16BIT then
 
2626
          failed := true;
 
2627
        if object_s32bit <> RESULT_S32BIT then
 
2628
          failed := true;
 
2629
        if object_s64bit <> RESULT_S64BIT then
 
2630
          failed := true;
 
2631
        if object_bigstring <> RESULT_BIGSTRING then
 
2632
          failed := true;
 
2633
        destructor_params_done;
 
2634
 
 
2635
        if failed then
 
2636
          fail
 
2637
        else
 
2638
          Writeln('Passed!');
 
2639
 
 
2640
        clear_globals;
 
2641
        clear_values;
 
2642
        failed := false;
 
2643
 
 
2644
        constructor_init;
 
2645
        Write('Testing mixed parameter (LOC_REFERENCE) method call w/virtual call...');
 
2646
        value_u8bit := RESULT_U8BIT;
 
2647
        value_u16bit := RESULT_U16BIT;
 
2648
        value_bigstring := RESULT_BIGSTRING;
 
2649
        value_s32bit := RESULT_S32BIT;
 
2650
        value_s64bit := RESULT_S64BIT;
 
2651
        method_normal_call_virtual_params_mixed(value_u8bit,
 
2652
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2653
        if object_u8bit <> RESULT_U8BIT then
 
2654
          failed := true;
 
2655
        if object_u16bit <> RESULT_U16BIT then
 
2656
          failed := true;
 
2657
        if object_s32bit <> RESULT_S32BIT then
 
2658
          failed := true;
 
2659
        if object_s64bit <> RESULT_S64BIT then
 
2660
          failed := true;
 
2661
        if object_bigstring <> RESULT_BIGSTRING then
 
2662
          failed := true;
 
2663
        destructor_params_done;
 
2664
 
 
2665
        if failed then
 
2666
          fail
 
2667
        else
 
2668
          Writeln('Passed!');
 
2669
 
 
2670
        { The virtual method has been overriden by the object in this case }
 
2671
        constructor_init;
 
2672
        Write('Testing mixed parameter (LOC_CONSTANT) method call w/virtual call...');
 
2673
        method_normal_call_overriden_params_mixed(RESULT_U8BIT,
 
2674
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2675
        if object_u8bit <> RESULT_U8BIT then
 
2676
          failed := true;
 
2677
        if object_u16bit <> RESULT_U16BIT then
 
2678
          failed := true;
 
2679
        if object_s32bit <> RESULT_S32BIT then
 
2680
          failed := true;
 
2681
        if object_s64bit <> RESULT_S64BIT then
 
2682
          failed := true;
 
2683
        if object_bigstring <> RESULT_BIGSTRING then
 
2684
          failed := true;
 
2685
        destructor_params_done;
 
2686
 
 
2687
        if failed then
 
2688
          fail
 
2689
        else
 
2690
          Writeln('Passed!');
 
2691
 
 
2692
        clear_globals;
 
2693
        clear_values;
 
2694
        failed := false;
 
2695
 
 
2696
        constructor_init;
 
2697
        Write('Testing mixed parameter (LOC_REFERENCE) method call w/virtual call...');
 
2698
        value_u8bit := RESULT_U8BIT;
 
2699
        value_u16bit := RESULT_U16BIT;
 
2700
        value_bigstring := RESULT_BIGSTRING;
 
2701
        value_s32bit := RESULT_S32BIT;
 
2702
        value_s64bit := RESULT_S64BIT;
 
2703
        method_normal_call_overriden_params_mixed(value_u8bit,
 
2704
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2705
        if object_u8bit <> RESULT_U8BIT then
 
2706
          failed := true;
 
2707
        if object_u16bit <> RESULT_U16BIT then
 
2708
          failed := true;
 
2709
        if object_s32bit <> RESULT_S32BIT then
 
2710
          failed := true;
 
2711
        if object_s64bit <> RESULT_S64BIT then
 
2712
          failed := true;
 
2713
        if object_bigstring <> RESULT_BIGSTRING then
 
2714
          failed := true;
 
2715
        destructor_params_done;
 
2716
 
 
2717
        if failed then
 
2718
          fail
 
2719
        else
 
2720
          Writeln('Passed!');
 
2721
 
 
2722
        clear_globals;
 
2723
        clear_values;
 
2724
        failed := false;
 
2725
 
 
2726
        constructor_init;
 
2727
        Write('Testing mixed parameter (LOC_CONSTANT) method call w/normal call...');
 
2728
        method_normal_call_normal_params_mixed(RESULT_U8BIT,
 
2729
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2730
        if object_u8bit <> RESULT_U8BIT then
 
2731
          failed := true;
 
2732
        if object_u16bit <> RESULT_U16BIT then
 
2733
          failed := true;
 
2734
        if object_s32bit <> RESULT_S32BIT then
 
2735
          failed := true;
 
2736
        if object_s64bit <> RESULT_S64BIT then
 
2737
          failed := true;
 
2738
        if object_bigstring <> RESULT_BIGSTRING then
 
2739
          failed := true;
 
2740
        destructor_params_done;
 
2741
 
 
2742
        if failed then
 
2743
          fail
 
2744
        else
 
2745
          Writeln('Passed!');
 
2746
 
 
2747
        clear_globals;
 
2748
        clear_values;
 
2749
        failed := false;
 
2750
 
 
2751
        constructor_init;
 
2752
        Write('Testing mixed parameter (LOC_REFERENCE) method call w/normal call...');
 
2753
        value_u8bit := RESULT_U8BIT;
 
2754
        value_u16bit := RESULT_U16BIT;
 
2755
        value_bigstring := RESULT_BIGSTRING;
 
2756
        value_s32bit := RESULT_S32BIT;
 
2757
        value_s64bit := RESULT_S64BIT;
 
2758
        method_normal_call_normal_params_mixed(value_u8bit,
 
2759
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2760
        if object_u8bit <> RESULT_U8BIT then
 
2761
          failed := true;
 
2762
        if object_u16bit <> RESULT_U16BIT then
 
2763
          failed := true;
 
2764
        if object_s32bit <> RESULT_S32BIT then
 
2765
          failed := true;
 
2766
        if object_s64bit <> RESULT_S64BIT then
 
2767
          failed := true;
 
2768
        if object_bigstring <> RESULT_BIGSTRING then
 
2769
          failed := true;
 
2770
        destructor_params_done;
 
2771
 
 
2772
        if failed then
 
2773
          fail
 
2774
        else
 
2775
          Writeln('Passed!');
 
2776
 
 
2777
        (* constructor call inside a normal method *)
 
2778
 
 
2779
        clear_globals;
 
2780
        clear_values;
 
2781
        failed := false;
 
2782
 
 
2783
        constructor_init;
 
2784
        Write('Testing mixed parameter (LOC_CONSTANT) method call w/constructor call...');
 
2785
        method_normal_call_constructor_params_mixed(RESULT_U8BIT,
 
2786
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2787
        if object_u8bit <> RESULT_U8BIT then
 
2788
          failed := true;
 
2789
        if object_u16bit <> RESULT_U16BIT then
 
2790
          failed := true;
 
2791
        if object_s32bit <> RESULT_S32BIT then
 
2792
          failed := true;
 
2793
        if object_s64bit <> RESULT_S64BIT then
 
2794
          failed := true;
 
2795
        if object_bigstring <> RESULT_BIGSTRING then
 
2796
          failed := true;
 
2797
        destructor_params_done;
 
2798
 
 
2799
        if failed then
 
2800
          fail
 
2801
        else
 
2802
          Writeln('Passed!');
 
2803
 
 
2804
        clear_globals;
 
2805
        clear_values;
 
2806
        failed := false;
 
2807
 
 
2808
        constructor_init;
 
2809
        Write('Testing mixed parameter (LOC_REFERENCE) method call w/constructor call...');
 
2810
        value_u8bit := RESULT_U8BIT;
 
2811
        value_u16bit := RESULT_U16BIT;
 
2812
        value_bigstring := RESULT_BIGSTRING;
 
2813
        value_s32bit := RESULT_S32BIT;
 
2814
        value_s64bit := RESULT_S64BIT;
 
2815
        method_normal_call_constructor_params_mixed(value_u8bit,
 
2816
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2817
        if object_u8bit <> RESULT_U8BIT then
 
2818
          failed := true;
 
2819
        if object_u16bit <> RESULT_U16BIT then
 
2820
          failed := true;
 
2821
        if object_s32bit <> RESULT_S32BIT then
 
2822
          failed := true;
 
2823
        if object_s64bit <> RESULT_S64BIT then
 
2824
          failed := true;
 
2825
        if object_bigstring <> RESULT_BIGSTRING then
 
2826
          failed := true;
 
2827
        destructor_params_done;
 
2828
 
 
2829
        if failed then
 
2830
          fail
 
2831
        else
 
2832
          Writeln('Passed!');
 
2833
 
 
2834
        { static method call }
 
2835
        clear_globals;
 
2836
        clear_values;
 
2837
        failed := false;
 
2838
 
 
2839
        constructor_init;
 
2840
        Write('Testing mixed parameter (LOC_CONSTANT) method call w/static call...');
 
2841
        method_normal_call_static_params_mixed(RESULT_U8BIT,
 
2842
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2843
        if global_u8bit <> RESULT_U8BIT then
 
2844
          failed := true;
 
2845
        if global_u16bit <> RESULT_U16BIT then
 
2846
          failed := true;
 
2847
        if global_s32bit <> RESULT_S32BIT then
 
2848
          failed := true;
 
2849
        if global_s64bit <> RESULT_S64BIT then
 
2850
          failed := true;
 
2851
        if global_bigstring <> RESULT_BIGSTRING then
 
2852
          failed := true;
 
2853
        destructor_params_done;
 
2854
 
 
2855
        if failed then
 
2856
          fail
 
2857
        else
 
2858
          Writeln('Passed!');
 
2859
 
 
2860
        clear_globals;
 
2861
        clear_values;
 
2862
        failed := false;
 
2863
 
 
2864
        constructor_init;
 
2865
        Write('Testing mixed parameter (LOC_REFERENCE) method call w/static call...');
 
2866
        value_u8bit := RESULT_U8BIT;
 
2867
        value_u16bit := RESULT_U16BIT;
 
2868
        value_bigstring := RESULT_BIGSTRING;
 
2869
        value_s32bit := RESULT_S32BIT;
 
2870
        value_s64bit := RESULT_S64BIT;
 
2871
        method_normal_call_static_params_mixed(value_u8bit,
 
2872
          value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2873
        if global_u8bit <> RESULT_U8BIT then
 
2874
          failed := true;
 
2875
        if global_u16bit <> RESULT_U16BIT then
 
2876
          failed := true;
 
2877
        if global_s32bit <> RESULT_S32BIT then
 
2878
          failed := true;
 
2879
        if global_s64bit <> RESULT_S64BIT then
 
2880
          failed := true;
 
2881
        if global_bigstring <> RESULT_BIGSTRING then
 
2882
          failed := true;
 
2883
        destructor_params_done;
 
2884
 
 
2885
        if failed then
 
2886
          fail
 
2887
        else
 
2888
          Writeln('Passed!');
 
2889
 
 
2890
        (* calls the inherited method *)
 
2891
        clear_globals;
 
2892
        clear_values;
 
2893
        failed := false;
 
2894
        { Calls the ancestor virtual method }
 
2895
        constructor_init;
 
2896
        Write('Testing mixed parameter (LOC_CONSTANT) method call w/inherited call...');
 
2897
        method_normal_call_inherited_params_mixed(RESULT_U8BIT,
 
2898
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2899
        if object_u8bit <> RESULT_U8BIT then
 
2900
          failed := true;
 
2901
        if object_u16bit <> RESULT_U16BIT then
 
2902
          failed := true;
 
2903
        if object_s32bit <> RESULT_S32BIT then
 
2904
          failed := true;
 
2905
        if object_s64bit <> RESULT_S64BIT then
 
2906
          failed := true;
 
2907
        if object_bigstring <> RESULT_BIGSTRING then
 
2908
          failed := true;
 
2909
        destructor_params_done;
 
2910
 
 
2911
        if failed then
 
2912
          fail
 
2913
        else
 
2914
          Writeln('Passed!');
 
2915
 
 
2916
        clear_globals;
 
2917
        clear_values;
 
2918
        failed := false;
 
2919
 
 
2920
        constructor_init;
 
2921
        Write('Testing mixed parameter (LOC_REFERENCE) method call w/inherited call...');
 
2922
        value_u8bit := RESULT_U8BIT;
 
2923
        value_u16bit := RESULT_U16BIT;
 
2924
        value_bigstring := RESULT_BIGSTRING;
 
2925
        value_s32bit := RESULT_S32BIT;
 
2926
        value_s64bit := RESULT_S64BIT;
 
2927
        method_normal_call_inherited_params_mixed(value_u8bit,
 
2928
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2929
        if object_u8bit <> RESULT_U8BIT then
 
2930
          failed := true;
 
2931
        if object_u16bit <> RESULT_U16BIT then
 
2932
          failed := true;
 
2933
        if object_s32bit <> RESULT_S32BIT then
 
2934
          failed := true;
 
2935
        if object_s64bit <> RESULT_S64BIT then
 
2936
          failed := true;
 
2937
        if object_bigstring <> RESULT_BIGSTRING then
 
2938
          failed := true;
 
2939
        destructor_params_done;
 
2940
 
 
2941
        if failed then
 
2942
          fail
 
2943
        else
 
2944
          Writeln('Passed!');
 
2945
 
 
2946
    { ********************************************************************
 
2947
        This calls virtual methods which in turn call other methods,
 
2948
        or a constructor  or a destructor.
 
2949
       *********************************************************************
 
2950
    }
 
2951
        clear_globals;
 
2952
        clear_values;
 
2953
        failed := false;
 
2954
        { Calls the ancestor virtual method }
 
2955
        constructor_init;
 
2956
        Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/virtual call...');
 
2957
        method_virtual_call_virtual_params_mixed(RESULT_U8BIT,
 
2958
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
2959
        if object_u8bit <> RESULT_U8BIT then
 
2960
          failed := true;
 
2961
        if object_u16bit <> RESULT_U16BIT then
 
2962
          failed := true;
 
2963
        if object_s32bit <> RESULT_S32BIT then
 
2964
          failed := true;
 
2965
        if object_s64bit <> RESULT_S64BIT then
 
2966
          failed := true;
 
2967
        if object_bigstring <> RESULT_BIGSTRING then
 
2968
          failed := true;
 
2969
        destructor_params_done;
 
2970
 
 
2971
        if failed then
 
2972
          fail
 
2973
        else
 
2974
          Writeln('Passed!');
 
2975
 
 
2976
        clear_globals;
 
2977
        clear_values;
 
2978
        failed := false;
 
2979
 
 
2980
        constructor_init;
 
2981
        Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/virtual call...');
 
2982
        value_u8bit := RESULT_U8BIT;
 
2983
        value_u16bit := RESULT_U16BIT;
 
2984
        value_bigstring := RESULT_BIGSTRING;
 
2985
        value_s32bit := RESULT_S32BIT;
 
2986
        value_s64bit := RESULT_S64BIT;
 
2987
        method_virtual_call_virtual_params_mixed(value_u8bit,
 
2988
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
2989
        if object_u8bit <> RESULT_U8BIT then
 
2990
          failed := true;
 
2991
        if object_u16bit <> RESULT_U16BIT then
 
2992
          failed := true;
 
2993
        if object_s32bit <> RESULT_S32BIT then
 
2994
          failed := true;
 
2995
        if object_s64bit <> RESULT_S64BIT then
 
2996
          failed := true;
 
2997
        if object_bigstring <> RESULT_BIGSTRING then
 
2998
          failed := true;
 
2999
        destructor_params_done;
 
3000
 
 
3001
        if failed then
 
3002
          fail
 
3003
        else
 
3004
          Writeln('Passed!');
 
3005
 
 
3006
        { The virtual method has been overriden by the object in this case }
 
3007
        constructor_init;
 
3008
        Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/virtual call...');
 
3009
        method_virtual_call_overriden_params_mixed(RESULT_U8BIT,
 
3010
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
3011
        if object_u8bit <> RESULT_U8BIT then
 
3012
          failed := true;
 
3013
        if object_u16bit <> RESULT_U16BIT then
 
3014
          failed := true;
 
3015
        if object_s32bit <> RESULT_S32BIT then
 
3016
          failed := true;
 
3017
        if object_s64bit <> RESULT_S64BIT then
 
3018
          failed := true;
 
3019
        if object_bigstring <> RESULT_BIGSTRING then
 
3020
          failed := true;
 
3021
        destructor_params_done;
 
3022
 
 
3023
        if failed then
 
3024
          fail
 
3025
        else
 
3026
          Writeln('Passed!');
 
3027
 
 
3028
        clear_globals;
 
3029
        clear_values;
 
3030
        failed := false;
 
3031
 
 
3032
        constructor_init;
 
3033
        Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/virtual call...');
 
3034
        value_u8bit := RESULT_U8BIT;
 
3035
        value_u16bit := RESULT_U16BIT;
 
3036
        value_bigstring := RESULT_BIGSTRING;
 
3037
        value_s32bit := RESULT_S32BIT;
 
3038
        value_s64bit := RESULT_S64BIT;
 
3039
        method_virtual_call_overriden_params_mixed(value_u8bit,
 
3040
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
3041
        if object_u8bit <> RESULT_U8BIT then
 
3042
          failed := true;
 
3043
        if object_u16bit <> RESULT_U16BIT then
 
3044
          failed := true;
 
3045
        if object_s32bit <> RESULT_S32BIT then
 
3046
          failed := true;
 
3047
        if object_s64bit <> RESULT_S64BIT then
 
3048
          failed := true;
 
3049
        if object_bigstring <> RESULT_BIGSTRING then
 
3050
          failed := true;
 
3051
        destructor_params_done;
 
3052
 
 
3053
        if failed then
 
3054
          fail
 
3055
        else
 
3056
          Writeln('Passed!');
 
3057
 
 
3058
        clear_globals;
 
3059
        clear_values;
 
3060
        failed := false;
 
3061
 
 
3062
        constructor_init;
 
3063
        Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/normal call...');
 
3064
        method_virtual_call_normal_params_mixed(RESULT_U8BIT,
 
3065
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
3066
        if object_u8bit <> RESULT_U8BIT then
 
3067
          failed := true;
 
3068
        if object_u16bit <> RESULT_U16BIT then
 
3069
          failed := true;
 
3070
        if object_s32bit <> RESULT_S32BIT then
 
3071
          failed := true;
 
3072
        if object_s64bit <> RESULT_S64BIT then
 
3073
          failed := true;
 
3074
        if object_bigstring <> RESULT_BIGSTRING then
 
3075
          failed := true;
 
3076
        destructor_params_done;
 
3077
 
 
3078
        if failed then
 
3079
          fail
 
3080
        else
 
3081
          Writeln('Passed!');
 
3082
 
 
3083
        clear_globals;
 
3084
        clear_values;
 
3085
        failed := false;
 
3086
 
 
3087
        constructor_init;
 
3088
        Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/normal call...');
 
3089
        value_u8bit := RESULT_U8BIT;
 
3090
        value_u16bit := RESULT_U16BIT;
 
3091
        value_bigstring := RESULT_BIGSTRING;
 
3092
        value_s32bit := RESULT_S32BIT;
 
3093
        value_s64bit := RESULT_S64BIT;
 
3094
        method_virtual_call_normal_params_mixed(value_u8bit,
 
3095
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
3096
        if object_u8bit <> RESULT_U8BIT then
 
3097
          failed := true;
 
3098
        if object_u16bit <> RESULT_U16BIT then
 
3099
          failed := true;
 
3100
        if object_s32bit <> RESULT_S32BIT then
 
3101
          failed := true;
 
3102
        if object_s64bit <> RESULT_S64BIT then
 
3103
          failed := true;
 
3104
        if object_bigstring <> RESULT_BIGSTRING then
 
3105
          failed := true;
 
3106
        destructor_params_done;
 
3107
 
 
3108
        if failed then
 
3109
          fail
 
3110
        else
 
3111
          Writeln('Passed!');
 
3112
 
 
3113
        (* constructor call inside a normal method *)
 
3114
 
 
3115
        clear_globals;
 
3116
        clear_values;
 
3117
        failed := false;
 
3118
 
 
3119
        constructor_init;
 
3120
        Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/constructor call...');
 
3121
        method_virtual_call_constructor_params_mixed(RESULT_U8BIT,
 
3122
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
3123
        if object_u8bit <> RESULT_U8BIT then
 
3124
          failed := true;
 
3125
        if object_u16bit <> RESULT_U16BIT then
 
3126
          failed := true;
 
3127
        if object_s32bit <> RESULT_S32BIT then
 
3128
          failed := true;
 
3129
        if object_s64bit <> RESULT_S64BIT then
 
3130
          failed := true;
 
3131
        if object_bigstring <> RESULT_BIGSTRING then
 
3132
          failed := true;
 
3133
        destructor_params_done;
 
3134
 
 
3135
        if failed then
 
3136
          fail
 
3137
        else
 
3138
          Writeln('Passed!');
 
3139
 
 
3140
        clear_globals;
 
3141
        clear_values;
 
3142
        failed := false;
 
3143
 
 
3144
        constructor_init;
 
3145
        Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/constructor call...');
 
3146
        value_u8bit := RESULT_U8BIT;
 
3147
        value_u16bit := RESULT_U16BIT;
 
3148
        value_bigstring := RESULT_BIGSTRING;
 
3149
        value_s32bit := RESULT_S32BIT;
 
3150
        value_s64bit := RESULT_S64BIT;
 
3151
        method_virtual_call_constructor_params_mixed(value_u8bit,
 
3152
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
3153
        if object_u8bit <> RESULT_U8BIT then
 
3154
          failed := true;
 
3155
        if object_u16bit <> RESULT_U16BIT then
 
3156
          failed := true;
 
3157
        if object_s32bit <> RESULT_S32BIT then
 
3158
          failed := true;
 
3159
        if object_s64bit <> RESULT_S64BIT then
 
3160
          failed := true;
 
3161
        if object_bigstring <> RESULT_BIGSTRING then
 
3162
          failed := true;
 
3163
        destructor_params_done;
 
3164
 
 
3165
        if failed then
 
3166
          fail
 
3167
        else
 
3168
          Writeln('Passed!');
 
3169
 
 
3170
        { static virtual call }
 
3171
        clear_globals;
 
3172
        clear_values;
 
3173
        failed := false;
 
3174
 
 
3175
        constructor_init;
 
3176
        Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/static call...');
 
3177
        method_virtual_call_static_params_mixed(RESULT_U8BIT,
 
3178
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
3179
        if global_u8bit <> RESULT_U8BIT then
 
3180
          failed := true;
 
3181
        if global_u16bit <> RESULT_U16BIT then
 
3182
          failed := true;
 
3183
        if global_s32bit <> RESULT_S32BIT then
 
3184
          failed := true;
 
3185
        if global_s64bit <> RESULT_S64BIT then
 
3186
          failed := true;
 
3187
        if global_bigstring <> RESULT_BIGSTRING then
 
3188
          failed := true;
 
3189
        destructor_params_done;
 
3190
 
 
3191
        if failed then
 
3192
          fail
 
3193
        else
 
3194
          Writeln('Passed!');
 
3195
 
 
3196
        clear_globals;
 
3197
        clear_values;
 
3198
        failed := false;
 
3199
 
 
3200
        constructor_init;
 
3201
        Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/static call...');
 
3202
        value_u8bit := RESULT_U8BIT;
 
3203
        value_u16bit := RESULT_U16BIT;
 
3204
        value_bigstring := RESULT_BIGSTRING;
 
3205
        value_s32bit := RESULT_S32BIT;
 
3206
        value_s64bit := RESULT_S64BIT;
 
3207
        method_virtual_call_static_params_mixed(value_u8bit,
 
3208
          value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
3209
        if global_u8bit <> RESULT_U8BIT then
 
3210
          failed := true;
 
3211
        if global_u16bit <> RESULT_U16BIT then
 
3212
          failed := true;
 
3213
        if global_s32bit <> RESULT_S32BIT then
 
3214
          failed := true;
 
3215
        if global_s64bit <> RESULT_S64BIT then
 
3216
          failed := true;
 
3217
        if global_bigstring <> RESULT_BIGSTRING then
 
3218
          failed := true;
 
3219
        destructor_params_done;
 
3220
 
 
3221
        if failed then
 
3222
          fail
 
3223
        else
 
3224
          Writeln('Passed!');
 
3225
 
 
3226
        (* calls the inherited method *)
 
3227
        clear_globals;
 
3228
        clear_values;
 
3229
        failed := false;
 
3230
        { Calls the ancestor virtual method }
 
3231
        constructor_init;
 
3232
        Write('Testing mixed parameter (LOC_CONSTANT) virtual call w/inherited call...');
 
3233
        method_virtual_call_inherited_params_mixed(RESULT_U8BIT,
 
3234
           RESULT_U16BIT, RESULT_BIGSTRING, RESULT_S32BIT, RESULT_S64BIT);
 
3235
        if object_u8bit <> RESULT_U8BIT then
 
3236
          failed := true;
 
3237
        if object_u16bit <> RESULT_U16BIT then
 
3238
          failed := true;
 
3239
        if object_s32bit <> RESULT_S32BIT then
 
3240
          failed := true;
 
3241
        if object_s64bit <> RESULT_S64BIT then
 
3242
          failed := true;
 
3243
        if object_bigstring <> RESULT_BIGSTRING then
 
3244
          failed := true;
 
3245
        destructor_params_done;
 
3246
 
 
3247
        if failed then
 
3248
          fail
 
3249
        else
 
3250
          Writeln('Passed!');
 
3251
 
 
3252
        clear_globals;
 
3253
        clear_values;
 
3254
        failed := false;
 
3255
 
 
3256
        constructor_init;
 
3257
        Write('Testing mixed parameter (LOC_REFERENCE) virtual call w/inherited call...');
 
3258
        value_u8bit := RESULT_U8BIT;
 
3259
        value_u16bit := RESULT_U16BIT;
 
3260
        value_bigstring := RESULT_BIGSTRING;
 
3261
        value_s32bit := RESULT_S32BIT;
 
3262
        value_s64bit := RESULT_S64BIT;
 
3263
        method_virtual_call_inherited_params_mixed(value_u8bit,
 
3264
           value_u16bit, value_bigstring, value_s32bit, value_s64bit);
 
3265
        if object_u8bit <> RESULT_U8BIT then
 
3266
          failed := true;
 
3267
        if object_u16bit <> RESULT_U16BIT then
 
3268
          failed := true;
 
3269
        if object_s32bit <> RESULT_S32BIT then
 
3270
          failed := true;
 
3271
        if object_s64bit <> RESULT_S64BIT then
 
3272
          failed := true;
 
3273
        if object_bigstring <> RESULT_BIGSTRING then
 
3274
          failed := true;
 
3275
        destructor_params_done;
 
3276
 
 
3277
        if failed then
 
3278
          fail
 
3279
        else
 
3280
          Writeln('Passed!');
 
3281
   end; { end with }
 
3282
  end;
 
3283
 
 
3284
 
 
3285
begin
 
3286
  WriteLN('*********************** NO VMT OBJECT TESTS ********************');
 
3287
  testnovmtobject;
 
3288
  WriteLN('************************ VMT OBJECT FAIL  **********************');
 
3289
  testfailedobject;
 
3290
  WriteLN('************************* VMT OBJECT TESTS *********************');
 
3291
  testvmtobject;
 
3292
  testheritedvmtobject;
 
3293
  WriteLN('**************** VMT OBJECT TESTS USING WITH *******************');
 
3294
  testwith;
 
3295
end.