Hi, there
Thanks for the help. I tried it in the way you suggested, but got all the
following errors (I am using gcc 3.3):
/mnt/eniac/home3/c/cis570/install/gcc-3.3/bin/g++ -c test_set.cc
/mnt/eniac/home3/c/cis570/install/gcc-3.3/include/c++/3.3.1/bits/stl_algo.h:
In
function `_OutputIter std::set_union(_InputIter1, _InputIter1,
_InputIter2,
_InputIter2, _OutputIter) [with _InputIter1 =
std::_Rb_tree_iterator<std::string, const std::string&, const
std::string*>,
_InputIter2 = std::_Rb_tree_iterator<std::string, const std::string&,
const
std::string*>, _OutputIter = std::_Rb_tree_iterator<std::string, const
std::string&, const std::string*>]':
test_set.cc:43: instantiated from here
/mnt/eniac/home3/c/cis570/install/gcc-3.3/include/c++/3.3.1/bits/stl_algo.h:
3667: error: passing
`const std::string' as `this' argument of `std::basic_string<_CharT,
_Traits, _Alloc>& std::basic_string<_CharT, _Traits,
_Alloc>:
perator=(const std::basic_string<_CharT, _Traits, _Alloc>&)
[with
_CharT = char, _Traits = std::char_traits<char>, _Alloc =
std::allocator<char>]' discards qualifiers
test_set.cc:43: instantiated from here
/mnt/eniac/home3/c/cis570/install/gcc-3.3/include/c++/3.3.1/bits/stl_algo.h:
3671: error: passing
`const std::string' as `this' argument of `std::basic_string<_CharT,
_Traits, _Alloc>& std::basic_string<_CharT, _Traits,
_Alloc>:
perator=(const std::basic_string<_CharT, _Traits, _Alloc>&)
[with
_CharT = char, _Traits = std::char_traits<char>, _Alloc =
std::allocator<char>]' discards qualifiers
/mnt/eniac/home3/c/cis570/install/gcc-3.3/include/c++/3.3.1/bits/stl_algo.h:
3675: error: passing
`const std::string' as `this' argument of `std::basic_string<_CharT,
_Traits, _Alloc>& std::basic_string<_CharT, _Traits,
_Alloc>:
perator=(const std::basic_string<_CharT, _Traits, _Alloc>&)
[with
_CharT = char, _Traits = std::char_traits<char>, _Alloc =
std::allocator<char>]' discards qualifiers
/mnt/eniac/home3/c/cis570/install/gcc-3.3/include/c++/3.3.1/bits/stl_algobas
e.h: In
function `_OutputIter std::__copy(_InputIter, _InputIter, _OutputIter,
std::input_iterator_tag) [with _InputIter =
std::_Rb_tree_iterator<std::string, const std::string&, const
std::string*>,
_OutputIter = std::_Rb_tree_iterator<std::string, const std::string&,
const
std::string*>]':
/mnt/eniac/home3/c/cis570/install/gcc-3.3/include/c++/3.3.1/bits/stl_algobas
e.h:260: instantiated from `_OutputIter std::__copy_aux2(_InputIter,
_InputIter, _OutputIter, __false_type) [with _InputIter =
std::_Rb_tree_iterator<std::string, const std::string&, const std::string*>,
_OutputIter = std::_Rb_tree_iterator<std::string, const std::string&, const
std::string*>]'
/mnt/eniac/home3/c/cis570/install/gcc-3.3/include/c++/3.3.1/bits/stl_algobas
e.h:303: instantiated from `_OutputIter std::__copy_ni2(_InputIter,
_InputIter, _OutputIter, __false_type) [with _InputIter =
std::_Rb_tree_iterator<std::string, const std::string&, const std::string*>,
_OutputIter = std::_Rb_tree_iterator<std::string, const std::string&, const
std::string*>]'
/mnt/eniac/home3/c/cis570/install/gcc-3.3/include/c++/3.3.1/bits/stl_algobas
e.h:323: instantiated from `_OutputIter std::__copy_ni1(_InputIter,
_InputIter, _OutputIter, __false_type) [with _InputIter =
std::_Rb_tree_iterator<std::string, const std::string&, const std::string*>,
_OutputIter = std::_Rb_tree_iterator<std::string, const std::string&, const
std::string*>]'
/mnt/eniac/home3/c/cis570/install/gcc-3.3/include/c++/3.3.1/bits/stl_algobas
e.h:349: instantiated from `_OutputIter std::copy(_InputIter, _InputIter,
_OutputIter) [with _InputIter = std::_Rb_tree_iterator<std::string, const
std::string&, const std::string*>, _OutputIter =
std::_Rb_tree_iterator<std::string, const std::string&, const
std::string*>]'
/mnt/eniac/home3/c/cis570/install/gcc-3.3/include/c++/3.3.1/bits/stl_algo.h:
3681: instantiated from `_OutputIter std::set_union(_InputIter1,
_InputIter1, _InputIter2, _InputIter2, _OutputIter) [with _InputIter1 =
std::_Rb_tree_iterator<std::string, const std::string&, const std::string*>,
_InputIter2 = std::_Rb_tree_iterator<std::string, const std::string&, const
std::string*>, _OutputIter = std::_Rb_tree_iterator<std::string, const
std::string&, const std::string*>]'
test_set.cc:43: instantiated from here
/mnt/eniac/home3/c/cis570/install/gcc-3.3/include/c++/3.3.1/bits/stl_algobas
e.h:228: error: passing
`const std::string' as `this' argument of `std::basic_string<_CharT,
_Traits, _Alloc>& std::basic_string<_CharT, _Traits,
_Alloc>:
perator=(const std::basic_string<_CharT, _Traits, _Alloc>&)
[with
_CharT = char, _Traits = std::char_traits<char>, _Alloc =
std::allocator<char>]' discards qualifiers
make: *** [test_set.o] Error 1