Suggestion: New table iterators

Bjorn Gustavsson bjorn@REDACTED
Thu Oct 19 15:24:45 CEST 2000


Robert Virding <rv@REDACTED> writes:

> Bjorn Gustavsson <bjorn@REDACTED> writes:
> >In the first version of the fold function, which we plan to release as
> >a patch for R7B, we will just encapsulate existing functionality in an
> >iterator. We will use safe_fixtable / fixtable, but we will not add any new
> >locking mechanims to ets or dets.
> 
> Question is whether it would not be better to let the caller handle 
> that and do fixtable themselves if they feel they need it.  What about 
> if the iterator fails?

I planned to catch any exception from the fun, unfix the table and rethrow
the exception.

I think that the whole point about the iterator is to hide unpleasant
details about ets/dets. Therefore, I my opinion, fixing and unfixing tables
should definitely be part of the iterator.

/Björn
-- 
Björn Gustavsson            Ericsson Utvecklings AB
bjorn@REDACTED      ÄT2/UAB/F/P
			    BOX 1505
+46 8 727 56 87 	    125 25 Älvsjö



More information about the erlang-questions mailing list