Stories
Slash Boxes
Comments

SoylentNews is people

posted by martyb on Friday December 01 2017, @04:42PM   Printer-friendly
from the if-some-is-good,-and-more-is-better,-than-too-many-languages-is-not-enough dept.

Google will contribute changes to Apple's Swift programming language, and will support the language in the Fuchsia OS, a presumed replacement for Android, ChromeOS, etc. that is designed to work on all devices:

Fuchsia is Google's not-at-all-but-kind-of-secret operating system that's being developed in the open, but with almost zero official messaging about what it's for, or what it's built to replace. (Android? Chrome OS? Both? Neither?) The operating system's core is written in mostly C and C++, with Dart for the default "Flutter" UI, but other languages like Go, Rust, Python, and now Swift have also found a home in the project.

Of course, just because you'll be able to compile Swift to run on Fuchsia doesn't mean you'll be able to instantly port any iOS app to Google's new OS when or if it ships. While Apple has open sourced the Swift language itself, much of the iOS platform (like the UI stuff, for instance) is closed source, so code that relies on those closed Apple libraries won't be portable.

One possible future in a world where Fuchsia is an important and relevant platform for apps is that you write the "core logic" of your app in your language of choice — Swift, Go, Rust, JavaScript, etc. — and then you build a custom UI for each platform — Android, iOS, Fuchsia, Linux, Windows, the web — using the appropriate tools for each.

Also at Android Police.

Previously: Google's New Non-Linux OS: Fuchsia
Google's Not-So-Secret New OS
Google Fuchsia UI Previewed


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 RamiK on Friday December 01 2017, @09:26PM (9 children)

    by RamiK (1813) on Friday December 01 2017, @09:26PM (#604058)

    Define "modern language".

    Also, no.

    --
    compiling...
    Starting Score:    1  point
    Karma-Bonus Modifier   +1  

    Total Score:   2  
  • (Score: 3, Funny) by DannyB on Friday December 01 2017, @10:02PM (7 children)

    by DannyB (5839) Subscriber Badge on Friday December 01 2017, @10:02PM (#604066) Journal

    Modern, I think of:
    * feels dynamic, but is compiled to executable
    * has strong typing, but infers types rather than being "duck" typing
    * has GC
    * I realize I also conflate "modern" with "higher level, more abstract, further from bare metal"

    Rust is modern, but not what I want to program in.

    --
    People today are educated enough to repeat what they are taught but not to question what they are taught.
    • (Score: 0) by Anonymous Coward on Friday December 01 2017, @10:09PM (5 children)

      by Anonymous Coward on Friday December 01 2017, @10:09PM (#604067)

      Wikipedia [wikipedia.org]:

      Lisp was a difficult system to implement with the compiler techniques and stock hardware of the 1970s. Garbage collection routines, developed by then-MIT graduate student Daniel Edwards, made it practical to run Lisp on general-purpose computing systems, but efficiency was still a problem. This led to the creation of Lisp machines: dedicated hardware for running Lisp environments and programs.

      You know what's modern? A language that allows you to choose what kind of memory management your software will use, including garbage collection; a modern language is one that is built around the notion of "zero-cost abstraction". That language is C++.

      • (Score: 2) by RamiK on Saturday December 02 2017, @02:55AM (2 children)

        by RamiK (1813) on Saturday December 02 2017, @02:55AM (#604131)

        a modern language is one that is built around the notion of "zero-cost abstraction". That language is C++.

        C++ abstractions might not cost you run-time directly (compared to C), but they take longer to develop, optimize and debug which ends up costing you run-time indirectly. Now, if you're a big corporation that can pour money the problem endlessly, you might be able to hire enough smart programmers until you're in the "we're faster then the competition" zone. But the resulting code-base ends-up so hairy that the next feature will take longer to develop and the following will be even harder... Until one day you're stuck like Microsoft with a code-base you can't even afford maintaining.

        Btw, personally if I wanted to go low-level with an opt-in GC and modern language facilities and could satisfy my personal flavor-of-the-month, I'd look at one of the concatenative languages. Kitten [kittenlang.org] for instance, while still young, is looking like everything you'd want from a modernized Forth.

        --
        compiling...
        • (Score: 0) by Anonymous Coward on Saturday December 02 2017, @11:08AM (1 child)

          by Anonymous Coward on Saturday December 02 2017, @11:08AM (#604213)

          Kitten [kittenlang.org] for instance, while still young, is looking like everything you'd want from a modernized Forth.

          "There is an interpreter written in Haskell, and a work-in-progress native code compiler." http://kittenlang.org/faq/ [kittenlang.org]
          If there is a more definite way to spell "stillborn", I've yet to see it.

      • (Score: 2) by Wootery on Saturday December 02 2017, @12:21PM

        by Wootery (2341) on Saturday December 02 2017, @12:21PM (#604234)

        Funny how comments as misguided as yours are always submitted as AC...

        You know what's modern? A language that allows you to choose what kind of memory management your software will use, including garbage collection

        You seem to be using the word 'modern' to mean 'something I like the sound of'.

        Anyway, when it comes to the garbage collection question, modern languages generally pick a side and commit to it, and for good reason: going half-way just confuses things.

        C++ uses RAII extensively, to the point that it doesn't make a lot of sense for them to get serious about supporting GC.

        D supports mixed-mode, but I couldn't name another language that does.

        That language is C++.

        No, it isn't. C++ supports pointer-arithmetic. It lets you do XOR linked lists, for instance, but means you'd better be careful if you want to use it with garbage collection, or the GC will collect still-live objects.

        Almost as disastrously, C++ semantics mean you can't use a garbage collection algorithm that relocates objects, something that all modern GC algorithms do.

      • (Score: 2) by DannyB on Monday December 04 2017, @02:46PM

        by DannyB (5839) Subscriber Badge on Monday December 04 2017, @02:46PM (#605053) Journal

        A language that allows you to choose what kind of memory management your software will use,

        I must strongly disagree with that.

        I don't mind if the system allows you to select which GC algorithm to use. And if it provides lots of knobs and controls to tune it. (See Java runtime system.)

        But GC must be built into the underlying runtime for any king of application programming language. For Systems and Microcontroller programming, stick to C, C++, Rust, etc. Although microcontrollers already are capable or running Java, Python, Node.js and other GC languages / platforms.

        Why must GC be in the runtime platform?

        This is one of the hidden strengths of Java. There are C and C++ programs and libraries galore. A major problem is that they have so many different memory management disciplines which make them all incompatible. Or make it difficult for a program to introduce another library that requires yet one more different memory management discipline.

        In Java, there are libraries galore. An absolute embarrassment of riches. But they are all compatible. I don't care who creates what data structure. And nobody thinks about anyone being "responsible" to dispose of it. When it is no longer referenced, the GC will eat it.

        I would also point out that GC has come a long way since the 1970's. A modern JVM can have dozens or even hundreds of Gigabytes (not Megabytes) of memory and only 10 ms GC pauses. Multiple vendors offer various solutions. Even the stock OpenJDK GC is amazing. But see Azul Systems Zing runtime for Java. You can have hundreds of cpu cores and hundreds of gigabytes and only 10 ms max GC pauses.

        --
        People today are educated enough to repeat what they are taught but not to question what they are taught.
    • (Score: 2) by RamiK on Saturday December 02 2017, @12:06AM

      by RamiK (1813) on Saturday December 02 2017, @12:06AM (#604104)

      * has gc

      Swift counts references and has you release or hold memory to resolve circular references manually as well as handle any locks and the like unlike parallel languages. So, it doesn't really qualify as having a GC. I guess you can also look at these half-manual memory management aspects as features...

      Disregarding that, I guess, advantages wise, it has generics and OO that Go doesn't have; It's stable unlike Rust; And, it isn't as bat-shit crazy broken syntactically like Javascript... Oh, and you're forced to use it or obj-c for iOS development and the latter doesn't qualify as a modern language according to your bucket list.

      --
      compiling...
  • (Score: 2) by Gaaark on Friday December 01 2017, @10:19PM

    by Gaaark (41) on Friday December 01 2017, @10:19PM (#604072) Journal

    Any language that includes saying "He my babby-daddy"

    --
    --- Please remind me if I haven't been civil to you: I'm channeling MDC. ---Gaaark 2.0 ---