Top "Objective-c-literals" questions

Clang 3.1 and Apple's LLVM 4.0 introduced new literal syntax for object creation and collection indexing in Objective-C, allowing simpler use of NSNumber, NSArray and NSDictionary.

What are the details of "Objective-C Literals" mentioned in the Xcode 4.4 release notes?

I was going through the release notes for Xcode 4.4 and noticed this: LLVM 4.0 Compiler Xcode now includes the Apple LLVM …

objective-c xcode objective-c-literals
Is there some literal dictionary or array syntax in Objective-C?

It's always been possible to create NSArrays (and NSDictionaries/NSNumber) with vararg method calls, like: [NSArray arrayWithObjects: @"a", @"b", @"c", …

objective-c llvm clang objective-c-literals
iOS: "attempt to insert nil object from objects[1]" when creating dictionary

I'm creating a custom navigation bar class and customizing it's title attributes using the following code: self.titleTextAttributes = @{ UITextAttributeFont: bariol, …

objective-c objective-c-literals
Is there a literal syntax for mutable collections?

I know I can create an NSArray with @[@"foo", @"bar"] or an NSDictionary with @{@0 : @"foo", @1 : @"bar"}. Is there a literal …

objective-c cocoa nsmutablearray nsmutabledictionary objective-c-literals
Compiler error "expected method not found" when using subscript on NSArray

I wrote this simple code to try out the new Objective-C literal syntax for NSArrays: NSArray *array = @[@"foo"]; NSLog(@"%@", array[0]); …

objective-c cocoa compiler-errors nsarray objective-c-literals
Difference between @[] and [NSArray arrayWithObjects:]

Possible Duplicate: Should I prefer to use literal syntax or constructors for creating dictionaries and arrays? Is there any difference …

objective-c nsarray objective-c-literals
What is the difference between @YES/@NO and YES/NO?

In Objective-c what is the difference between @YES/@NO and YES/NO? What types are used for each?

objective-c boolean objective-c-literals
Accessing keys in NSDictionary using [key] notation?

I have just realised that I can access NSDictionary using both objectForKey: and dict[key]? NSDictionary *coordsDict = @{@"xpos": @5.0, @"ypos": @7.2, @"zpos": @15.7}; …

objective-c nsdictionary objective-c-literals