Boost logo

Boost :

Subject: Re: [boost] [timer] May I apply trivial fix?
From: Agustín K-ballo Bergé (kaballo86_at_[hidden])
Date: 2013-08-02 18:33:38

On 02/08/2013 06:25 a.m., Andrey Semashev wrote:
> On Friday 02 August 2013 12:52:56 Antony Polukhin wrote:
>> Hi,
>> As far as I know Beman is almost always busy, so may I apply trivial fix
>> described in this ticket ?
>> This fix is essential for running regression tests with Intel compiler.
> I recently made a workaround in Boost.Test for this problem [1] but I simply
> dropped noncopyable and replaced it with deleted functions. I wonder if
> there's any need for noncopyable now besides backward compatibility.
> [1]

Doesn't a defaulted function get the access level it would get if
implicitly declared? In C++11 mode the singleton constructor and
destructor would be public. At least gcc-4.8.1 thinks so:

This are the relevant paragraphs in the standard to support that
(emphasis mine):

Explicitly-defaulted functions and implicitly-declared functions are
collectively called defaulted functions, and the implementation shall
provide implicit definitions for them (12.1 12.4, 12.8), which might
mean defining them as deleted. (...)

[class.ctor]/4: A default constructor for a class X is a constructor of
class X that can be called without an argument. If there is no
user-declared constructor for class X, a constructor having no
parameters is implicitly declared as defaulted (8.4). An
implicitly-declared default constructor is an inline **public** member
of its class. (...)


Agustín K-ballo Bergé.-

Boost list run by bdawes at, gregod at, cpdaniel at, john at