Re: Patch for : src/Lib/vpf/database path

Frederic Bouvier <[email protected]> Sat, 22 Jan 2005 15:49:13 +0100
Newsgroups gmane.games.flightgear.terragear.devel
Message-ID <[email protected]>
Curtis L. Olson a écrit :

> Frederic Bouvier wrote:
>
>> Curtis L. Olson wrote :
>>
>>> Frederic Bouvier wrote:
>>>
>>>> Paul Surgeon a écrit :
>>>>
>>>>> GCC 3.4 doesn't like a copy constructor as a private member of a 
>>>>> class.
>>>>> It only accepts it as a public member.
>>>>>
>>>>> I'm not sure if that is what is wanted but at least it compiles on 
>>>>> my system now.
>>>>
>>>> Private copy constructor ( and private assignment operator ) are 
>>>> there to prevent objects of that class to be copied. Any attempt 
>>>> result in a compiler error. If the class designer don't want the 
>>>> objects be copied ( because the object must be a singleton or there 
>>>> are resource or performance issues ), it is better to see why the 
>>>> compiler needs to copy objects.
>>>
>>> Hmmm, I have already applied this patch.  Let me know if I should 
>>> back it out.
>>
>> I don't have gcc 3.4 at hand. 
>
> Neither do I, and it's clear there are a lot more clever C++ 
> programmers floating around this project than me.


The fact is that if it was not meant to be called, the copy constructor 
could be totally broken or empty. It could even be non existent but if 
it compiles it is not the case here.

-Fred



_______________________________________________
Terragear-devel mailing list
[email protected]
http://mail.flightgear.org/mailman/listinfo/terragear-devel
2f585eeea02e2c79d7b1d8c4963bae2d