Live data from Hacker News

The Death of Cocoa

nshipster.com

11–20 of 118 posts

Re: The Death of Cocoa

#11
Am I terrible for loving the minimalist design, and simultaneously wondering how I can read the archives from above the fold on the home page, instead of reading the article?

Re: The Death of Cocoa

#12
post #10
post #9

Earlier quoted context omitted.

The NeXT/Apple ASCII encoding of their PLIST format is very similar to JSON and has been around forever. IIRC TextMate 1 made use of it for much of its bundle system.

NeXT Plists were a lot like JSON, but OSX Plists were XML (or binary). Apple definitely had their anointed interchange format, and it was not JSON, for several reasons -- first among them that Plists predate JavaScript! -- but also because JavaScript types get a bit ambiguous in a ObjC/Cocoa context. Interestingly, Plists can now be XML or JSON (or binary).

> NeXT Plists were a lot like JSON, but OSX Plists were XML (or binary).

Old style text plists are still supported:

    $ cat > /tmp/test.plist
    {
        "david" = "great";
        "array" = ( 1,2,3,4 );
    }

    $ plutil  -convert xml1 /tmp/test.plist -o -
    
    
    
    
    	array
    	
    		1
    		2
    		3
    		4
    	
    	david
    	great
    
    

    $ sw_vers -productVersion
    10.10.1

Re: The Death of Cocoa

#13
>Will Swift unseat Javascript as the only viable web scripting language by adding interpreter to Safari?

Adding Swift to Safari would be an interesting development

Re: The Death of Cocoa

#14

Am I terrible for loving the minimalist design, and simultaneously wondering how I can read the archives from above the fold on the home page, instead of reading the article?

Nope, I love it too. I made my personal website the same way. Long live meaningful and well written text being the focus.

Re: The Death of Cocoa

#15
post #4

"Apple is a company with a long view of technology. It's really difficult to tell whether a technology like JSON is going to stick, or if it's just another fad. Apple once released a framework for PubSub, which despite not being widely known or used, still has to be supported for the foreseeable future. Each technology is a gamble of engineering resources." Apple doubted JSON would be around?

JSON was invented (discovered ;) ) in 2001, the website went up in 2002. Major services like Google and Yahoo were providing their data in JSON format in 2006. If this article is correct, Apple didn't include JSON functionality in Cocoa until 2011 , that's 9 years after the public website and 5 years after inclusion in major web services. This is an eternity in technology time. I personally find the explanation that…

> Just look at this: https://twitter.com/andy_matuschak/status/549268259871002624

"A pragmatic and intentionally non-abstract solution to JSON decoding / initialization that doesn't require learning about five new operators."

What's scary about operators? An API with five new functions doesn't cause the same amount of anxiety, does it?

Re: The Death of Cocoa

#16
Holy clickbait headline, Batman.

Yes, Carbon has been replaced in the past but that involved a $400 million acquisition and 10 years of continual complaining, kicking and screaming from established Carbon users who had no desire to change. I doubt it's an example of how future changes will occur.

Replacing entire application frameworks is hard. Super, super hard. It seems like it might be simple to start by replacing Foundation with Swift's standard library but actually, replacing Foundation would mean replacing every Cocoa framework since they all rely on it. And there's a gigantic amount of work in those frameworks; 25 years of development (all the way back to the early NeXT days).

I think this is why Swift includes such extensive support for Objective-C interoperation: Apple expect Swift will need to link against Objective-C APIs for a long, long time.

I think we're much more likely to see a major deprecation sweep through Cocoa in one or two years time (probably once Swift finally has all the features Apple have hinted are coming). Not deleting things, per se, but simply saying "these things look ugly or silly in Swift" so use these other things instead.

Re: The Death of Cocoa

#17
With Objective-C they had to do a lot of things in higher level (standard library or the framework). With the new shiny language that had tons of features that are remained unused it makes sense to slim down Cocoa and move things to language level.

A good example is string interpolation. Swift makes it unnecessary to have things like `stringWithFormat` in framework level.

Re: The Death of Cocoa

#18
post #15
post #4

Earlier quoted context omitted.

JSON was invented (discovered ;) ) in 2001, the website went up in 2002. Major services like Google and Yahoo were providing their data in JSON format in 2006. If this article is correct, Apple didn't include JSON functionality in Cocoa until 2011 , that's 9 years after the public website and 5 years after inclusion in major web services. This is an eternity in technology time. I personally find the explanation that…

> Just look at this: https://twitter.com/andy_matuschak/status/549268259871002624 "A pragmatic and intentionally non-abstract solution to JSON decoding / initialization that doesn't require learning about five new operators." What's scary about operators? An API with five new functions doesn't cause the same amount of anxiety, does it?

1. The operators are abstract (most people have never seen >>=).

2. Even IF they were functions, (say "bind" and "return"), the actual functions themselves are known to be hard to understand for people.

3. Needing to know these when all you want to do is grab google maps results is the worst place to encounter them. In JavaScript, you don't need to learn "anything", just call JSON.parse. Its fine to encourage learning. When you want to do something completely unrelated that takes no thought in other places though, its a bad place to enforce learning.

Re: The Death of Cocoa

#19
I think vanilla cocoa is being replaced slowly by cocoa touch. They will probably rename it and then force cocoa touch onto macosx. I don't see foundation changing much though. Maybe foundation touch "universal" is coming ;)

Re: The Death of Cocoa

#20
post #13

>Will Swift unseat Javascript as the only viable web scripting language by adding interpreter to Safari? Adding Swift to Safari would be an interesting development

>only viable

But wait, since when was Safari the only viable web browser anyway?

Disclaimer: I'm an Apple fanboy and rMBP user.

Post reply on HN