On 7/15/07, Thomas Lord <[EMAIL PROTECTED]> wrote:

Ben Simon wrote:
>
> Now, what about a higher level case - something like I originally
> mentioned.  You go to open a DB connection, and it fails. Is the raise
> continuable or not?  I'm not trying to be difficult here, I'm honestly
> not sure which type it should be.

I have no idea.  The problem is to vague, as you have specified it.
It's meaningless (at least to me).


Good Point. How about this:

(define (open-db-connection host port username password)
 (let ((raw-tcp-conn (open-tcp-connection host port)))
   (if (not raw-tcp-conn)
       (raise "Unable to open db connection"))
   (authenticate-connection raw-tcp-conn username password)))

Assume that:
 open-tcp-connection opens up a TCP/IP connection, or returns #f if it
can't.
 authenticate-connection takes a raw TCP/IP connection and sends various
  packets across it to make sure it's a valid connection. The return of
  authenticate-connection is a valid connection.

So, the question is, should the above be raise or raise-continuable?
Obviously, this is toy code. But, I think the essence of the problem is
there.

-Ben

--
Ben Simon
My blog: http://benjisimon.blogspot.com
tenspotting.com - Top 10 Lists++
_______________________________________________
r6rs-discuss mailing list
[email protected]
http://lists.r6rs.org/cgi-bin/mailman/listinfo/r6rs-discuss

Reply via email to