OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [warn/] [pr36069.C] - Blame information for rev 701

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
// PR c++/36069 Strange "warning: suggest parentheses around
2
// assignment used as truth value" with volatile/non volatile bools
3
// { dg-do compile }
4
// { dg-options "-Wparentheses" }
5
struct foo {
6
  bool a;
7
  volatile bool b,c;
8
  foo() { a = b = c = false; } // { dg-bogus "parentheses" }
9
};
10
 
11
int main() {
12
  bool a;
13
  volatile bool b,c;
14
  a = b = c = false; // { dg-bogus "parentheses" }
15
  foo A;
16
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.