File tree 1 file changed +5
-2
lines changed
1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -1492,19 +1492,22 @@ void c_typecheck_baset::adjust_function_parameter(typet &type) const
1492
1492
{
1493
1493
if (type.id ()==ID_array)
1494
1494
{
1495
+ source_locationt source_location=type.source_location ();
1495
1496
type=pointer_type (type.subtype ());
1496
- type.remove (ID_size);
1497
- type.remove (ID_C_constant);
1497
+ type.add_source_location ()=source_location;
1498
1498
}
1499
1499
else if (type.id ()==ID_code)
1500
1500
{
1501
1501
// see ISO/IEC 9899:1999 page 199 clause 8,
1502
1502
// may be hidden in typedef
1503
+ source_locationt source_location=type.source_location ();
1503
1504
type=pointer_type (type);
1505
+ type.add_source_location ()=source_location;
1504
1506
}
1505
1507
else if (type.id ()==ID_KnR)
1506
1508
{
1507
1509
// any KnR args without type yet?
1508
1510
type=signed_int_type (); // the default is integer!
1511
+ // no source location
1509
1512
}
1510
1513
}
You can’t perform that action at this time.
0 commit comments