Update parser's disambiguation to cope with braced function-style casts in
C++11, and with braced-init-list initializers in conditions. This exposed an
ambiguity with enum underlying types versus bitfields, which we resolve by
treating 'enum E : T {' as always defining an enumeration (even if it would
only successfully parse as a bitfield). This appears to be g++ compatible.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151227 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/Parser/cxx0x-condition.cpp b/test/Parser/cxx0x-condition.cpp
index ce7d1a8..e45cd86 100644
--- a/test/Parser/cxx0x-condition.cpp
+++ b/test/Parser/cxx0x-condition.cpp
@@ -27,11 +27,11 @@
   if (S b(n) = 0) {} // expected-error {{a function type is not allowed here}}
   if (S b(n) == 0) {} // expected-error {{a function type is not allowed here}} expected-error {{did you mean '='?}}
 
-  // FIXME: this is legal, and incorrectly rejected, because tentative parsing
-  // does not yet know about braced function-style casts.
-  if (S{a}) {} // unexpected-error{{unqualified-id}}
-
+  if (S{a}) {} // ok
   if (S a{a}) {} // ok
   if (S a = {a}) {} // ok
   if (S a == {a}) {} // expected-error {{did you mean '='?}}
+
+  if (S(b){a}) {} // ok
+  if (S(b) = {a}) {} // ok
 }