[PATCH] Fix PR34973, -Wno-strict-aliasing not working

Richard Guenther rguenther@suse.de
Sat May 3 15:23:00 GMT 2008


Fixed thus.

Bootstrapped and tested on x86_64-unknown-linux-gnu, applied to
trunk and the 4.3 branch.

Richard.


2008-05-03  Richard Guenther  <rguenther@suse.de>

	PR middle-end/34973
	* opts.c (set_Wstrict_aliasing): Handle the turn-off case.

Index: opts.c
===================================================================
*** opts.c	(revision 134849)
--- opts.c	(working copy)
*************** set_Wstrict_aliasing (int onoff)
*** 1865,1870 ****
--- 1865,1872 ----
    gcc_assert (onoff == 0 || onoff == 1);
    if (onoff != 0)
      warn_strict_aliasing = 3;
+   else
+     warn_strict_aliasing = 0;
  }
  
  /* The following routines are useful in setting all the flags that



More information about the Gcc-patches mailing list