This page is no longer maintained — Please continue to the home page at www.scala-lang.org

Excellent talk! (And a couple of nits...)

3 replies
Meredith Gregory
Joined: 2008-12-17,
User offline. Last seen 42 years 45 weeks ago.
Dear Daniel,
i'm sorry i couldn't be there for your excellent talk on advanced Scala. The slides look great! However, there are a couple of nits i want to pick (because i think the discussion would be healthy for this community and i'm sure smarter people than i can provide some interesting input).
What is a type system?
The quote from Pierce regarding what a type system is
A type system is a tractable syntactic method for proving the absence of certain program behaviors by classifying phrases according to the kinds of values they compute. – Benjamin Pierce

misses a great deal of computation that can and is being usefully typed. First of all, not all computation produces values. What does high water mark algorithm, aka sliding window, compute? Nothing! It guarantees a property, namely exactly once, in order delivery. However, protocols like this can be typed at the behavioral level. Moreover, we need support from the type system because concurrent programming is orders of magnitude harder than sequential programming. (As an aside, Berry's theorem demonstrates that the lambda calculus -- the core computational model of languages like OCaml, F#, Scala and Haskell -- is fundamentally sequential!) Therefore we need all the help we can get as we step into this brave new world. Static analysis -- especially as applied in a dialogue between the programmer providing hints like minimal type declarations and the compiler suggesting where implementation might have strayed from the programmers declared intentions -- is one of the crucial forms of help of which we must avail ourselves.
On the usefulness of delimited continuations...
It's quite a mistake to think that shift/reset is the be-all and end-all of delimited continuations. Peyton-Jones, et al, have provided a more granular set of operators out of which many of the proposed control operator regimes (including shift/reset) are made. To see that this is really quite powerful, take a look a ZFS. The point is that with delimited continuations (appropriately packaged) you can get a whole variety of transactional semantics. This all derives from one simple abstraction built up from delimited continuations -- the zipper.
So, it's really important not to throw the baby out with the bath water. It may very well be that shift/reset doesn't live up to the promise of delimited continuations. However, there's a whole zoo of control regimes to explore. And one good toolkit for exploring them has been pretty well laid out.
Best wishes,
--greg

--
L.G. Meredith
Managing Partner
Biosimilarity LLC
1219 NW 83rd St
Seattle, WA 98117

+1 206.650.3740

http://biosimilarity.blogspot.com
Alex Cruise
Joined: 2008-12-17,
User offline. Last seen 2 years 26 weeks ago.
Re: Excellent talk! (And a couple of nits...)
On Wed, Jul 21, 2010 at 11:29 AM, Meredith Gregory <lgreg [dot] meredith [at] gmail [dot] com> wrote:
It's quite a mistake to think that shift/reset is the be-all and end-all of delimited continuations. Peyton-Jones, et al, have provided a more granular set of operators out of which many of the proposed control operator regimes (including shift/reset) are made. To see that this is really quite powerful, take a look a ZFS.

For anyone else who was momentarily confused, I'm pretty sure Greg meant http://okmij.org/ftp/Computation/Continuations.html#zipper-fs -- not the Sun filesystem. :)
-0xe1a
Meredith Gregory
Joined: 2008-12-17,
User offline. Last seen 42 years 45 weeks ago.
Re: Excellent talk! (And a couple of nits...)
Dear Alex,
Yes, thanks for the clarification!
Best wishes,
--greg

On Wed, Jul 21, 2010 at 11:42 AM, Alex Cruise <alex [at] cluonflux [dot] com> wrote:
On Wed, Jul 21, 2010 at 11:29 AM, Meredith Gregory <lgreg [dot] meredith [at] gmail [dot] com> wrote:
It's quite a mistake to think that shift/reset is the be-all and end-all of delimited continuations. Peyton-Jones, et al, have provided a more granular set of operators out of which many of the proposed control operator regimes (including shift/reset) are made. To see that this is really quite powerful, take a look a ZFS.

For anyone else who was momentarily confused, I'm pretty sure Greg meant http://okmij.org/ftp/Computation/Continuations.html#zipper-fs -- not the Sun filesystem. :)
-0xe1a



--
L.G. Meredith
Managing Partner
Biosimilarity LLC
1219 NW 83rd St
Seattle, WA 98117

+1 206.650.3740

http://biosimilarity.blogspot.com
gkossakowski
Joined: 2010-03-11,
User offline. Last seen 33 weeks 5 days ago.
Re: Excellent talk! (And a couple of nits...)
2010/7/21 Meredith Gregory <lgreg [dot] meredith [at] gmail [dot] com>
Dear Daniel,
i'm sorry i couldn't be there for your excellent talk on advanced Scala. The slides look great! However, there are a couple of nits i want to pick (because i think the discussion would be healthy for this community and i'm sure smarter people than i can provide some interesting input).

Just in case someone was wondering, this is mentioned talk:
  http://www.oscon.com/oscon2010/public/schedule/detail/15325  --
Grzegorz Kossakowski

Copyright © 2012 École Polytechnique Fédérale de Lausanne (EPFL), Lausanne, Switzerland