Re: Mostly Harmless: c++bookends - patch 2 of 4

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: Mostly Harmless: c++bookends - patch 2 of 4
Дата
Msg-id 200907140051.49450.peter_e@gmx.net
обсуждение исходный текст
Ответ на Re: Mostly Harmless: c++bookends - patch 2 of 4  (Kurt Harriman <harriman@acm.org>)
Ответы Re: Mostly Harmless: c++bookends - patch 2 of 4  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
On Friday 05 December 2008 11:16:37 Kurt Harriman wrote:
> Just a few additional header files are mentioned in the PostgreSQL
>      Reference Manual for add-on developers to use: fmgr.h, funcapi.h,
>      and spi.h.  This patch adds bookends within those three files for
>      the benefit of beginners writing very simple extensions in C++.

I have signed up to review this patch series for the commit fest.

I can try to debunk this approach for selecting the files to add C++ 
decorations in: A grep through contrib/, which includes a variety of simple 
and complex extensions, shows a count of 80 different backend includes being 
used.

So I think either decoration is added to all of these files or none of them.  
And I think the former is not going to go over well.

>      Documentation and learning are simplified because C example code
>      can be compiled as C or C++ without change.

I think having some subset of header files work with C++ without extra 
decoration and some only with extra decoration will not necessarily improve 
documentation and learning.  Forcing people to add the decorations around 
PostgreSQL backend header files will at least make them remember what they are 
dealing with.


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

Предыдущее
От: Robert Haas
Дата:
Сообщение: final preparations for CommitFest 2009-07
Следующее
От: Robert Haas
Дата:
Сообщение: Re: Alpha release process