You'd need the abstract code available and then you can call dialyzer_utils:get_record_and_type_info/1 which returns a dict containing the type information. You can then pass this dict to various functions in the erl_types module to get back information about type specs.
If you don't want to rely on dialyzer at runtime, you'll need to copy-paste the code from dialyzer_utils AFAICT. Also the erl_types module is part of hipe.
On 27 March 2012 07:58, dmitry kolesnikov <dmkolesni...@gmail.com> wrote:
It may seem a bit silly, but you could wrap element and setelement in macros that relate to the record name with short get/set names. That would probably make it simpler for those that are addicted to get/set.