Re: How to eliminate assignment operator generation warning
- From: David Lowndes <davidl@xxxxxxxxxxxxxxx>
- Date: Sat, 23 Jul 2005 09:35:52 +0100
>I'm using Microsoft Development Environment 2002 Version 7.0.9466 on
>Windows XP Professional Service Pack 2. If I compile the following
>code at maximum warning level:
>...
>I get the following warning:
>... warning C4512: 'SetValue' : assignment operator could not be
>generated
> ... see declaration of 'SetValue'
FWIW, the Comeau online compiler agrees with VC++ - it reports a more
useful message:
"ComeauTest.c", line 3: error: implicitly generated assignment
operator cannot copy:
reference member "SetValue::m_value"
>What is causing the warning and how can I eliminate it?
Add an assignment operator to the class.
Dave
--
MVP VC++ FAQ: http://www.mvps.org/vcfaq
.
- Follow-Ups:
- Re: How to eliminate assignment operator generation warning
- From: Tron Thomas
- Re: How to eliminate assignment operator generation warning
- References:
- How to eliminate assignment operator generation warning
- From: tron . thomas
- How to eliminate assignment operator generation warning
- Prev by Date: How to eliminate assignment operator generation warning
- Next by Date: Re: How to eliminate assignment operator generation warning
- Previous by thread: How to eliminate assignment operator generation warning
- Next by thread: Re: How to eliminate assignment operator generation warning
- Index(es):
Relevant Pages
|