Hi Matthew,

On Wed, Jan 7, 2009 at 4:36 PM, Matthew Fuesz <[email protected]> wrote:
> Blanket-supression of C4706 isn't really a good thing, since as you pointed 
> out, it can actually point out an error (usually a typo by the developer). 
> C4706 will not be generated if it is made explicitly clear what the intent of 
> the conditional is.
>
> i.e., instead of checking "if ( a = fxn() )", check "if ( (a = fxn()) != 0 
> )". This is covered in the MSDN page on C4706.
>
> I actually prefer the latter syntax (which doesn't generate C4706) anyway, 
> since it eliminates any possible confusion as to the intended operations.

All the instances if assignment in condtionaly already have a () added
around the conditional to avoid the warning under gcc, I had hoped
that this would be the end of it... but no...

Personally I've got others things to chase up right now that are more
important than adding more superfluous code to the OSG to fix silly
warnings that have no relevance to fixing bugs in the OSG.  Feel free
to dive in if you feel so inclined, otherwise I'll be happy to stick
with the surpression of this warning under VS.

Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to