Re: [PATCH] binary heap implementation
| От | Andrew Dunstan |
|---|---|
| Тема | Re: [PATCH] binary heap implementation |
| Дата | |
| Msg-id | 50A51369.1060004@dunslane.net обсуждение исходный текст |
| Ответ на | Re: [PATCH] binary heap implementation (Robert Haas <robertmhaas@gmail.com>) |
| Ответы |
Re: [PATCH] binary heap implementation
|
| Список | pgsql-hackers |
On 11/15/2012 10:11 AM, Robert Haas wrote:
> + {
> + sift_down(heap, i);
> + }
>
> Project style is to omit braces for a single-line body. This comes up
> a few other places as well.
>
I thought we modified that some years ago, although my memory of it is a
bit hazy. Personally I think it's a bad rule, at least as stated, in the
case where there's an else clause with a compound statement. I'd prefer
to see a rule that says that either both branches of an if/else should
be compound statements or neither should be. I think the cases where
only one branch is a compound statement are rather ugly.
cheers
andrew
В списке pgsql-hackers по дате отправления: