Commit 56d4b6fd by Benjamin Kosnik

}

if 0 ambiguous test case

From-SVN: r18845
parent ac50abce
...@@ -5,12 +5,15 @@ ...@@ -5,12 +5,15 @@
void bar ( bool x ) {}; void bar ( bool x ) {};
void bars ( short x ) {}; void bars ( short x ) {};
/* 980326 bkoz this is not initialized and so can have indeterminate value. */
#if 0
int orb(){ int orb(){
bool y; bool y;
bar ( y ); bar ( y );
int blob = ( 27 | int (y) ); int blob = ( 27 | int (y) );
return blob; //expect 27 or 0 return blob; //expect 27 or 0
} }
#endif
int orbtrue(){ int orbtrue(){
bool y = true; bool y = true;
...@@ -51,8 +54,10 @@ int orus(){ ...@@ -51,8 +54,10 @@ int orus(){
int main() { int main() {
int tmp; int tmp;
#if 0
tmp = orb(); tmp = orb();
assert (tmp == 27 || tmp == 0); assert (tmp == 27 || tmp == 0);
#endif
tmp = orbtrue(); tmp = orbtrue();
assert (tmp ==27); assert (tmp ==27);
tmp = orbfalse(); tmp = orbfalse();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment