[futurebasic] Re: [FB] Swift - nibless window and button

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : June 2014 : Group Archive : Group : All Groups

From: Brian S <fblistserve@...>
Date: Thu, 5 Jun 2014 09:39:49 -0700
Ken Shmidheiser wrote:

> p.s. I'm glad to see semicolons go.
Roger that. Semi-colons are more for the language parser than the programmer. There are other ways for a parser to detect the end of a statement ( as proved by other languages including FB’s FBtoC translator ).

btw: one comment for the article Ken linked to highlights how Apple is moving away from verbosity and IMO that’s good:

Xcode 4:  
NSArray *names = [[NSArray alloc] initWithObjects: @"Tom", @"Dick", @"Harry", nil];

Xcode 5:
NSArray *names = @[@"Tom", @"Dick", @"Harry"];

let names = ["Tom", "Dick", "Harry"]

For FBers in particular it’s worth noting Apple’s implicit assumption that strings are always NSStrings/CFStrings ( i.e. strings that can handle multi-byte characters and other pros unlike pascal strings ). Why? Because it shows us where Apple is focused and where it isn’t. Even though pascal strings themselves aren’t deprecated, there are many clues ( such as deprecation of APIs that support pascal strings ) warning us.