]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
Don't call c++ constructors directly by name.
authorMark Wielaard <mjw@redhat.com>
Thu, 25 Nov 2010 13:02:44 +0000 (14:02 +0100)
committerMark Wielaard <mjw@redhat.com>
Thu, 25 Nov 2010 13:02:44 +0000 (14:02 +0100)
g++ 4.5 doesn't like to call constructors by name directly.
http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_defects.html#147

libdw/c++/dwarf
libdw/c++/dwarf_output
libdw/c++/line_info.cc

index 975c1545f44e5abf9a3201c8d7491d840244c61e..4ab57ce8fad7adab2830e0adc3f99ec91a5bd8d0 100644 (file)
@@ -1,5 +1,5 @@
 /* -*- C++ -*- interfaces for libdw.
-   Copyright (C) 2009 Red Hat, Inc.
+   Copyright (C) 2009, 2010 Red Hat, Inc.
    This file is part of Red Hat elfutils.
 
    Red Hat elfutils is free software; you can redistribute it and/or modify
@@ -2246,7 +2246,7 @@ namespace elfutils
     };
     inline raw_compile_units_type raw_compile_units () const
     {
-      return raw_compile_units_type::raw_compile_units_type (*this);
+      return raw_compile_units_type (*this);
     }
 
   private:
@@ -2295,7 +2295,7 @@ namespace elfutils
     };
     inline class compile_units_type compile_units () const
     {
-      return compile_units_type::compile_units_type (raw_compile_units ());
+      return compile_units_type (raw_compile_units ());
     }
 
   private:
@@ -2491,25 +2491,25 @@ namespace elfutils
   inline class dwarf::debug_info_entry::raw_children_type
   dwarf::debug_info_entry::raw_children () const
   {
-    return raw_children_type::raw_children_type (*this);
+    return raw_children_type (*this);
   }
 
   inline class dwarf::debug_info_entry::children_type
   dwarf::debug_info_entry::children () const
   {
-    return children_type::children_type (*this);
+    return children_type (*this);
   }
 
   inline class dwarf::debug_info_entry::raw_attributes_type
   dwarf::debug_info_entry::raw_attributes () const
   {
-    return raw_attributes_type::raw_attributes_type (*this);
+    return raw_attributes_type (*this);
   }
 
   inline class dwarf::debug_info_entry::attributes_type
   dwarf::debug_info_entry::attributes () const
   {
-    return attributes_type::attributes_type (raw_attributes ());
+    return attributes_type (raw_attributes ());
   }
 
   // Explicit specializations.
index 53decf49304f9aab09796e0b9f6b7012e1cb453a..9e5c1f632d2dc7aa50727b93f605cdf90d706033 100644 (file)
@@ -561,7 +561,7 @@ namespace elfutils
     inline dwarf_output (const input &dw, dwarf_output_collector &c)
     {
       copier<input> maker (c);
-      _m_units.swap (compile_units_type::compile_units_type (dw.compile_units (), maker));
+      _m_units.swap (compile_units_type (dw.compile_units (), maker));
     }
 
     template<typename file>
index b913da626bd20fae5bf236a46229795d9ba93b95..83e625109fa8f631444570df5a502742b34f5496 100644 (file)
@@ -45,7 +45,7 @@ dwarf::attr_value::source_file () const
     default:
       throw std::runtime_error ("XXX not a file name");
     }
-  return source_file::source_file (_m_attr);
+  return dwarf::source_file (_m_attr);
 }
 
 static bool