@@ -3065,8 +3065,7 @@ unary_identifier_declarator:
3065
3065
{
3066
3066
// the type_qualifier_list is for the pointer,
3067
3067
// and not the identifier_declarator
3068
- stack_type ($1 ).id(ID_pointer);
3069
- stack_type ($1 ).subtype()=typet(ID_abstract);
3068
+ stack_type ($1 )=pointer_type(typet(ID_abstract));
3070
3069
$2 =merge($2 , $1 ); // dest=$2
3071
3070
make_subtype ($3 , $2 ); // dest=$3
3072
3071
$$ =$3 ;
@@ -3250,15 +3249,13 @@ unary_abstract_declarator:
3250
3249
' *'
3251
3250
{
3252
3251
$$ =$1 ;
3253
- set ($$, ID_pointer);
3254
- stack_type ($$).subtype()=typet(ID_abstract);
3252
+ stack_type ($$)=pointer_type(typet(ID_abstract));
3255
3253
}
3256
3254
| ' *' attribute_type_qualifier_list
3257
3255
{
3258
3256
// The type_qualifier_list belongs to the pointer,
3259
3257
// not to the (missing) abstract declarator.
3260
- set ($1 , ID_pointer);
3261
- stack_type ($1 ).subtype()=typet(ID_abstract);
3258
+ stack_type ($1 )=pointer_type(typet(ID_abstract));
3262
3259
$$ =merge($2 , $1 );
3263
3260
}
3264
3261
| ' *' abstract_declarator
@@ -3270,8 +3267,7 @@ unary_abstract_declarator:
3270
3267
{
3271
3268
// The type_qualifier_list belongs to the pointer,
3272
3269
// not to the abstract declarator.
3273
- stack_type ($1 ).id(ID_pointer);
3274
- stack_type ($1 ).subtype()=typet(ID_abstract);
3270
+ stack_type ($1 )=pointer_type(typet(ID_abstract));
3275
3271
$2 =merge($2 , $1 ); // dest=$2
3276
3272
make_subtype ($3 , $2 ); // dest=$3
3277
3273
$$ =$3 ;
@@ -3290,15 +3286,13 @@ parameter_unary_abstract_declarator:
3290
3286
' *'
3291
3287
{
3292
3288
$$ =$1 ;
3293
- set ($$, ID_pointer);
3294
- stack_type ($$).subtype()=typet(ID_abstract);
3289
+ stack_type ($$)=pointer_type(typet(ID_abstract));
3295
3290
}
3296
3291
| ' *' attribute_type_qualifier_list
3297
3292
{
3298
3293
// The type_qualifier_list belongs to the pointer,
3299
3294
// not to the (missing) abstract declarator.
3300
- set ($1 , ID_pointer);
3301
- stack_type ($1 ).subtype()=typet(ID_abstract);
3295
+ stack_type ($1 )=pointer_type(typet(ID_abstract));
3302
3296
$$ =merge($2 , $1 );
3303
3297
}
3304
3298
| ' *' parameter_abstract_declarator
@@ -3310,8 +3304,7 @@ parameter_unary_abstract_declarator:
3310
3304
{
3311
3305
// The type_qualifier_list belongs to the pointer,
3312
3306
// not to the (missing) abstract declarator.
3313
- stack ($1 ).id(ID_pointer);
3314
- stack_type ($1 ).subtype()=typet(ID_abstract);
3307
+ stack_type ($1 )=pointer_type(typet(ID_abstract));
3315
3308
$2 =merge($2 , $1 ); // dest=$2
3316
3309
make_subtype ($3 , $2 ); // dest=$3
3317
3310
$$ =$3 ;
0 commit comments