Problem with dict:new()

Sean Hinde Sean.Hinde@REDACTED
Mon Nov 19 14:16:36 CET 2001


In the source (though undocumented) there appears to be a dict:size/1
function which would allow you to match an empty dict.

Apart from that I wouldn't have thought it was generally good form to rely
on the internal representation of an abstract data type..

Rgds,
Sean


> -----Original Message-----
> From: Nico Weling [mailto:nico.weling@REDACTED]
> Sent: 19 November 2001 12:37
> To: erlang-questions@REDACTED
> Subject: Problem with dict:new()
> 
> 
> Hi all,
> 
> after upgrading to Erlang R8B I've got a lot of badmatch 
> errors due to the 'new' dict module.
> 
> How is it possible to use the new release without changing my 
> own programms?
> 
> 
> Eshell V4.9.1  (abort with ^G)
> 1>  D0 = dict:new().
> []
> 
> 
> Eshell V5.1  (abort with ^G)
> 1> D0 = dict:new().
> {dict,0,
>       16,
>       16,
>       8,
>       80,
>       48,
>       {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],[]},
>       {{[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],[]}}}
> 
> 
> Thanks in advance,
> 
> regards Nico.
> 



NOTICE AND DISCLAIMER:
This email (including attachments) is confidential.  If you have received
this email in error please notify the sender immediately and delete this
email from your system without copying or disseminating it or placing any
reliance upon its contents.  We cannot accept liability for any breaches of
confidence arising through use of email.  Any opinions expressed in this
email (including attachments) are those of the author and do not necessarily
reflect our opinions.  We will not accept responsibility for any commitments
made by our employees outside the scope of our business.  We do not warrant
the accuracy or completeness of such information.





More information about the erlang-questions mailing list