]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
Must keep identifier and string distinct.
authorRoland McGrath <roland@redhat.com>
Mon, 6 Jul 2009 08:12:48 +0000 (01:12 -0700)
committerRoland McGrath <roland@redhat.com>
Mon, 6 Jul 2009 08:12:48 +0000 (01:12 -0700)
libdw/c++/dwarf_data

index 12bae8fdd84a394914ec3661e921733ea346d642..cb412d3029a41e7e40572799d93fd938edd70ffc 100644 (file)
@@ -794,6 +794,8 @@ namespace elfutils
 
       struct value_identifier : public value_string
       {
+       inline value_identifier () {}
+
        template<typename id, typename arg_type>
        inline value_identifier (const id &s, arg_type &arg)
          : value_string (s, arg)
@@ -1155,12 +1157,14 @@ namespace elfutils
 
       inline const std::string &identifier () const
       {
-       return string ();
+       return static_cast<const std::string &>
+         (variant<typename vw::value_identifier> ());
       }
 
       inline std::string &identifier ()
       {
-       return string ();
+       return static_cast<std::string &>
+         (variant<typename vw::value_identifier> ());
       }
 
       inline const typename impl::source_file &source_file () const