cc1plus: error: candidates are: #‘tree_list’ not supported by dump_decl#<declaration error>

source code clone download copy to clipboard

ShareThisreport bug / make suggestion

1
2
3
4
5
6
7
8
9
10
 int x; 
      namespace A {  int x; }
      namespace B {  int x; }
      int main()
       {
        using namespace A;
        using namespace B;
         x;  // error : ambiguity between A::i & B::i
        return 0;
       }

prog.cpp: In function ‘int main()’:
prog.cpp:8: error: reference to ‘x’ is ambiguous
cc1plus: error: candidates are: #‘tree_list’ not supported by dump_decl#<declaration error>
prog.cpp:2: error:                 int A::x
prog.cpp:8: error: reference to ‘x’ is ambiguous
cc1plus: error: candidates are: #‘tree_list’ not supported by dump_decl#<declaration error>
prog.cpp:2: error:                 int A::x

posted on 2011-10-11 17:55  foreveryl  阅读(1043)  评论(0编辑  收藏  举报