logo       

Re: Imperative Object Destruction: msg#00043

lang.haskell.general

Subject: Re: Imperative Object Destruction

Hello!

On Mon, Nov 13, 2000 at 02:30:17AM -0800, Ashley Yakeley wrote:
> [...]

> Doesn't fulfill condition 2:

> 2. no read or write operations are performed on file-handles that have
> not yet been opened, or that have already been closed.

> ...since you can do

> stealHandle = withOpenFile "filename" ReadMode (\handle -> handle)
> stealHandle >>= read

And that yields an exception, as the handle is definitely closed.

Is there any *real* problem with this?

Kind regards,

Hannah.




<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise