Re: [Proposal] Level4 Warnings show many shadow vars
От | Robert Haas |
---|---|
Тема | Re: [Proposal] Level4 Warnings show many shadow vars |
Дата | |
Msg-id | CA+TgmoYh+qHFYVnH2ihw5+SiVwGEmFkWiZaO0E-rv5hNbaeirA@mail.gmail.com обсуждение исходный текст |
Ответ на | [Proposal] Level4 Warnings show many shadow vars (Ranier Vilela <ranier_gyn@hotmail.com>) |
Ответы |
RE: [Proposal] Level4 Warnings show many shadow vars
|
Список | pgsql-hackers |
On Tue, Dec 3, 2019 at 8:24 PM Ranier Vilela <ranier_gyn@hotmail.com> wrote: > I believe PostgreSQL can benefit from changing the alert level of compilation warnings. > The current Level3 level for windows does not show any alerts, but that does not mean that there are no problems. > Changing the level to Level4 and its equivalent for GCC in Unix environments will show many warnings for shadow variables,including global variables. > True, there will also be many silly alerts that can be safely disabled. > Shadow variables, although they may not currently represent bugs, may be hiding errors, or at the very least, it is a wasteof variable declaration. > With the current Level3 level, development is no longer checking and correcting shadow variables. > > Any comments? Most of us don't develop on Windows, so changing warning levels on Windows won't really affect what developers see on their own machines, and thus probably doesn't have much value. It might be a good idea to try to clean up some/many cases of shadowed variables, though. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company
В списке pgsql-hackers по дате отправления: