PR5909 had a test case for binding of const, non-volatile references

to bitfields. Add it here.

llvm-svn: 94832
This commit is contained in:
Douglas Gregor 2010-01-29 19:42:41 +00:00
parent d1e08648c6
commit aa6050b0e2
1 changed files with 12 additions and 0 deletions

View File

@ -0,0 +1,12 @@
// RUN: %clang_cc1 -fsyntax-only -verify %s
namespace PR5909 {
struct Foo {
int x : 20;
};
bool Test(const int& foo);
const Foo f = { 0 }; // It compiles without the 'const'.
bool z = Test(f.x);
}