source: src/Tests/Expect-v/Tuple.txt @ d67a9a1

ADTaaron-thesisarm-ehast-experimentalcleanup-dtorsctordeferred_resndemanglerenumforall-pointer-decaygc_noraiijacob/cs343-translationjenkins-sandboxmemorynew-astnew-ast-unique-exprnew-envno_listpersistent-indexerpthread-emulationqualifiedEnumresolv-newwith_gc
Last change on this file since d67a9a1 was b1d6dd5, checked in by Peter A. Buhr <pabuhr@…>, 9 years ago

fix parsing error for EOF message, change cfa-ccp -x flag to -v, regression testing third attempt: consolidate example programs

  • Property mode set to 100644
File size: 19.1 KB
Line 
1f: function
2    with parameters
3      signed int
4      signed int
5    returning
6      signed int
7
8g: function
9    with parameters
10      signed int
11      signed int
12      signed int
13    returning
14      signed int
15
16h: static function
17    with parameters
18      a: signed int
19      b: signed int
20      c: pointer to signed int
21      d: pointer to char
22    returning
23      signed int
24      pointer to signed int
25      pointer to signed int
26      signed int
27
28struct inner
29    with members
30      f2: signed int
31      f3: signed int
32
33?=?: automatically generated inline static function
34    with parameters
35      _dst: pointer to instance of struct inner
36      _src: instance of struct inner
37    returning
38      instance of struct inner
39    with body
40      CompoundStmt
41                  Expression Statement:
42            Applying untyped:
43                Name: ?=?
44            ...to:
45                Address of:
46                  Member Expression, with field:
47                    f2: signed int
48                  from aggregate:
49                    Applying untyped:
50                        Name: *?
51                    ...to:
52                        Variable Expression: _dst: pointer to instance of struct inner
53                Member Expression, with field:
54                  f2: signed int
55                from aggregate:
56                  Variable Expression: _src: instance of struct inner
57
58                  Expression Statement:
59            Applying untyped:
60                Name: ?=?
61            ...to:
62                Address of:
63                  Member Expression, with field:
64                    f3: signed int
65                  from aggregate:
66                    Applying untyped:
67                        Name: *?
68                    ...to:
69                        Variable Expression: _dst: pointer to instance of struct inner
70                Member Expression, with field:
71                  f3: signed int
72                from aggregate:
73                  Variable Expression: _src: instance of struct inner
74
75                  Return Statement, returning: Variable Expression: _src: instance of struct inner
76
77
78
79struct outer
80    with members
81      f1: signed int
82      i: instance of struct inner
83      f4: double
84
85?=?: automatically generated inline static function
86    with parameters
87      _dst: pointer to instance of struct outer
88      _src: instance of struct outer
89    returning
90      instance of struct outer
91    with body
92      CompoundStmt
93                  Expression Statement:
94            Applying untyped:
95                Name: ?=?
96            ...to:
97                Address of:
98                  Member Expression, with field:
99                    f1: signed int
100                  from aggregate:
101                    Applying untyped:
102                        Name: *?
103                    ...to:
104                        Variable Expression: _dst: pointer to instance of struct outer
105                Member Expression, with field:
106                  f1: signed int
107                from aggregate:
108                  Variable Expression: _src: instance of struct outer
109
110                  Expression Statement:
111            Applying untyped:
112                Name: ?=?
113            ...to:
114                Address of:
115                  Member Expression, with field:
116                    i: instance of struct inner
117                  from aggregate:
118                    Applying untyped:
119                        Name: *?
120                    ...to:
121                        Variable Expression: _dst: pointer to instance of struct outer
122                Member Expression, with field:
123                  i: instance of struct inner
124                from aggregate:
125                  Variable Expression: _src: instance of struct outer
126
127                  Expression Statement:
128            Applying untyped:
129                Name: ?=?
130            ...to:
131                Address of:
132                  Member Expression, with field:
133                    f4: double
134                  from aggregate:
135                    Applying untyped:
136                        Name: *?
137                    ...to:
138                        Variable Expression: _dst: pointer to instance of struct outer
139                Member Expression, with field:
140                  f4: double
141                from aggregate:
142                  Variable Expression: _src: instance of struct outer
143
144                  Return Statement, returning: Variable Expression: _src: instance of struct outer
145
146
147
148s: instance of struct outer
149sp: pointer to instance of struct outer
150t1: const volatile tuple of types
151    signed int
152    signed int
153
154t2: static const tuple of types
155    signed int
156    const signed int
157
158t3: static const tuple of types
159    signed int
160    const signed int
161
162printf: function
163    with parameters
164      fmt: pointer to char
165      and a variable number of other arguments
166    returning
167      rc: signed int
168
169printf: function
170    with parameters
171      fmt: pointer to char
172      and a variable number of other arguments
173    returning
174      signed int
175
176f1: function
177    with parameters
178      w: signed int
179    returning
180      x: short signed int
181      y: unsigned int
182    with body
183      CompoundStmt
184                  Expression Statement:
185            Applying untyped:
186                Name: ?=?
187            ...to:
188                Address of:
189                  Tuple:
190                                          Name: y
191
192                                          Name: x
193
194                Applying untyped:
195                    Name: ?=?
196                ...to:
197                    Address of:
198                      Tuple:
199                                                  Name: x
200
201                                                  Name: y
202
203                    Tuple:
204                                              Name: w
205
206                      constant expression 23 signed int
207
208
209g1: function
210    returning
211      r: tuple of types
212          signed int
213          char
214          long signed int
215          signed int
216
217    with body
218      CompoundStmt
219        Declaration of x: short signed int
220        Declaration of p: short signed int
221        Declaration of y: unsigned int
222        Declaration of z: tuple of types
223            signed int
224            signed int
225
226                  Expression Statement:
227            Applying untyped:
228                Name: ?=?
229            ...to:
230                Address of:
231                  Tuple:
232                                          Name: x
233
234                                          Name: y
235
236                                          Name: z
237
238                Tuple:
239                                      Name: p
240
241                                      Applying untyped:
242                        Name: f
243                    ...to:
244constant expression 17 signed int
245                  constant expression 3 signed int
246
247                  Expression Statement:
248            Applying untyped:
249                Name: ?=?
250            ...to:
251                Address of:
252                  Tuple:
253                                          Name: x
254
255                                          Name: y
256
257                                          Name: z
258
259                Cast of:
260                  Tuple:
261                                          Name: p
262
263                                          Applying untyped:
264                          Name: f
265                      ...to:
266constant expression 17 signed int
267                    constant expression 3 signed int
268
269                to:
270                  short signed int
271                  unsigned int
272                  tuple of types
273                      signed int
274                      signed int
275
276
277                  Expression Statement:
278            Applying untyped:
279                Name: ?=?
280            ...to:
281                Address of:
282                  Name: r
283                Tuple:
284                                      Name: x
285
286                                      Name: y
287
288                                      Name: z
289
290
291
292main: C function
293    with parameters
294      argc: signed int
295      argv: pointer to pointer to char
296    returning
297      rc: signed int
298    with body
299      CompoundStmt
300        Declaration of a: signed int
301        Declaration of b: signed int
302        Declaration of c: signed int
303        Declaration of d: signed int
304        Declaration of t: instance of struct outer with initializer
305          Compound initializer: 
306            Simple Initializer:               Tuple:
307                                  Name: 1
308
309                constant expression 7.0 double
310
311              designated by:                 Name: f1
312                Name: f4
313
314                  Expression Statement:
315            Applying untyped:
316                Name: f
317            ...to:
318                Tuple:
319                  constant expression 3 signed int
320                  constant expression 5 signed int
321
322                  Expression Statement:
323            Applying untyped:
324                Name: g
325            ...to:
326                Tuple:
327                  constant expression 3 signed int
328                  constant expression 5 signed int
329constant expression 3 signed int
330                  Expression Statement:
331            Applying untyped:
332                Name: f
333            ...to:
334                Name: t1
335
336                  Expression Statement:
337            Applying untyped:
338                Name: g
339            ...to:
340                Name: t1
341constant expression 3 signed int
342                  Expression Statement:
343            Tuple:
344
345                  Expression Statement:
346            Tuple:
347              constant expression 3 signed int
348              constant expression 5 signed int
349
350                  Expression Statement:
351            Applying untyped:
352                Name: ?=?
353            ...to:
354                Address of:
355                  Tuple:
356                                          Name: a
357
358                                          Name: b
359
360constant expression 3 signed int
361                  Expression Statement:
362            Applying untyped:
363                Name: ?=?
364            ...to:
365                Address of:
366                  Tuple:
367                                          Name: a
368
369                                          Name: b
370
371                Tuple:
372                  constant expression 4.6 double
373
374                  Expression Statement:
375            Applying untyped:
376                Name: ?=?
377            ...to:
378                Address of:
379                  Tuple:
380                                          Name: a
381
382                                          Name: b
383
384                Applying untyped:
385                    Name: ?=?
386                ...to:
387                    Address of:
388                      Tuple:
389                                                  Name: c
390
391                                                  Name: d
392
393                    Tuple:
394                      constant expression 3 signed int
395                      constant expression 5 signed int
396
397                  Expression Statement:
398            Applying untyped:
399                Name: ?=?
400            ...to:
401                Address of:
402                  Tuple:
403                                          Name: a
404
405                                          Name: b
406
407                                          Tuple:
408                                                  Name: c
409
410
411                Tuple:
412                  constant expression 2 signed int
413                                      Tuple:
414                                              Name: a
415
416                                              Name: b
417
418
419
420                  Expression Statement:
421            Applying untyped:
422                Name: ?=?
423            ...to:
424                Address of:
425                  Tuple:
426                                          Name: a
427
428                                          Name: b
429
430                Conditional expression on:
431                  Cast of:
432                    Applying untyped:
433                        Name: ?!=?
434                    ...to:
435                        Applying untyped:
436                            Name: ?>?
437                        ...to:
438constant expression 3 signed int constant expression 4 signed int                         Name: 0
439
440                  to:
441                    signed int
442                First alternative:
443                  Tuple:
444                                          Name: b
445
446                    constant expression 6 signed int
447                Second alternative:
448                  Tuple:
449                    constant expression 7 signed int
450                    constant expression 8 signed int
451
452
453                  Expression Statement:
454            Applying untyped:
455                Name: ?=?
456            ...to:
457                Address of:
458                  Name: t1
459                Tuple:
460                                      Name: a
461
462                                      Name: b
463
464
465                  Expression Statement:
466            Applying untyped:
467                Name: ?=?
468            ...to:
469                Address of:
470                  Name: t1
471                Applying untyped:
472                    Name: ?=?
473                ...to:
474                    Address of:
475                      Name: t2
476                    Tuple:
477                                              Name: a
478
479                                              Name: b
480
481
482                  Expression Statement:
483            Applying untyped:
484                Name: ?=?
485            ...to:
486                Address of:
487                  Tuple:
488                                          Name: a
489
490                                          Name: b
491
492                Applying untyped:
493                    Name: ?=?
494                ...to:
495                    Address of:
496                      Tuple:
497                                                  Name: c
498
499                                                  Name: d
500
501                    Applying untyped:
502                        Name: ?+=?
503                    ...to:
504                        Address of:
505                          Name: d
506                        Applying untyped:
507                            Name: ?+=?
508                        ...to:
509                            Address of:
510                              Name: c
511                            Name: 1
512
513                  Expression Statement:
514            Applying untyped:
515                Name: ?=?
516            ...to:
517                Address of:
518                  Tuple:
519                                          Name: a
520
521                                          Name: b
522
523                Applying untyped:
524                    Name: ?=?
525                ...to:
526                    Address of:
527                      Tuple:
528                                                  Name: c
529
530                                                  Name: d
531
532                    Name: t1
533
534                  Expression Statement:
535            Applying untyped:
536                Name: ?=?
537            ...to:
538                Address of:
539                  Tuple:
540                                          Name: a
541
542                                          Name: b
543
544                Applying untyped:
545                    Name: ?=?
546                ...to:
547                    Address of:
548                      Name: t1
549                    Tuple:
550                                              Name: c
551
552                                              Name: d
553
554
555                  Expression Statement:
556            Applying untyped:
557                Name: ?=?
558            ...to:
559                Address of:
560                  Tuple:
561                                          Name: a
562
563                                          Name: b
564
565                Applying untyped:
566                    Name: ?=?
567                ...to:
568                    Address of:
569                      Name: t1
570                    Applying untyped:
571                        Name: ?=?
572                    ...to:
573                        Address of:
574                          Name: t2
575                        Tuple:
576                                                      Name: c
577
578                                                      Name: d
579
580
581                  Expression Statement:
582            Applying untyped:
583                Name: ?=?
584            ...to:
585                Address of:
586                  Name: t1
587                Applying untyped:
588                    Name: ?=?
589                ...to:
590                    Address of:
591                      Tuple:
592                        constant expression 3 signed int
593                        constant expression 4 signed int
594                    Applying untyped:
595                        Name: ?=?
596                    ...to:
597                        Address of:
598                          Tuple:
599                            constant expression 3 signed int
600                            constant expression 4 signed int
601                        Applying untyped:
602                            Name: ?=?
603                        ...to:
604                            Address of:
605                              Name: t1
606                            Tuple:
607                              constant expression 3 signed int
608                              constant expression 4 signed int
609
610                  Expression Statement:
611            Applying untyped:
612                Name: ?=?
613            ...to:
614                Address of:
615                  Name: s
616                Tuple:
617                  constant expression 11 signed int
618                  constant expression 12 signed int
619                  constant expression 13 signed int
620                  constant expression 3.14159 double
621
622                  Expression Statement:
623            Applying untyped:
624                Name: ?=?
625            ...to:
626                Address of:
627                  Name: s
628                Applying untyped:
629                    Name: h
630                ...to:
631constant expression 3 signed int constant expression 3 signed int                     Name: 0
632constant expression "abc" array of char with dimension of constant expression 6 unsigned int
633                  Expression Statement:
634            Applying untyped:
635                Name: ?=?
636            ...to:
637                Address of:
638                  Tuple:
639                                          Name: a
640
641                                          Name: b
642
643                Applying untyped:
644                    Name: h
645                ...to:
646constant expression 3 signed int constant expression 3 signed int                     Name: 0
647constant expression "abc" array of char with dimension of constant expression 6 unsigned int
648                  Expression Statement:
649            Applying untyped:
650                Name: ?=?
651            ...to:
652                Address of:
653                  Name: sp
654                Name: sp
655
656                  Expression Statement:
657            Applying untyped:
658                Name: printf
659            ...to:
660constant expression "expecting 3, 17, 23, 4; got %d, %d, %d, %d\n" array of char with dimension of constant expression 47 unsigned int                 Name: s
661
662                  Expression Statement:
663            Applying untyped:
664                Name: ?=?
665            ...to:
666                Address of:
667                  Name: rc
668                Name: 0
669
670
Note: See TracBrowser for help on using the repository browser.