On Fri, Apr 20, 2018 at 7:18 AM, Teodor Sigaev <teo...@sigaev.ru> wrote: > After close look I change my opinion. To have a clean code it's much better > to have new pair get/set macroses specialy to manage link to top pare during > page deletion. This removes last naked usage of > ItemPointer(SetInvalid/IsInvalid/GetBlockNumberNoCheck) and uses > self-described macroses. Patch is attached.
I see your point. Maybe don't have the newline between the get and set, though, to match the existing style. And, the note about the assertion seems unnecessary. I suggest putting something about what general area this deals with. Perhaps something like the following: "Get/set leaf page highkey's link. During the second phase of deletion, the target leaf page's high key may point to an ancestor page (at all other times, the leaf level high key's link is not used). See the nbtree README for full details." -- Peter Geoghegan