xref: /llvm-project/lldb/test/API/functionalities/data-formatter/nsdictionarysynth/main.m (revision fdea9a4ec9b0d9585b8fe8a612686d9f44f40ddc)
1#import <Foundation/Foundation.h>
2
3int main (int argc, const char * argv[])
4{
5
6    NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
7
8
9	NSArray* keys = @[@"foo",@"bar",@"baz"];
10	NSArray* values = @[@"hello",@[@"X",@"Y"],@{@1 : @"one",@2 : @"two"}];
11	NSDictionary* dictionary = [NSDictionary dictionaryWithObjects:values forKeys:keys];
12	NSMutableDictionary* mutabledict = [NSMutableDictionary dictionaryWithCapacity:5];
13	[mutabledict setObject:@"123" forKey:@23];
14	[mutabledict setObject:[NSURL URLWithString:@"http://www.apple.com"] forKey:@"foobar"];
15	[mutabledict setObject:@[@"a",@12] forKey:@57];
16	[mutabledict setObject:dictionary forKey:@"sourceofstuff"];
17
18    [pool drain];// Set break point at this line.
19    return 0;
20}
21
22