[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: closing string output ports?
From: |
Marius Vollmer |
Subject: |
Re: closing string output ports? |
Date: |
Wed, 08 Oct 2003 15:30:07 +0200 |
User-agent: |
Gnus/5.1002 (Gnus v5.10.2) Emacs/21.3 (gnu/linux) |
Nic Ferrier <address@hidden> writes:
> I don't really care about any of that, I just want to know what the
> correct procedure should be for a virtual port. Should the virtual
> port (close) the underlying port?
There is no simple answer. Guile itself does not dictate a specific
behavior. I'd say a good rule would be that the virtual port should
close its underlying port when it has openend it itself. That is,
when the function that creates a new instance of your virtual port
type opens an underlying port specifically for this new instance, then
the close function of the virtual port should close the underlying
port.
> Right now, if the underlying port is closed by the virtual port I get
> an exception.
>
> This seems wrong, it seems like virtual ports should close the
> underlying ports... but what do I know?
What kind of exception is that? (I guess the one about a cloed
stringport, right?) Can you show a complete example?
--
GPG: D5D4E405 - 2F9B BCCC 8527 692A 04E3 331E FAF8 226A D5D4 E405