Stories
Slash Boxes
Comments

SoylentNews is people

posted by LaminatorX on Thursday November 06 2014, @12:40PM   Printer-friendly
from the Brainfuck++ dept.

A variety of debates ensue during discussions whether a given programming language is “the right tool for the job" and while some of these debates may appear to be tinged with an almost religious fervor, most people would agree that a programming language can impact not only the coding process, but also the properties of the resulting product. Now computer scientists at the University of California - Davis have published a study of the effect of programming languages on software quality using a very large data set from GitHub that analyzed 729 projects with 80 Million SLOC by 29,000 authors and 1.5 million commits in 17 languages. The large sample size allowed them to use a mixed-methods approach, combining multiple regression modeling with visualization and text analytics, to study the effect of language features such as static vs. dynamic typing, strong vs. weak typing on software quality. By triangulating findings from different methods, and controlling for confounding effects such as team size, project size, and project history, they report that language design does have a significant, but modest effect on software quality.

Most notably, it does appear that strong typing is modestly better than weak typing, and among functional languages, static typing is also somewhat better than dynamic typing. We also find that functional languages are somewhat better than procedural languages. It is worth noting that these modest effects arising from language design are overwhelm- ingly dominated by the process factors such as project size, team size, and commit size. However, we hasten to caution the reader that even these modest effects might quite possibly be due to other, intangible process factors, e.g., the preference of certain personality types for functional, static and strongly typed languages.

 
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 Random2 on Thursday November 06 2014, @06:49PM

    by Random2 (669) on Thursday November 06 2014, @06:49PM (#113604)

    The conclusion I saw there is that functional programming is awful for embedded systems, but Ada is pretty nice (and it is, believe you me).

    --
    If only I registered 3 users earlier....
    Starting Score:    1  point
    Karma-Bonus Modifier   +1  

    Total Score:   2  
  • (Score: 2) by HiThere on Thursday November 06 2014, @07:34PM

    by HiThere (866) Subscriber Badge on Thursday November 06 2014, @07:34PM (#113624) Journal

    OK, but there is no best language. There is a "best language for the job". Just because a language *can* do anything computable doesn't mean it's a good tool to use for a particular job.

    Ada is one of those languages that feels "almost right". For embedded systems it may be more right than any other language (though even there it might depend strongly on exactly what the embedded system needed to do). But they should have made the default string type unbounded, and they should have *strongly* encouraged garbage collection be implemented...as in if garbage collection was not implemented it should only have qualified as a subset of the full language. Most other things feel right, and the flaw with garbage collection is largely due to the fact that when it was being designed garbage collection was not fully developed. (Mind you, there's no reason you shouldn't be able to turn it off if you don't need it...or actively don't want it. But I don't consider storage pools to be an even approximately adequate replacement. But what you need depends on what you are doing.)

    --
    Javascript is what you use to allow unknown third parties to run software you have no idea about on your computer.
    • (Score: 2, Insightful) by novak on Thursday November 06 2014, @08:27PM

      by novak (4683) on Thursday November 06 2014, @08:27PM (#113642) Homepage

      Please don't get your garbage collection all over my embedded systems. Some of us do not consider its absence a flaw.

      --
      novak
      • (Score: 2) by TheRaven on Friday November 07 2014, @10:09AM

        by TheRaven (270) on Friday November 07 2014, @10:09AM (#113775) Journal
        It depends a lot on what you mean by 'embedded'. At the really low end, you have a degenerate case of garbage collection: all dynamically allocated memory is reclaimed, because there is no dynamically allocated memory. Embedded these days generally means 'needs to run for a really long time without maintenance or downtime' rather than 'has very low resource constraints'. In this case a full tracing GC can be acceptable depending on the latency requirements. More commonly, you'll use very coarse-grained GC and periodically restart components, reclaiming their entire heap.
        --
        sudo mod me up
      • (Score: 2) by HiThere on Friday November 07 2014, @07:59PM

        by HiThere (866) Subscriber Badge on Friday November 07 2014, @07:59PM (#113924) Journal

        Did you even read where I mentioned disabling it? Ada already has an optional appendix to allow garbage collection, it's just that nobody implements it, making it unusable.

        --
        Javascript is what you use to allow unknown third parties to run software you have no idea about on your computer.
        • (Score: 1) by novak on Friday November 07 2014, @10:34PM

          by novak (4683) on Friday November 07 2014, @10:34PM (#113945) Homepage

          Yes. I guess I read (part of) your comment as "I wish they would hobble ada without garbage collection," to which I wanted to say "I do not wish that."

          --
          novak