@@ -101,7 +101,7 @@ typedef struct
101
101
* class? */
102
102
} ObjectPropertyType ;
103
103
104
- static ObjectPropertyType ObjectProperty [] =
104
+ static const ObjectPropertyType ObjectProperty [] =
105
105
{
106
106
{
107
107
CastRelationId ,
@@ -431,7 +431,7 @@ static ObjectAddress get_object_address_type(ObjectType objtype,
431
431
List * objname , bool missing_ok );
432
432
static ObjectAddress get_object_address_opcf (ObjectType objtype , List * objname ,
433
433
List * objargs , bool missing_ok );
434
- static ObjectPropertyType * get_object_property_data (Oid class_id );
434
+ static const ObjectPropertyType * get_object_property_data (Oid class_id );
435
435
436
436
static void getRelationDescription (StringInfo buffer , Oid relid );
437
437
static void getOpFamilyDescription (StringInfo buffer , Oid opfid );
@@ -1297,7 +1297,7 @@ get_object_namespace(const ObjectAddress *address)
1297
1297
HeapTuple tuple ;
1298
1298
bool isnull ;
1299
1299
Oid oid ;
1300
- ObjectPropertyType * property ;
1300
+ const ObjectPropertyType * property ;
1301
1301
1302
1302
/* If not owned by a namespace, just return InvalidOid. */
1303
1303
property = get_object_property_data (address -> classId );
@@ -1329,71 +1329,71 @@ get_object_namespace(const ObjectAddress *address)
1329
1329
Oid
1330
1330
get_object_oid_index (Oid class_id )
1331
1331
{
1332
- ObjectPropertyType * prop = get_object_property_data (class_id );
1332
+ const ObjectPropertyType * prop = get_object_property_data (class_id );
1333
1333
1334
1334
return prop -> oid_index_oid ;
1335
1335
}
1336
1336
1337
1337
int
1338
1338
get_object_catcache_oid (Oid class_id )
1339
1339
{
1340
- ObjectPropertyType * prop = get_object_property_data (class_id );
1340
+ const ObjectPropertyType * prop = get_object_property_data (class_id );
1341
1341
1342
1342
return prop -> oid_catcache_id ;
1343
1343
}
1344
1344
1345
1345
int
1346
1346
get_object_catcache_name (Oid class_id )
1347
1347
{
1348
- ObjectPropertyType * prop = get_object_property_data (class_id );
1348
+ const ObjectPropertyType * prop = get_object_property_data (class_id );
1349
1349
1350
1350
return prop -> name_catcache_id ;
1351
1351
}
1352
1352
1353
1353
AttrNumber
1354
1354
get_object_attnum_name (Oid class_id )
1355
1355
{
1356
- ObjectPropertyType * prop = get_object_property_data (class_id );
1356
+ const ObjectPropertyType * prop = get_object_property_data (class_id );
1357
1357
1358
1358
return prop -> attnum_name ;
1359
1359
}
1360
1360
1361
1361
AttrNumber
1362
1362
get_object_attnum_namespace (Oid class_id )
1363
1363
{
1364
- ObjectPropertyType * prop = get_object_property_data (class_id );
1364
+ const ObjectPropertyType * prop = get_object_property_data (class_id );
1365
1365
1366
1366
return prop -> attnum_namespace ;
1367
1367
}
1368
1368
1369
1369
AttrNumber
1370
1370
get_object_attnum_owner (Oid class_id )
1371
1371
{
1372
- ObjectPropertyType * prop = get_object_property_data (class_id );
1372
+ const ObjectPropertyType * prop = get_object_property_data (class_id );
1373
1373
1374
1374
return prop -> attnum_owner ;
1375
1375
}
1376
1376
1377
1377
AttrNumber
1378
1378
get_object_attnum_acl (Oid class_id )
1379
1379
{
1380
- ObjectPropertyType * prop = get_object_property_data (class_id );
1380
+ const ObjectPropertyType * prop = get_object_property_data (class_id );
1381
1381
1382
1382
return prop -> attnum_acl ;
1383
1383
}
1384
1384
1385
1385
AclObjectKind
1386
1386
get_object_aclkind (Oid class_id )
1387
1387
{
1388
- ObjectPropertyType * prop = get_object_property_data (class_id );
1388
+ const ObjectPropertyType * prop = get_object_property_data (class_id );
1389
1389
1390
1390
return prop -> acl_kind ;
1391
1391
}
1392
1392
1393
1393
bool
1394
1394
get_object_namensp_unique (Oid class_id )
1395
1395
{
1396
- ObjectPropertyType * prop = get_object_property_data (class_id );
1396
+ const ObjectPropertyType * prop = get_object_property_data (class_id );
1397
1397
1398
1398
return prop -> is_nsp_name_unique ;
1399
1399
}
@@ -1419,10 +1419,10 @@ is_objectclass_supported(Oid class_id)
1419
1419
/*
1420
1420
* Find ObjectProperty structure by class_id.
1421
1421
*/
1422
- static ObjectPropertyType *
1422
+ static const ObjectPropertyType *
1423
1423
get_object_property_data (Oid class_id )
1424
1424
{
1425
- static ObjectPropertyType * prop_last = NULL ;
1425
+ static const ObjectPropertyType * prop_last = NULL ;
1426
1426
int index ;
1427
1427
1428
1428
/*
0 commit comments