octave-maintainers
[Top][All Lists]
Advanced

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

Re: C++11 now default?


From: Mike Miller
Subject: Re: C++11 now default?
Date: Thu, 18 Feb 2016 18:15:03 -0800
User-agent: Mutt/1.5.24 (2015-08-30)

On Thu, Feb 18, 2016 at 17:30:36 -0800, Rik wrote:
> Changset 21304:0cf6c08cb252 uses Autoconf macros to check for the presence
> of a C++ compiler that supports the 2011 standard, and defaults to that
> compiler if it exists.  This is producing a lot of warnings because the
> Octave code base is not written to that standard.  For example:
> 
>  ./liboctave/util/unwind-prot.h:71:14: warning: 'template<class> class
> std::auto_ptr' is deprecated [-Wdeprecated-declarations]
> 
> I don't mind shifting if that is the consensus decision, but we should make
> it a conscious choice.  It has been 5 years since the standard was
> published, but I'm sure Octave also gets compiled on ancient machines where
> there may not be a 2011-compliant compiler.

My understanding from previous discussions, and from patch #8906 where
this was worked out, is that the intent is to allow the compiler to use
the newest standard when available, but that we are not going to start
requiring a C++11 compatible compiler at all.

By the way, when gcc 6 starts to become available in distros soon, it
will enable the GNU flavors of C11 and C++14 by default without any -std
options.

Yes, I see the same warnings as you and it's a little annoying, and
maybe we can test for the availability of std::unique_ptr and
conditionally use that instead of std::auto_ptr.

-- 
mike



reply via email to

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