Re: pgindent behavior we could do without
| От | Noah Misch |
|---|---|
| Тема | Re: pgindent behavior we could do without |
| Дата | |
| Msg-id | 20130719032235.GA102571@tornado.leadboat.com обсуждение исходный текст |
| Ответ на | pgindent behavior we could do without (Tom Lane <tgl@sss.pgh.pa.us>) |
| Ответы |
Re: pgindent behavior we could do without
|
| Список | pgsql-hackers |
On Thu, Jul 18, 2013 at 12:27:21AM -0400, Tom Lane wrote:
> It's always annoyed me that pgindent insists on adjusting vertical
> whitespace around #else and related commands. This has, for example,
> rendered src/include/storage/barrier.h nigh illegible: you get things
> like
>
> /*
> * lwsync orders loads with respect to each other, and similarly with stores.
> * But a load can be performed before a subsequent store, so sync must be used
> * for a full memory barrier.
> */
> #define pg_memory_barrier() __asm__ __volatile__ ("sync" : : : "memory")
> #define pg_read_barrier() __asm__ __volatile__ ("lwsync" : : : "memory")
> #define pg_write_barrier() __asm__ __volatile__ ("lwsync" : : : "memory")
> #elif defined(__alpha) || defined(__alpha__) /* Alpha */
>
> which makes it look like this block of code has something to do with
> Alpha.
Agreed. I've similarly disliked how pgindent adds a blank line between an #if
and a multi-line comment, like at the top of get_restricted_token().
--
Noah Misch
EnterpriseDB http://www.enterprisedb.com
В списке pgsql-hackers по дате отправления: