monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Monotone-devel] Re: [Monotone-debian] Bug#455646: FTBFS with GCC 4.3: m


From: Zack Weinberg
Subject: [Monotone-devel] Re: [Monotone-debian] Bug#455646: FTBFS with GCC 4.3: missing #includes
Date: Fri, 14 Dec 2007 13:20:17 -0800

On Dec 14, 2007 9:31 AM, brian m. carlson
<address@hidden> wrote:
> >> backward/auto_ptr.h:177: warning:
> >> 'hash.std::auto_ptr<Botan::HashFunction>::_M_ptr' is used
> >> uninitialized in this function
> >> botan/dsa_gen.cpp:57: note:
> >> 'hash.std::auto_ptr<Botan::HashFunction>::_M_ptr' was declared here
> >>
> >> Looks spurious; the variable in question is declared with a
> >> constructor expression.  (I am ignorant of what is going on inside
> >> auto_ptr though.)
>
> Assuming it is actually initialized using a constructor, then yes, this
> appears to be spurious.  I haven't actually looked at the botan code,
> though.

It's definitely spurious.  This is a minimal test case:

  #include <string>
  #include <memory>
  class HashFunction {};
  HashFunction *get_hash (std::string const &);
  void generate_dsa_primes (void)
  { std::auto_ptr <HashFunction> hash(get_hash("SHA-160")); }

(If you change get_hash's argument to const char *, the diagnostic
goes away.  Bizarre.)

Is now GCC bug #34470.

zw




reply via email to

[Prev in Thread] Current Thread [Next in Thread]