Changeset 914844e


Ignore:
Timestamp:
Nov 24, 2020, 3:50:17 PM (10 months ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
arm-eh, jacob/cs343-translation, master, new-ast-unique-expr
Children:
53e28a7
Parents:
18fe0fe
Message:

fix attributes and completeType error for new ast (only x64)

Location:
tests
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • tests/.expect/attributes.nast.x64.txt

    r18fe0fe r914844e  
    639639    __attribute__ ((unused)) signed int (*_X10_retval_f3PA0i_1)[];
    640640}
    641 __attribute__ ((unused,used,unused)) signed int (*_X2f4FFi_i____1())(signed int __anonymous_object1);
    642 __attribute__ ((unused,unused)) signed int (*_X2f4FFi_i____1())(__attribute__ ((unused)) signed int __anonymous_object2){
    643     __attribute__ ((unused)) signed int (*_X10_retval_f4Fi_i__1)(signed int __anonymous_object3);
     641__attribute__ ((unused,used,unused)) signed int (*_X2f4FFi_i____1())(signed int __param_0);
     642__attribute__ ((unused,unused)) signed int (*_X2f4FFi_i____1())(signed int __param_0){
     643    __attribute__ ((unused)) signed int (*_X10_retval_f4Fi_i__1)(signed int __param_0);
    644644}
    645645signed int _X3vtrFi___1(){
     
    671671signed int _X4tpr2Fi_PPi__1(__attribute__ ((unused,unused,unused,unused,unused,unused)) signed int **_X3FooPPi_1);
    672672signed int _X4tpr3Fi_Pi__1(__attribute__ ((unused,unused,unused)) signed int *_X3FooPi_1);
    673 signed int _X4tpr4Fi_Fi_Pi___1(__attribute__ ((unused,unused)) signed int (*__anonymous_object4)(__attribute__ ((unused,unused)) signed int __anonymous_object5[((unsigned long int )5)]));
     673signed int _X4tpr4Fi_Fi_Pi___1(__attribute__ ((unused,unused)) signed int (*__anonymous_object1)(signed int __param_0[((unsigned long int )5)]));
    674674signed int _X4tpr5Fi_Fi____1(__attribute__ ((unused,unused,unused)) signed int (*_X3FooFi___1)());
    675675signed int _X4tpr6Fi_Fi____1(__attribute__ ((unused,unused,unused)) signed int (*_X3FooFi___1)());
    676 signed int _X4tpr7Fi_Fi_Fi_i____1(__attribute__ ((unused,unused)) signed int (*__anonymous_object6)(__attribute__ ((unused)) signed int (*__anonymous_object7)(__attribute__ ((unused,unused)) signed int __anonymous_object8)));
     676signed int _X4tpr7Fi_Fi_Fi_i____1(__attribute__ ((unused,unused)) signed int (*__anonymous_object2)(signed int (*__param_0)(signed int __param_0)));
    677677signed int _X2adFi___1(){
    678678    __attribute__ ((unused)) signed int _X10_retval_adi_1;
     
    692692
    693693    {
    694         ((void)sizeof(__attribute__ ((unused,unused,unused)) signed int [((unsigned long int )5)]));
    695     }
    696 
    697     {
    698         ((void)sizeof(__attribute__ ((unused,unused,unused)) signed int (*)[((unsigned long int )10)]));
     694        ((void)sizeof(__attribute__ ((unused,unused,unused)) signed int [5]));
     695    }
     696
     697    {
     698        ((void)sizeof(__attribute__ ((unused,unused,unused)) signed int (*)[10]));
    699699    }
    700700
     
    776776
    777777}
    778 signed int _X4apd1Fi_PiPi__1(__attribute__ ((unused,unused,unused)) signed int *__anonymous_object9, __attribute__ ((unused,unused,unused)) signed int *__anonymous_object10);
    779 signed int _X4apd2Fi_PPiPPi__1(__attribute__ ((unused,unused,unused,unused)) signed int **__anonymous_object11, __attribute__ ((unused,unused,unused,unused)) signed int **__anonymous_object12);
    780 signed int _X4apd3Fi_PiPi__1(__attribute__ ((unused,unused,unused)) signed int *__anonymous_object13, __attribute__ ((unused,unused,unused)) signed int *__anonymous_object14);
    781 signed int _X4apd4Fi_Fi__Fi____1(__attribute__ ((unused,unused,unused)) signed int (*__anonymous_object15)(), __attribute__ ((unused,unused,unused)) signed int (*__anonymous_object16)());
    782 signed int _X4apd5Fi_Fi_i_Fi_i___1(__attribute__ ((unused,unused,unused)) signed int (*__anonymous_object17)(__attribute__ ((unused)) signed int __anonymous_object18), __attribute__ ((unused,unused,unused)) signed int (*__anonymous_object19)(__attribute__ ((unused)) signed int __anonymous_object20));
    783 signed int _X4apd6Fi_Fi__Fi____1(__attribute__ ((unused,unused,unused)) signed int (*__anonymous_object21)(), __attribute__ ((unused,unused,unused)) signed int (*__anonymous_object22)());
    784 signed int _X4apd7Fi_Fi_i_Fi_i___1(__attribute__ ((unused,unused,unused)) signed int (*__anonymous_object23)(__attribute__ ((unused)) signed int __anonymous_object24), __attribute__ ((unused,unused,unused)) signed int (*__anonymous_object25)(__attribute__ ((unused)) signed int __anonymous_object26));
     778signed int _X4apd1Fi_PiPi__1(__attribute__ ((unused,unused,unused)) signed int *__anonymous_object3, __attribute__ ((unused,unused,unused)) signed int *__anonymous_object4);
     779signed int _X4apd2Fi_PPiPPi__1(__attribute__ ((unused,unused,unused,unused)) signed int **__anonymous_object5, __attribute__ ((unused,unused,unused,unused)) signed int **__anonymous_object6);
     780signed int _X4apd3Fi_PiPi__1(__attribute__ ((unused,unused,unused)) signed int *__anonymous_object7, __attribute__ ((unused,unused,unused)) signed int *__anonymous_object8);
     781signed int _X4apd4Fi_Fi__Fi____1(__attribute__ ((unused,unused,unused)) signed int (*__anonymous_object9)(), __attribute__ ((unused,unused,unused)) signed int (*__anonymous_object10)());
     782signed int _X4apd5Fi_Fi_i_Fi_i___1(__attribute__ ((unused,unused,unused)) signed int (*__anonymous_object11)(signed int __param_0), __attribute__ ((unused,unused,unused)) signed int (*__anonymous_object12)(signed int __param_0));
     783signed int _X4apd6Fi_Fi__Fi____1(__attribute__ ((unused,unused,unused)) signed int (*__anonymous_object13)(), __attribute__ ((unused,unused,unused)) signed int (*__anonymous_object14)());
     784signed int _X4apd7Fi_Fi_i_Fi_i___1(__attribute__ ((unused,unused,unused)) signed int (*__anonymous_object15)(signed int __param_0), __attribute__ ((unused,unused,unused)) signed int (*__anonymous_object16)(signed int __param_0));
    785785struct Vad {
    786786    __attribute__ ((unused)) signed int :4;
  • tests/errors/.expect/completeType.nast.x64.txt

    r18fe0fe r914844e  
    1313          function
    1414        ... with parameters
    15           intrinsic pointer to instance of type DT (not function type)
     15          pointer to instance of type DT (not function type)
    1616        ... returning
    17           _retval__operator_deref: reference to instance of type DT (not function type)
    18           ... with attributes:
    19             Attribute with name: unused
     17          reference to instance of type DT (not function type)
    2018
    21 
    22       ... to arguments
    23         Variable Expression: x: pointer to instance of struct A with body 0
     19        ... to arguments
     20        Variable Expression: x: pointer to instance of struct B with body
    2421
    2522    ... to: nothing
    2623  (types:
    27     void 
     24    void
    2825  )
    29   Environment: -> instance of struct A with body 0 (no widening)
     26  Environment:( _99_2_DT ) -> instance of struct B with body (no widening)
    3027
    3128
     
    3633          function
    3734        ... with parameters
    38           intrinsic pointer to instance of type DT (not function type)
     35          pointer to instance of type DT (not function type)
    3936        ... returning
    40           _retval__operator_deref: reference to instance of type DT (not function type)
    41           ... with attributes:
    42             Attribute with name: unused
     37          reference to instance of type DT (not function type)
    4338
    44 
    45       ... to arguments
    46         Variable Expression: x: pointer to instance of struct B with body 1
     39        ... to arguments
     40        Variable Expression: x: pointer to instance of struct A without body
    4741
    4842    ... to: nothing
    4943  (types:
    50     void 
     44    void
    5145  )
    52   Environment: -> instance of struct B with body 1 (no widening)
     46  Environment:( _99_2_DT ) -> instance of struct A without body (no widening)
    5347
    5448
    5549
    56 errors/completeType.cfa:35:1 error: No reasonable alternatives for expression Applying untyped:
     50errors/completeType.cfa:35:1 error: Invalid application of existing declaration(s) in expression Applying untyped:
    5751  Name: foo
    5852...to:
    5953  Name: v
    6054
    61 errors/completeType.cfa:36:1 error: No reasonable alternatives for expression Applying untyped:
     55errors/completeType.cfa:36:1 error: Invalid application of existing declaration(s) in expression Applying untyped:
    6256  Name: baz
    6357...to:
    6458  Name: v
    6559
    66 errors/completeType.cfa:37:1 error: No reasonable alternatives for expression Applying untyped:
     60errors/completeType.cfa:37:1 error: Invalid application of existing declaration(s) in expression Applying untyped:
    6761  Name: quux
    6862...to:
    6963  Name: v
    7064
    71 errors/completeType.cfa:59:1 error: No reasonable alternatives for expression Applying untyped:
     65errors/completeType.cfa:59:1 error: Invalid application of existing declaration(s) in expression Applying untyped:
    7266  Name: baz
    7367...to:
    7468  Name: y
    7569
    76 errors/completeType.cfa:60:1 error: No reasonable alternatives for expression Applying untyped:
     70errors/completeType.cfa:60:1 error: Invalid application of existing declaration(s) in expression Applying untyped:
    7771  Name: quux
    7872...to:
     
    9488                  instance of type T (not function type)
    9589                ... returning
    96                   _retval__operator_assign: instance of type T (not function type)
    97                   ... with attributes:
    98                     Attribute with name: unused
    99 
     90                  instance of type T (not function type)
    10091
    10192                ?{}: pointer to function
     
    121112            ... returning nothing
    122113
    123           ... to arguments
     114            ... to arguments
    124115            Variable Expression: z: pointer to instance of type T (not function type)
     116          with 1 pending inference slots
    125117
    126118        (types:
    127           void 
     119          void
    128120        )
    129         Environment: -> instance of type T (not function type) (no widening)
     121        Environment:( _118_0_T ) -> instance of type T (not function type) (no widening)
    130122
    131123      Could not satisfy assertion:
    132124?=?: pointer to function
    133125        ... with parameters
    134           reference to instance of type _110_0_T (not function type)
    135           instance of type _110_0_T (not function type)
     126          reference to instance of type _118_0_T (not function type)
     127          instance of type _118_0_T (not function type)
    136128        ... returning
    137           _retval__operator_assign: instance of type _110_0_T (not function type)
    138           ... with attributes:
    139             Attribute with name: unused
     129          instance of type _118_0_T (not function type)
    140130
    141 
Note: See TracChangeset for help on using the changeset viewer.