diff options
Diffstat (limited to 'BlocksRuntime/tests/block-static.c')
-rw-r--r-- | BlocksRuntime/tests/block-static.c | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/BlocksRuntime/tests/block-static.c b/BlocksRuntime/tests/block-static.c new file mode 100644 index 000000000000..d38c816cf015 --- /dev/null +++ b/BlocksRuntime/tests/block-static.c @@ -0,0 +1,25 @@ +// +// The LLVM Compiler Infrastructure +// +// This file is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. + +// testfilerunner CONFIG + +#include <stdio.h> + + +int main(int argc, char **argv) { + static int numberOfSquesals = 5; + + ^{ numberOfSquesals = 6; }(); + + if (numberOfSquesals == 6) { + printf("%s: success\n", argv[0]); + return 0; + } + printf("**** did not update static local, rdar://6177162\n"); + return 1; + +} + |