Re: [GENERAL] C++ port of Postgres

Поиск
Список
Период
Сортировка
Искать
От
Piotr Stefaniak
Тема
Re: [GENERAL] C++ port of Postgres
Дата
Msg-id
AM4PR03MB1586A8AEFEA1CC49EEC0B283F2130@AM4PR03MB1586.eurprd03.prod.outlook.com
Ответ на
Список
Дерево обсуждения
Re: [GENERAL] C++ port of Postgres "dandl" <david@andl.org>
Re: [GENERAL] C++ port of Postgres Andres Freund <andres@anarazel.de>
Re: [GENERAL] C++ port of Postgres "dandl" <david@andl.org>
Re: [GENERAL] C++ port of Postgres 'Andres Freund' <andres@anarazel.de>
Re: [GENERAL] C++ port of Postgres Craig Ringer <craig@2ndquadrant.com>
Re: [GENERAL] C++ port of Postgres Serge Rielau <srielau@gmail.com>
On 2016-08-16 18:33, Robert Haas wrote:
> It wouldn't be that much work to maintain, either: we'd
> just set up some buildfarm members that compiled using C++ and when
> they turned red, we'd go fix it.

I think that there exist subtle differences between C and C++ that 
without compile-time diagnostic could potentially lead to different 
run-time behavior. As an artificial example:

$ cat ./test.c
#include 

int main(void) {FILE *f = fopen("test.bin", "w");if (f == NULL)	return 1;fwrite("1", sizeof '1', 1, f);fclose(f);return 0;
}
$ clang ./test.c -o test
$ ./test
$ hexdump test.bin
0000000 0031 0000
0000004
$ clang++ ./test.c -o test
clang-3.9: warning: treating 'c' input as 'c++' when in C++ mode, this 
behavior is deprecated
$ ./test
$ hexdump test.bin
0000000 0031
0000001
В списке pgsql-hackers по дате отправления
От: Andres Freund
Дата:
Сообщение: Re: LWLocks in DSM memory
От: Peter Geoghegan
Дата:
FAQ