[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Baby-Doe and friends

A few buffered up comments relating to this conversation...

 - I strongly prefer CALL-WITH-VALUES to WITH-VALUES because my
   background in other languages says that WITH-xxx forms should
   be macros or special forms which have special syntaxes, usually
   including an implicit-block body.

   make an argument of internal naming inconsistency for Scheme,
   but I can say that I would change the names of those two functions
   at the drop of a hat because I think they're badly misnamed.

 - I think I mentioned before, but I'll say it again because it's
   not getting much notice:
     (CALL-xxx continuation function)
   would make infinitely more sense to me than 
     (CALL-xxx function continuation)
   since it is the continuation which is being called with values.
   The fact that the function is a function is only an incidental
   artifact. [i.e., if we had a separate datatype THUNK such that
   (THUNK exp) meant like (LAMBDA () exp) except that THUNKs were
   not `called', they were `frobbed', I think it would still make
   sense to say 
     (CALL-xxx continuation thunk)
   but it would be totally icky to say
     (CALL-xxx thunk continuation)
   In this thought exercise, you'd want to say
     (FROB-xxx thunk continuation)
   I believe.]

   On the issue of internal consistency, CALL-WITH-CURRENT-CONTINUATION 
   takes only one arg, so I I can't construct an argument about whether
   that argument is the first or the last, but the parallel with FUNCALL
   in Lisp of anything named CALL-xxx is too strong and I just think it
   will cause immeasurable headache for any CALL-xxx to not be like FUNCALL.

 - I have a problem with the morpheme "values" in the multiple values
   terminology.  It's the reason I suggested YIELD earlier.

   Part of the issue is that every object passed along a data-flow
   path is, in effect, a value, so it seems contrived and potentially
   confusion-inducing to designate some of those as VALUES and leave
   the rest to merely be values.

   The way a language is spoken aloud among people who program in it
   is important to me.  The following interchange in Common Lisp would
   seem `natural' ...
     ``What does the function FOO return?''
     ``It returns (VALUES).''
     (pronounced the same as ``It returns values.'')
   One learns that the word "values" in spoken speech is shorthand for
   ``no values.''  It's really yucky. The reason I prefer (YIELD . values)
   is that it doesn't admit this bizaree verbal shorthand and properly
   encourages one to say either
      ``It returns no values''
   or ``It yields no values.''

 - As for naming BABY-DOE, I still like COMPOSE-CONTINUATION.


   If you really want a CALL-xxx thing, maybe I could get into
   Other possible adjectives include composed, interposed,
   encapsulated, augmented, composed, protected, ...

 - If a truncating version of BABY-DOE is created, I think some thought
   should be given to whether it should also pad with extra NIL's or some
   such. A key reason for using such a thing in the first place would
   presumably be to interface to Common Lisp, which has the other kind
   of multiple values, and provides both padding and truncation.

   However, since this kind of truncation can be added as a layered thing,
   I see no reason to include it in R4RS Scheme.