The Artima Developer Community
Sponsored Link

Weblogs Forum
A (Brief) History of Object-Functional Programming

59 replies on 4 pages. Most recent reply: Feb 15, 2010 12:02 PM by robert young

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 59 replies on 4 pages [ « | 1 2 3 4 ]
Vincent O'Sullivan

Posts: 724
Nickname: vincent
Registered: Nov, 2002

Re: A (Brief) History of Object-Functional Programming Posted: Dec 11, 2009 12:24 AM
Reply to this message Reply
Advertisement
Will any Scala program that compiles and runs against the JVM, compile and run identically against the CLR?

Kevin Wright

Posts: 38
Nickname: kevwright
Registered: Jul, 2009

Re: A (Brief) History of Object-Functional Programming Posted: Dec 11, 2009 12:51 AM
Reply to this message Reply
> Will any Scala program that compiles and runs against the
> JVM, compile and run identically against the CLR?

In theory, yes, so long as the program doesn't use any java libraries.

The scala devs are actively working on improved clr support for the 2.8 release.

Vincent O'Sullivan

Posts: 724
Nickname: vincent
Registered: Nov, 2002

Re: A (Brief) History of Object-Functional Programming Posted: Dec 11, 2009 12:54 AM
Reply to this message Reply
> I think running on the JVM is a safe bet for at least
> another decade.

That may be perfectly correct but it is, at best, only speculation. Java appears in extreme pain just getting another version out this - sorry next - year (maybe). How successful that version will be and what it will do for Java in ten years is anybody's guess.

David is right to point out that Scala appears to have a curious dependency on Oracle (the owner of Java) at its core whilst at the same time positioning itself as a replacement for Java. He is right to question its implications. Just assuming "the JVM is a safe bet for at least another decade" is not really a long term strategy for anybody interested in making long term or commercial commitments to switching to Scala.

Mark Thornton

Posts: 275
Nickname: mthornton
Registered: Oct, 2005

Re: A (Brief) History of Object-Functional Programming Posted: Dec 11, 2009 12:58 AM
Reply to this message Reply
> > Will any Scala program that compiles and runs against
> the
> > JVM, compile and run identically against the CLR?
>
> In theory, yes, so long as the program doesn't use any
> java libraries.

In practice I suspect that little production software will meet that constraint.

Kevin Wright

Posts: 38
Nickname: kevwright
Registered: Jul, 2009

Re: A (Brief) History of Object-Functional Programming Posted: Dec 11, 2009 6:29 AM
Reply to this message Reply
> Just assuming "the JVM is a safe bet for at
> least another decade" is not really a long term strategy
> for anybody interested in making long term or commercial
> commitments to switching to Scala.


There's no such thing as "the" JVM, wikipedia leasts 32 open source implementations:
http://en.wikipedia.org/wiki/List_of_Java_virtual_machines

Plus 22 proprietary implementations; so I agree totally that targeting the JVM is a safe bet for the next decade.

Added to this, that scala backend is swappable to use alternative bytecode generators (this is how it supports both the JVM and CLR). I have no doubt that if a new groundbreaking technology came along, then that could also be used.

James Watson

Posts: 2024
Nickname: watson
Registered: Sep, 2005

Re: A (Brief) History of Object-Functional Programming Posted: Dec 11, 2009 11:44 AM
Reply to this message Reply
> > Have you actually ever done any development in COBOL or
> > Java? If you think they are similar, you should
> disabuse
> > yourself of that notion.
>
> Both, though as little COBOL as possible. My point is not
> that they resemble each other in either semantics or
> syntax, but that they do implement the dumbData/smartCode
> paradigm in the enterprise. What was once done in COBOL
> is now done, with identical datastore thinking, in java.

I have to agree with you on this one (even though it pains me ;) JOBOL is very prevalent.

David Rozenberg

Posts: 15
Nickname: drozenbe
Registered: Nov, 2009

Re: A (Brief) History of Object-Functional Programming Posted: Dec 11, 2009 1:09 PM
Reply to this message Reply
This is related Kevin's last comment as to the number of JVM implementations. I do not know any serious commercial application that would rely on the product (JVM) that does not provide any vendor support. So, with the case with JVM there are probably 3-4 at most commercial JVM products that provide such support and will be used for the time being of it. With the CLR the problem is more serious because you never know whether it will be supported by Microsoft in the next generation of its software or will be abondoned as it happened already with multiple other products.

robert young

Posts: 361
Nickname: funbunny
Registered: Sep, 2003

Re: A (Brief) History of Object-Functional Programming Posted: Dec 11, 2009 1:28 PM
Reply to this message Reply
> Plus 22 proprietary implementations; so I agree totally
> that targeting the JVM is a safe bet for the next decade.
>
> Added to this, that scala backend is swappable to use
> alternative bytecode generators (this is how it supports
> both the JVM and CLR). I have no doubt that if a new
> groundbreaking technology came along, then that could also
> be used.

If Oracle/Sun never gets around to producing anything other than JDK7, what then?

Kevin Wright

Posts: 38
Nickname: kevwright
Registered: Jul, 2009

Re: A (Brief) History of Object-Functional Programming Posted: Dec 11, 2009 2:32 PM
Reply to this message Reply
> If Oracle/Sun never gets around to producing anything
> other than JDK7, what then?

Interesting thought here, but Hotspot and JRockit will soon both be under oracle ownership, it'll be very interesting to see if these two get unified.

Assuming Oracle really does stop all work here then the strongest proprietary offering will be from IBM, though you can fully expect people to start offering commercial support for both Apache Harmony and the OpenJDK.

David Rozenberg

Posts: 15
Nickname: drozenbe
Registered: Nov, 2009

Re: A (Brief) History of Object-Functional Programming Posted: Dec 12, 2009 5:23 AM
Reply to this message Reply
I think that the idea of merging HotSpot and JRockit can result in something quite bad. Those two JVMs were designed and implemented for different purposes ahd have different optimization techniques targeted for specific areas of applications. IBM JVM has its own pitfalls and some strange interpretations of the JVM spec. as well. I doubt that any unsupported by vendor JVM will make to the market. These will be used in colleges, schools and any other small 'pap-mom' shops until any of the products that come up from these small companies actually require commercial support and that may be a challenge.

Chuck Allison

Posts: 63
Nickname: cda
Registered: Feb, 2003

Re: A (Brief) History of Object-Functional Programming Posted: Dec 22, 2009 12:39 PM
Reply to this message Reply
It is fascinating to see how FP is surfacing in widespread languages, even C++ and C#. But as far as the "history" of FP goes, the ideas of closures, currying, referential transparency, lazy evaluation (via call-by-name, at least), etc. were all present in Church's Lambda Calculus, which was developed in the 1930s, and drew on work done by Shoenfinkel in the 1920s. Very brilliant stuff that not only predated computers (duh), but comprises a complete model of computation equal in power to Turing machines upon which computer architecture was based. Haskell is a relative late-comer, and owes its appeal to being a fairly faithful implementation of lambda calculus. So here we are, 90 years later, slowly catching up. To fracture a phrase, "Those who forget/ignore the past are doomed to relearn it" :-). (Shameless plug for a solid CS education!)

Achilleas Margaritis

Posts: 674
Nickname: achilleas
Registered: Feb, 2005

Re: A (Brief) History of Object-Functional Programming Posted: Dec 23, 2009 2:42 AM
Reply to this message Reply
> It is fascinating to see how FP is surfacing in widespread
> languages, even C++ and C#. But as far as the "history" of
> FP goes, the ideas of closures, currying, referential
> transparency, lazy evaluation (via call-by-name, at
> least), etc. were all present in Church's Lambda Calculus,
> which was developed in the 1930s, and drew on work done by
> Shoenfinkel in the 1920s. Very brilliant stuff that not
> only predated computers (duh), but comprises a complete
> model of computation equal in power to Turing machines
> upon which computer architecture was based. Haskell is a
> relative late-comer, and owes its appeal to being a fairly
> faithful implementation of lambda calculus. So here we
> are, 90 years later, slowly catching up. To fracture a
> phrase, "Those who forget/ignore the past are doomed to
> relearn it" :-). (Shameless plug for a solid CS education!)

Indeed. Now all that is required is a computation calculus that involves updating variables and we are done! :-)

David Rozenberg

Posts: 15
Nickname: drozenbe
Registered: Nov, 2009

Re: A (Brief) History of Object-Functional Programming Posted: Dec 23, 2009 1:31 PM
Reply to this message Reply
If that's the only thing you think the computers are for,then you may be right.

Jason Chambers

Posts: 1
Nickname: jchambers
Registered: Feb, 2010

Re: A (Brief) History of Object-Functional Programming Posted: Feb 14, 2010 8:15 AM
Reply to this message Reply
Wonderful write-up.

Alas, it was 17 years ago that I first tinkered with functional programming languages at Nottingham Trent University. The language was Gofer - a Haskell derivative.

At this point, I had only been exposed to C, C++, COBOL, Pascal and BASIC. I remember struggling at first with this new (to me) approach of programming. However, once I got past that I remember thinking, wow this is very clever stuff.

Once I finished university, I entered the work-force where I developed using C, C++ and most recently Java. A couple of years ago I heard rumblings of functional programming languages starting to enter the mainstream. I believed this to be due to the rise in multi-core CPUs and how functional languages seemed to be better positioned to take advantage of this than their mainstream distant cousins.

For me at least, it appears languages that are in essence an amalgamation of object oriented and functional programming seem to be the way forward. Scala I think provides a good implementation of such an approach.

robert young

Posts: 361
Nickname: funbunny
Registered: Sep, 2003

Re: A (Brief) History of Object-Functional Programming Posted: Feb 15, 2010 12:02 PM
Reply to this message Reply
> > If Oracle/Sun never gets around to producing anything
> > other than JDK7, what then?
>
> Interesting thought here, but Hotspot and JRockit will
> soon both be under oracle ownership, it'll be very
> interesting to see if these two get unified.
>
> Assuming Oracle really does stop all work here then the
> strongest proprietary offering will be from IBM, though
> you can fully expect people to start offering commercial
> support for both Apache Harmony and the OpenJDK.

In revisiting this long-dormant thread, I've realized I was unclear. Since Oracle/Sun are producing (as of the time I mentioned it, at least) only *an implementation* called JDK7, not a java 7 specification (which fact has been the source of much angst in the community), what then for java? Without a spec, only Oracle can produce a compliant java. We'd be left with the last spec'ed java from which to fork.

Flat View: This topic has 59 replies on 4 pages [ « | 1  2  3  4 ]
Topic: A Golf Ball to the Forehead Previous Topic   Next Topic Topic: Pattern matching in Scala for expressions

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use