Record selectors

Sean Hinde <>
Mon Jan 13 11:30:02 CET 2003


Hi,

All attempts to make records a bit safer are welcome - I have a couple of
comments on your suggestion:

> 	- one problem today is that records are effectively 
> module local (since they only exist as such at compile-time). 

I have grown very used to using the same record name (locally defined) in
lots of different modules - not least in the gen_server where just about
every one ever written surely has a #st() or #state{} record.

I think that such a scheme as you suggest would need to kep the ability to
have totally module private record definitions as well as your global
definitions.

One further thought - we use the xref tool as part of our build process.
This is invaluable in discovering calls to undefined modules in corner cases
(try calling error_logger:format("Aargh") ). If xref could be extended to
find inconsistencies in use of records across a set of modules maybe that
would be sufficient?

Sean



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.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20030113/ddad1e7b/attachment.html>


More information about the erlang-questions mailing list