Re: Further news on Clang - spurious warnings
От | Peter Geoghegan |
---|---|
Тема | Re: Further news on Clang - spurious warnings |
Дата | |
Msg-id | CAEYLb_W-7ZBvG3Fe9HCz9CPhieUc5egmnyBDPEQX0diAGmC6vQ@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Further news on Clang - spurious warnings (Peter Geoghegan <peter@2ndquadrant.com>) |
Ответы |
Re: Further news on Clang - spurious warnings
|
Список | pgsql-hackers |
Now, apart from the Flex warning, there are just 3 warnings left. They all look like this: repl_gram.y:106:30: warning: implicit conversion from enumeration type 'enum ReplNodeTag' to different enumeration type 'NodeTag' (aka 'enum NodeTag') [-Wconversion] (yyval.node) = (Node *) makeNode(IdentifySystemCmd); ^~~~~~~~~~~~~~~~~~~~~~~~~~~ ../../../src/include/nodes/nodes.h:475:64: note: expanded from: #define makeNode(_type_) ((_type_ *) newNode(sizeof(_type_),T_##_type_)) ^ <scratch space>:180:1: note: expanded from: T_IdentifySystemCmd ^ ../../../src/include/nodes/nodes.h:452:19: note: expanded from: _result->type = (tag); \ ~ ^~~ Attached patch fixes all 3 warnings with an explicit cast, so the number of warnings with Clang is the same number as GCC 4.5 - 1. On GCC 4.6, there are still quite a few -Wunused-but-set-variable warnings left despite an effort to eradicate them. Perhaps I should look into that next. -- Peter Geoghegan http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training and Services
Вложения
В списке pgsql-hackers по дате отправления: