From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carlo Wood To: egcs@cygnus.com (egcs@cygnus.com) Subject: Annoying warning Date: Sun, 11 Apr 1999 07:29:00 -0000 Message-id: <199904110036.CAA09133@jolan.ppro> X-SW-Source: 1999-04/msg00384.html This code snippet, from the STL: inline int __black_count(__rb_tree_node_base* node, __rb_tree_node_base* root) { if (node == 0) return 0; else { int bc = node->color == __rb_tree_black ? 1 : 0; if (node == root) return bc; else return bc + __black_count(node->parent, root); } } causes this warning when compiled with -g -O3 : /usr/local/egcs/include/g++/stl_tree.h:1045: warning: can't inline call to `int __black_count(struct __rb_tree_node_base *, struct __rb_tree_node_base *)' /usr/local/egcs/include/g++/stl_tree.h:1053: warning: called from here Shouldn't this warning be suppressed for a recursive call? Thanks, -- Carlo Wood From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carlo Wood To: egcs@cygnus.com (egcs@cygnus.com) Subject: Annoying warning Date: Fri, 30 Apr 1999 23:15:00 -0000 Message-ID: <199904110036.CAA09133@jolan.ppro> X-SW-Source: 1999-04n/msg00387.html Message-ID: <19990430231500.FCVU2Hwf8TFyK5xH8bAw3i1_IrGNrv4NOoZ5tloq6Hw@z> This code snippet, from the STL: inline int __black_count(__rb_tree_node_base* node, __rb_tree_node_base* root) { if (node == 0) return 0; else { int bc = node->color == __rb_tree_black ? 1 : 0; if (node == root) return bc; else return bc + __black_count(node->parent, root); } } causes this warning when compiled with -g -O3 : /usr/local/egcs/include/g++/stl_tree.h:1045: warning: can't inline call to `int __black_count(struct __rb_tree_node_base *, struct __rb_tree_node_base *)' /usr/local/egcs/include/g++/stl_tree.h:1053: warning: called from here Shouldn't this warning be suppressed for a recursive call? Thanks, -- Carlo Wood