Here's a v2- note on NULL args/returns- ref PointerGetDatum- used your example. Started adding some comments but don't think they're really necessary. The reader gets the point as-is I think.
pgsql-hackers by date:
Соглашаюсь с условиями обработки персональных данных