summaryrefslogtreecommitdiff
path: root/test/FrontendC++/2005-02-20-BrokenReferenceTest.cpp
blob: 31026d30e90c7fe2e2f9fae7cf70800511a5065b (plain)
1
2
3
4
5
6
7
8
9
10
11
// RUN: %llvmgxx %s -S -o /dev/null

void test(unsigned char *b, int rb) {
  typedef unsigned char imgfoo[10][rb];
  imgfoo &br = *(imgfoo *)b;

  br[0][0] = 1;

  rb = br[0][0];
}