Stories
Slash Boxes
Comments

SoylentNews is people

posted by martyb on Sunday June 14 2015, @10:44PM   Printer-friendly
from the swift-rise-in-popularity dept.

The hype around Swift is near non-existent by Apple standards, yet the language has attracted high praise since its release last year. Swift is essentially one of the very few Apple products representing a clear departure from the hardware-led approach Steve Jobs took to the business. If Stack Overflow's 2015 dev survey is anything to go by, it looks as if the Swift language might have potential to really shake things up.

Might the days of Apple programmers relying upon objective C be numbered?


Original Submission

 
This discussion has been archived. No new comments can be posted.
Display Options Threshold/Breakthrough Mark All as Read Mark All as Unread
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
  • (Score: 2) by kaszz on Sunday June 14 2015, @11:17PM

    by kaszz (4211) on Sunday June 14 2015, @11:17PM (#196279) Journal

    Does Swift have general and basic benefits over other languages? will the standardization and usage be stable over decades? Does it have any real world application benefit outside of the Apple hegemony?

    The Apple APIs are Objective-C so they will stay around for a while. But the replacement better measure up or there will be deep trouble ahead.

    Starting Score:    1  point
    Karma-Bonus Modifier   +1  

    Total Score:   2  
  • (Score: 3, Interesting) by NCommander on Sunday June 14 2015, @11:30PM

    by NCommander (2) Subscriber Badge <michael@casadevall.pro> on Sunday June 14 2015, @11:30PM (#196284) Homepage Journal

    My understanding is swif tis basically wrapping over the ObjC APIs, so its 1:1 functionality, or put in another way, Swift is a new language with ABI compatibility with ObjC message passing. I tried to play with ObjC, and while I think in some ways its better than C++, TBH, the syntax is very hard to grok. This is compounded by the fact that a lot of stuff at ObjC is detected at runtime vs compile time.

    Please note, I'm just a hobbist, never did a major project in ObjC

    --
    Still always moving
    • (Score: 4, Disagree) by kaszz on Sunday June 14 2015, @11:59PM

      by kaszz (4211) on Sunday June 14 2015, @11:59PM (#196288) Journal

      I'm just suspicious that this falls into:
        * Hey cool we have written our own language that doesn't add anything than more book reading for you and fragmentation
        * We must change language every so often to keep up with fashion because we lack impulse control
        * Not invented here!
        * We need this extra thing so we make a whole new language
        * Our developers have skills to make use of other platforms so lets force them to use our language so they forget others

      • (Score: 0) by Anonymous Coward on Monday June 15 2015, @02:03AM

        by Anonymous Coward on Monday June 15 2015, @02:03AM (#196323)

        > Our developers have skills to make use of other platforms so lets force them to use our language so they forget others

        They are saying some of the right words, [opensource.com] deeds are still pending.

      • (Score: 5, Informative) by BasilBrush on Monday June 15 2015, @05:19AM

        by BasilBrush (3994) on Monday June 15 2015, @05:19AM (#196363)

        * Hey cool we have written our own language that doesn't add anything than more book reading for you and fragmentation

        There are a number of unique and very nice features in Swift.

        * We must change language every so often to keep up with fashion because we lack impulse control

        Apple has been using Obj-C as it's major language for 15 years. OSX(including it's pervious incarnation as NextStep) for 26 years.

        * Not invented here!

        There is no existing language that has the fundamental requirement that it supports the existing Cocoa frameworks.

        * We need this extra thing so we make a whole new language

        Apple already has de-facto control over objective-c and has been adding extra things over the years. Including this year.

        * Our developers have skills to make use of other platforms so lets force them to use our language so they forget others

        No change over Obj-C.

        So all your suspicions are stupid.

        --
        Hurrah! Quoting works now!
        • (Score: 2) by kaszz on Tuesday June 16 2015, @06:35PM

          by kaszz (4211) on Tuesday June 16 2015, @06:35PM (#196980) Journal

          There is no existing language that has the fundamental requirement that it supports the existing Cocoa frameworks.

          Does the Cocoa framework bring any new possibilities to the computing except being able to do graphics in the Apple ecosystem?

    • (Score: 2) by bzipitidoo on Monday June 15 2015, @02:03PM

      by bzipitidoo (4388) on Monday June 15 2015, @02:03PM (#196486) Journal

      I took a cursory look at Swift, and get the impression it's Python with curly braces instead of indentation (or, can think of it as C/C++ without semicolons and with better looping), with much simpler syntax for using the Objective C/C++/Cocoa libraries than Objective C/C++ itself.

      I think the religious fervor over Object Oriented Programming faded years ago, and now people can see that while OOP has its points, it also has plenty of issues. I was never sure about the value of the whole idea of an inheritance hierarchy, just seemed too rigid to try to organize data that way.

  • (Score: 2) by c0lo on Monday June 15 2015, @02:28AM

    by c0lo (156) Subscriber Badge on Monday June 15 2015, @02:28AM (#196332) Journal

    The Apple APIs are Objective-C so they will stay around for a while. But the replacement better measure up or there will be deep trouble ahead.

    Remember the good old MS OLE [wikipedia.org] and what it meant for VB*?
    Well, seems that Apple "innovated" their own version of VB and are pretty proud about it. Perhaps over the years they'll get to evolve it into the equivalent of Java/dontNetFramework.

    * VB as in Visual Basic, not Victoria Bitter [wikipedia.org]

    --
    https://www.youtube.com/watch?v=aoFiw2jMy-0 https://soylentnews.org/~MichaelDavidCrawford
    • (Score: 3, Insightful) by BasilBrush on Monday June 15 2015, @05:22AM

      by BasilBrush (3994) on Monday June 15 2015, @05:22AM (#196364)

      Remember the good old MS OLE and what it meant for VB*?

      However if you think Swift is in any way comparable to VB, you're a cluless idiot.

      --
      Hurrah! Quoting works now!
      • (Score: 1, Flamebait) by c0lo on Monday June 15 2015, @06:01AM

        by c0lo (156) Subscriber Badge on Monday June 15 2015, @06:01AM (#196374) Journal

        However if you think Swift is in any way comparable to VB, you're a cluless idiot.

        Really? Doesn't it serve for Apple the same purpose as the old VB did for MS?
        I mean... "make available the Godness of our API to masses. Because, you know... developers, developers, developers... memory management and whatnot is too hard for the wannabe programmer" (I still remember the days before the dotcom bust, everybody and their dog would got hired with "I know VB" on their CV - 'cause, you know, before ASPX and other dontNet goodnesses MS came afterwards, the VB was the "language of Web as decreed by Microsoft").

        Yeah, sure, maybe it's more evolved than VB, but in the end... it only runs on Apple - very much like VB used to run only on MS. Yet another point they somehow resemble, don't yea think?

        --
        https://www.youtube.com/watch?v=aoFiw2jMy-0 https://soylentnews.org/~MichaelDavidCrawford
        • (Score: 5, Informative) by BasilBrush on Monday June 15 2015, @07:22AM

          by BasilBrush (3994) on Monday June 15 2015, @07:22AM (#196385)

          Really? Doesn't it serve for Apple the same purpose as the old VB did for MS?

          No. This isn't an easy to use option for casual use. This is a replacement of the professional languages both for apps and systems programming.

          it only runs on Apple

          Wrong. Linux and open source is part of the v2.0 release.

          --
          Hurrah! Quoting works now!
          • (Score: 2) by c0lo on Monday June 15 2015, @08:58AM

            by c0lo (156) Subscriber Badge on Monday June 15 2015, @08:58AM (#196402) Journal

            it only runs on Apple

            Wrong. Linux and open source is part of the v2.0 release.

            It may seem pedantic, but I detect a slightly misleading use of tense time. The as precise as possible way to put it is:

            Linux and open source will be part of the v2.0 release. Sometime "later this year" [theregister.co.uk]

            On the other side, what should I be so enthused by Swift on Linux? For some +Informative mods, what does the language brings new/useful to Linux? (why should I believe is something else than an expression of Not-Invented-Here-Syndrome coming from Apple?)
            Does it have some standard libraries besides OSX/Cocoa to make it useful? Multi-threading, async/futures... something?

            --
            https://www.youtube.com/watch?v=aoFiw2jMy-0 https://soylentnews.org/~MichaelDavidCrawford
            • (Score: 2) by BasilBrush on Monday June 15 2015, @03:26PM

              by BasilBrush (3994) on Monday June 15 2015, @03:26PM (#196537)

              You shouldn't be excited at all. You hate Apple and thus won't be using it. Some of the more open minded language experimenters will though.

              --
              Hurrah! Quoting works now!
          • (Score: 4, Insightful) by c0lo on Monday June 15 2015, @11:00AM

            by c0lo (156) Subscriber Badge on Monday June 15 2015, @11:00AM (#196421) Journal

            This is a replacement of the professional languages both for apps and systems

            Groan... Really? [wikipedia.org]

            Swift uses Automatic Reference Counting (ARC) to manage memory. Apple used to require manual memory management in Objective-C, but introduced ARC in 2011 to allow for easier memory allocation and deallocation.[29] One problem with ARC is the possibility of creating a strong reference cycle, where instances of two different classes each include a reference to the other, causing them to become leaked into memory as they are never released. Swift provides the weak and unowned keywords that allow the programmer to prevent strong reference cycles from occurring. Typically a parent-child relationship would use a strong reference while a child-parent would use either weak reference, where parents and children can be unrelated, or unowned where a child always has a parent, but parent may not have a child.

            Because... you know?... there's never going to be a relation between siblings, it will always be an asymmetrical parent-child-like relationship.
            Yes, circular lists or bidi-graphs with cycles are evil constructs one is never going to need in practice.

            Those foolish younsters with disdain for ancient wisdom [catb.org] are in for surprises:

            One day a student came to Moon and said: “I understand how to make a better garbage collector. We must keep a reference count of the pointers to each cons.”

            Moon patiently told the student the following story:

            “One day a student came to Moon and said: ‘I understand how to make a better garbage collector...

            --
            https://www.youtube.com/watch?v=aoFiw2jMy-0 https://soylentnews.org/~MichaelDavidCrawford
            • (Score: 3, Touché) by BasilBrush on Monday June 15 2015, @03:23PM

              by BasilBrush (3994) on Monday June 15 2015, @03:23PM (#196535)

              Really.

              Because... you know?... there's never going to be a relation between siblings, it will always be an asymmetrical parent-child-like relationship.
              Yes, circular lists or bidi-graphs with cycles are evil constructs one is never going to need in practice.

              Just because it is possible to write software that has circular references, doesn't mean that properly written software ever has them. Put the correct attributes on properties and there is no problem I've been programming with ARC for years and literally never had a bug of that nature.

              ARC is NOT a garbage collector. That's your first mistake.

              --
              Hurrah! Quoting works now!
            • (Score: 2) by kaszz on Tuesday June 16 2015, @06:27PM

              by kaszz (4211) on Tuesday June 16 2015, @06:27PM (#196975) Journal

              "to allow for easier" alright, then only idiots will use it .. ;-)

              It sounds more and more like Swift might be useful to learn if creating apps for iPhone is your task. Otherwise it's just another NIH thing waiting to be scrapped.

  • (Score: 0) by Anonymous Coward on Monday June 15 2015, @10:08AM

    by Anonymous Coward on Monday June 15 2015, @10:08AM (#196413)

    Does Swift have general and basic benefits over other languages?

    I guess the advantage is that you can use it in situations where you otherwise would have been forced to use Objective C.