Arity of funs
Bjorn Gustavsson
bjorn@REDACTED
Wed Mar 15 11:11:31 CET 2000
There is no way to find out the arity of a fun.
There are, however, erlang:fun_info/1,2 BIFs that return some information
about a fun, but not the arity. (These BIFs are meant to be used for
debugging purposes, not for use in applications.)
/Bjorn
Tony Pedley <tonyp@REDACTED> writes:
>
> Content-type: text/plain ; charset = us-ascii
>
> Hi,
> Well I've searched the OTP book, trawled the erlang questions archive(very good by the way, however
> there should
> be an all button on the Available Subdirectories) and I still can't work out how to do it.
>
> How do you extract the arity of a Fun? e.g How do I do this
>
> F = fun(X,Y,Z) -> end,
>
> X = get_fun_arity(F).
>
> 3
>
> All the best
>
> Tony
>
> --
> ______________________________________________________________________
> Tony Pedley mailto:tonyp@REDACTED
> Ericsson Intracom Ltd. Intranet : http://intracom.ericsson.se
> 1 Bede Island Internet : http://www.ericsson.co.uk/datacom/index.htm
> Leicester memoID : ECOM.CBERAM
> England Tel : +44 (0)116 2 542 400
> LE2 7EU Fax : +44 (0)116 2 046 111
> ______________________________________________________________________
>
>
>
--
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