1/*
2 * Copyright (c) 2010 Apple Inc. All rights reserved.
3 *
4 * @APPLE_LLVM_LICENSE_HEADER@
5 */
6
7//
8//  escape2.m
9//  btest
10//
11//  Created by Apple on 6/12/08.
12//  Copyright 2008 __MyCompanyName__. All rights reserved.
13//
14
15
16#import "common.h"
17
18void test(void) {
19	// validate that escaping a context is enough
20	for (int counter = 0; counter < 10; ++counter) {
21		BYREF int i = 0;
22		vv block = ^{  ++i; };
23		if (i < 9) {
24			lastUse(i);
25			continue; // leave scope early
26		}
27		lastUse(i);
28	}
29}
30