+2004-07-20 Joseph S. Myers <jsm@polyomino.org.uk>
+
+ * gcc.dg/pr12625-1.c: New test.
+
2004-07-20 Steven Bosscher <stevenb@suse.de>
* testsuite/gcc.dg/switch-warn-1.c: New test.
--- /dev/null
+/* Warning for assignment used as truth-value should apply for
+ bit-fields. */
+/* Origin: bug 12625 from nomura at netapp.com */
+/* { dg-do compile } */
+/* { dg-options "-Wparentheses" } */
+
+static struct { int i:8; } s;
+
+void
+foo ()
+{
+ if (s.i = 0) ; /* { dg-warning "parentheses" "warning for bit-field" } */
+}