Mark ItemPointer parameters as const in tuple/table lock functions

Поиск
Список
Период
Сортировка
От Chao Li
Тема Mark ItemPointer parameters as const in tuple/table lock functions
Дата
Msg-id CAEoWx2m9e4rECHBwpRE4+GCH+pbYZXLh2f4rB1Du5hDfKug+Og@mail.gmail.com
обсуждение исходный текст
Ответы Re: Mark ItemPointer parameters as const in tuple/table lock functions
Список pgsql-hackers

Hi Hackers,

This is a pure refactor patch.

The functions LockTuple, ConditionalLockTuple, UnlockTuple, and XactLockTableWait take an ItemPointer parameter named 'tid'. Since these functions do not modify the tuple identifier, the parameter should be declared as const to better convey intent and allow the compiler to enforce immutability.

With this patch, build still passes, and "make check" also passes.

Best regards,

--

Chao Li (Evan)
HighGo Software Co., Ltd.
https://www.highgo.com/
Вложения

В списке pgsql-hackers по дате отправления: