"OO has been a success because it's a useful way for *humans* to think
about problems. Type theorists didn't know that."
Which is not to say they have to be at odds with each other, but for
much of this history of popular programming, they have been largely
ignorant of each other. And that's arguably evident in that exchange.
Twenty years ago or so there was a lot made of the American
("mechanical", "pragmatic") compared to the European ("theoretical",
"pure") schools of programming. A quick search did not turn up
anything for me. Does anyone have a recollection or a reference?
-Patrick
"OO has been a success because it's a useful way for *humans* to think
about problems. Type theorists didn't know that."
Hi,
While this might consistent with the popular "definition" of OO and
even with Smalltalk 80, I'm disappointed that Cook, who is familiar
with the history of Smalltalk and who has met Alan Kay, perpetuates
the following misunderstanding about what Kay considered to be the
essence of OO:
Emails with Bob Harper #6
... "message passing" simply means "calling a function value
selected form a structure of functions"
Cheers,
Mike
... "message passing" simply means "calling a function valueEmails with Bob Harper #6
selected form a structure of functions"
Cheers,
Mike
First, that person's quote is far too brief for me to be sure what was intended. But generally it's indicative of people being effective with the common OOPLs, at least combined with a few good practices.
Second, I think I would have expressed something more like what you just wrote, David. Something that would be supported by nearly all of my posts to comp.object through the 90's and into the 2000's. ie. I am far from the opinion that "OOP lets you just model the real world "
I am simply of the "black-diamond run" school of OOP... ie. OOP's "edge" is merely the dynamic message send and method selector. Not much more than that.
-Patrick
Hi,
Cook equates passing a message with calling a function, even if
decoupled by use of a lookup. Yes, that's what ST-80 does, and, yes,
that's what Steele and Sussman arrived at in Scheme's eval/appy core
while exploring Hewitt's Actor Model. However, that's not what Kay
was after (nor is Scheme an Actor language). Kay was very clear about
his goal: FEXPRS (see below).
My concern is, precisely, that people think this an "irrelevant
implementation" detail, when it is, in fact, a profound shift.
Witness: 1) the difference between Erlang messaging and STM; and 2)
the difference between the lambda calculus and the vau calculus of
John Shutt's Kernel.
"I could hardly believe how beautiful and wonderful the idea of LISP
was. I say it this way because LISP had not only been around enough to
get some honest barnacles, but worse, there were deep flaws in its
logical foundations. By this, I mean that the pure language was
supposed to be based on functions, but its most important components
-- such as lambda expressions, quotes, and conds -- were not functions
at all, and instead were called special forms. Landin and others had
been able to get quotes and cons in terms of lambda by tricks that
were variously clever and useful, but the flaw remained in the jewel.
In the practical language things were better. There were not just
EXPRs (which evaluated their arguments), but FEXPRs (which did not).
My next questions was, why on Earth call it a functional language? Why
not just base everything on FEXPRs and force evaluation on the
receiving side when needed?
I could never get a good answer, but the question was very helpful
when it came time to invent Smalltalk, because this started a line of
thought that said 'take the hardest and most profound thing you need
to do, make it great, an then build every easier thing out of it.'"
Alan Kay,
The Early History of Smalltalk.,
in: Bergin, Jr., T.J., and R.G. Gibson.
History of Programming Languages - II,
ACM Press, New York NY, and
Addison-Wesley Publ. Co., Reading MA 1996,
pp. 511-578
Cheers,
Mike
Not my intention. And Kay was after more than that: As the second
paragraph suggests, eliminating special forms was a step toward his
goal. That they fell short of that goal in the name of efficiency on
hardware of the day is something he has acknowledged. Today, Erlang
and Kernel take it further.
> So in what way is OOP not pervasive higher order functional programming
> again and vice versa?
I didn't claim it wasn't. Nor did I state a preference for any
definition of OO (my preference would be to drop it in favour of
precise definitions of the various and different notions that lay
claim to it). Cook's papers and posts shed some welcome light on
procedural data abstraction in contrast to ADTs -- that they are
different, complementary, and useful -- despite the fact that they
have both been considered to be OO by different people at one time or
another.
No, what I said, in different words, was that I was disappointed that
Cook swept "messaging" under the rug, because understanding it as more
than function lookup and application is significant. It was the key
aspect of Smalltalk 72 that intrigued, separately, Carl Hewitt and Joe
Armstrong. Now, we see it emerging again in Kernel, and it's not just
higher order functional programming.
Cheers,
Mike
Not my intention. And Kay was after more than that: As the second
paragraph suggests, eliminating special forms was a step toward his
goal. That they fell short of that goal in the name of efficiency on
hardware of the day is something he has acknowledged. Today, Erlang
and Kernel take it further.
No, what I said, in different words, was that I was disappointed thatCook swept "messaging" under the rug, because understanding it as more
than function lookup and application is significant. It was the key
aspect of Smalltalk 72 that intrigued, separately, Carl Hewitt and Joe
Armstrong. Now, we see it emerging again in Kernel, and it's not just
higher order functional programming.
> So in what way is OOP not pervasive higher order functional programming
> again and vice versa?
Cook says something similar as well: "To me, saying 'OO is crap' is
equivalent to saying 'collections of functions are crap'."
(http://wcook.blogspot.com/2012/03/emails-with-bob-harper-6.html)
I speculate that such reductionist arguments are not persuasive to Bob
Harper. This is more a battle of different aesthetics than anything
else. FP concepts hang well together, but adding OO concepts seems
redundant. And vice versa. Perhaps "OO is crap" means, "giving just
plain collections of functions a high-falutin' name is crap".
Without reading the chapters he's referring to, that sounds like a
reductionist argument from the FP side. Which seems like more evidence
for my thesis.
Well, I didn't claim FEXPRs were practical... yet :-D
And, true, Erlang does provide HOF for _sequential_ programming, while
messaging is the control flow for concurrent programming.
[...]
> I only understand messaging as a form of late binding. Higher order function
> invocation is precisely that - a form of late binding. In fact static-y OO
> languages like JavaScript actually require you to wrap actions in functions
> in order to get the benefits of messaging!
No disagreement; I'm only emphasising that Kay, in his original
definition of OO, was aiming for a step beyond function invocation.
(By now, I hope that you get that I'm not trying to belabour
defintions. :-)
Cheers,
Mike
Yeesh. Yes, I think (hope) that David knows that I quite appreciate
the time and thoughtfulness he's investing in conversing with me.
Mike
Thanks; I'm struggling with it (http://arclanguage.org/item?id=15999)
On Sat, Mar 3, 2012 at 13:39, Paul deGrandis <paul.de...@gmail.com> wrote:
> I also really liked Bob's news release about changing intro CS courses
> at CMU. http://www.infoq.com/news/2011/03/oop-out-at-cmu
This post led me to Barbara Liskov's turing award lecture:
http://www.infoq.com/presentations/liskov-power-of-abstraction
Among other things, I realized that she was inventing ADTs around the
same time Alan Kay was building smalltalk and so inventing OO. That
was an interesting historical context to William Cook's essay.
Kernel is slow.
Of course a PL can be slow. Some part of its semantics may be defined
on an NP hard algorithm or some arbitrary resource intensive function.
OTOH I agree that most complaints are about particular
implementations, instead of PL definitions.
True. My recent, explorations on a Self-ish language is stuck on
parallel GC for huge heaps with thousands of concurrent mutators. The
fast sequential part was trivial compare to this one.
> And even if raw performance mattered, a lot of time programs are
> waiting for IO. This is why people write servers in e.g. Perl or
> MapReduce tasks in Sawzall. If your app is waiting for the OS kernel
> to finish IO requests for 80% of the time, making the language
> implementation faster can only give you a boost for the other 20%.
>
> See also Proebsting's Law.
> http://research.microsoft.com/en-us/um/people/toddpro/papers/law.htm
>
> * Focus on performance considered harmful (?)
>
> Finally, I should also say that a focus on raw performance to the
> detriment of cool language features is the antithesis of the Lisp
> spirit - which to me means having the cool, mind-bending features and
> *then* figuring out how to make them fast.
>
> In conclusion: Kernel's fexprs are much too new a topic to say
> anything about their performance. But they're so exciting, that even
> if they're slower than macros, I would find them still worth having in
> the language. Fexprs are fun expressions.
>
> Manuel
Daniel
Yes we don't yet know efficient implementation techniques for fexprs.
If performance is the overriding interest, perhaps the list should
have been named "ll-right-now" ;-)
Mike
On Monday, March 5, 2012 1:45:11 PM UTC+1, David Nolen wrote:Yes we don't yet know efficient implementation techniques for fexprs.David, why are you implying that fexprs are inefficient without providing any benchmarks or even scope for such a claim?
PicoLisp, a Lisp interpreter with fexprs, outperforms CLisp on some benchmarks, and is less than an order of magnitude slower than SBCL - one of the fastest dynamic language compilers.Manuel
On Mon, Mar 5, 2012 at 8:06 AM, Manuel Simoni <msi...@gmail.com> wrote:On Monday, March 5, 2012 1:45:11 PM UTC+1, David Nolen wrote:Yes we don't yet know efficient implementation techniques for fexprs.David, why are you implying that fexprs are inefficient without providing any benchmarks or even scope for such a claim?
I've found no literature on improving the performance of fexprs because as far as I can tell they don't exist
and plenty of literature going back to Smalltalk on why they're slow.
You're a Kernel enthusiast why don't *you* provide the benchmarks.
On Monday, March 5, 2012 2:38:25 PM UTC+1, David Nolen wrote:On Mon, Mar 5, 2012 at 8:06 AM, Manuel Simoni <msi...@gmail.com> wrote:
On Monday, March 5, 2012 1:45:11 PM UTC+1, David Nolen wrote:Yes we don't yet know efficient implementation techniques for fexprs.David, why are you implying that fexprs are inefficient without providing any benchmarks or even scope for such a claim?I've found no literature on improving the performance of fexprs because as far as I can tell they don't existAgain, you're implying that the performance of fexprs needs improvement, without evidence.and plenty of literature going back to Smalltalk on why they're slow.Links please.
You're a Kernel enthusiast why don't *you* provide the benchmarks.I provided a link to a benchmark of a Lisp with fexprs beating a traditional Lisp in the post you just replied to.Manuel