This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: , operand with no effect warning


On Mon, Jul 30, 2001 at 06:01:11PM -0400, Phil Edwards wrote:
> On Mon, Jul 30, 2001 at 08:30:03PM +0100, John Levon wrote:
> > 
> > Why does gcc warn for :
> > 
> > 	p1, p2;
> 
> Because this has no effect.
> 
> > but not :
> > 	delete p1, p2;
> 
> Because this does have an effect.

Admittedly, the whole statement has an effect - p1 is deleted.  But the
second operand of the comma is not used, so it would be nice if we
could warn about that somehow.

-- 
Daniel Jacobowitz                           Carnegie Mellon University
MontaVista Software                         Debian GNU/Linux Developer


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]