[erlang-questions] record with dynamic item name
Michael Richter
ttmrichter@REDACTED
Sun Aug 28 13:40:52 CEST 2011
On 28 August 2011 13:46, Roberto Ostinelli <roberto@REDACTED> wrote:
> is there any way to retrieve a record item whose identifier is in a
> variable? For instance:
>
>
You could probably quickly cook up a function or macros that does that
using record_info as detailed in
http://www.erlang.org/doc/reference_manual/records.html#id80708.
--
"Perhaps people don't believe this, but throughout all of the discussions of
entering China our focus has really been what's best for the Chinese people.
It's not been about our revenue or profit or whatnot."
--Sergey Brin, demonstrating the emptiness of the "don't be evil" mantra.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20110828/37a1a0a6/attachment.htm>
More information about the erlang-questions
mailing list