Re: [HACKERS] Compiler warning cleanup - unitilized const variables, pointer type mismatch

2009-05-29 Thread Zdenek Kotala
Tom Lane píše v čt 28. 05. 2009 v 11:42 -0400: Zdenek Kotala zdenek.kot...@sun.com writes: I attached another cleanup patch which fixes following warnings reported by Sun Studio: I'm not too impressed with any of these. The proposed added initializers just increase future maintenance

Re: [HACKERS] Compiler warning cleanup - unitilized const variables, pointer type mismatch

2009-05-29 Thread Zdenek Kotala
Tom Lane píše v čt 28. 05. 2009 v 11:57 -0400: ). AFAICS, Sun's compiler is just too stupid and shouldn't be emitting this warning. Perhaps the right response is to file a bug report against the compiler. I checked it and it is already know bug. It is new lint style check in Sun Studio

Re: [HACKERS] Compiler warning cleanup - unitilized const variables, pointer type mismatch

2009-05-29 Thread Tom Lane
Zdenek Kotala zdenek.kot...@sun.com writes: Tom Lane píše v čt 28. 05. 2009 v 11:42 -0400: The proposed signature change on psql_completion is going to replace a warning on your system with outright failures on other people's. I check readline and definition is still same at least from

[HACKERS] Compiler warning cleanup - unitilized const variables, pointer type mismatch

2009-05-28 Thread Zdenek Kotala
I attached another cleanup patch which fixes following warnings reported by Sun Studio: zic.c, line 1534: warning: const object should have initializer: tzh0 dynloader.c, line 7: warning: empty translation unit pgstat.c, line 666: warning: const object should have initializer: all_zeroes

Re: [HACKERS] Compiler warning cleanup - unitilized const variables, pointer type mismatch

2009-05-28 Thread Michael Meskes
On Thu, May 28, 2009 at 11:11:20AM +0200, Zdenek Kotala wrote: I attached another cleanup patch which fixes following warnings reported by Sun Studio: ... preproc.c, line 39569: warning: pointer expression or its operand do not point to the same object yyerror_range, result is undefined and

Re: [HACKERS] Compiler warning cleanup - unitilized const variables, pointer type mismatch

2009-05-28 Thread Zdenek Kotala
Michael Meskes píše v čt 28. 05. 2009 v 13:33 +0200: On Thu, May 28, 2009 at 11:11:20AM +0200, Zdenek Kotala wrote: I attached another cleanup patch which fixes following warnings reported by Sun Studio: ... preproc.c, line 39569: warning: pointer expression or its operand do not

Re: [HACKERS] Compiler warning cleanup - unitilized const variables, pointer type mismatch

2009-05-28 Thread Michael Meskes
On Thu, May 28, 2009 at 01:51:07PM +0200, Zdenek Kotala wrote: Problem is with YYLLOC_DEFAULT. When I look on macro definition #define YYLLOC_DEFAULT(Current, Rhs, N) \ Current.first_line = Rhs[1].first_line; \ Current.first_column = Rhs[1].first_column;\

Re: [HACKERS] Compiler warning cleanup - unitilized const variables, pointer type mismatch

2009-05-28 Thread Zdenek Kotala
Michael Meskes píše v čt 28. 05. 2009 v 14:47 +0200: On Thu, May 28, 2009 at 01:51:07PM +0200, Zdenek Kotala wrote: Problem is with YYLLOC_DEFAULT. When I look on macro definition #define YYLLOC_DEFAULT(Current, Rhs, N) \ Current.first_line = Rhs[1].first_line; \

Re: [HACKERS] Compiler warning cleanup - unitilized const variables, pointer type mismatch

2009-05-28 Thread Tom Lane
Zdenek Kotala zdenek.kot...@sun.com writes: I attached another cleanup patch which fixes following warnings reported by Sun Studio: I'm not too impressed with any of these. The proposed added initializers just increase future maintenance effort without solving any real problem (since the

Re: [HACKERS] Compiler warning cleanup - unitilized const variables, pointer type mismatch

2009-05-28 Thread Tom Lane
Michael Meskes mes...@postgresql.org writes: I have to admit that those version look strikingly unsimilar to me. There is no reference to Rhs[N] in our macro at all. But then I have no idea whether this is needed. The default version of the macro is intended to track both the starting and