[erlang-questions] parameterized module returns badfun
YC
yinso.chen@REDACTED
Fri Oct 5 00:04:19 CEST 2007
Hi -
I tried out the parameterized module example in
http://www.erlang.org/pipermail/erlang-questions/2007-May/026867.html - I
can compile the example and even create the module instance, but evaluating
the functions returns badfun instead. I'm not sure where the issues are -
any pointers are appreciated. I'm using 5.5.5 on linux.
Erlang (BEAM) emulator version 5.5.5 [source] [async-threads:0] [hipe]
[kernel-poll:false]
Eshell V5.5.5 (abort with ^G)
1> c(pmod).
{ok,pmod}
2> M = pmod:new(3,4).
{pmod,3,4}
3> M:sum().
=ERROR REPORT==== 2-Oct-2007::10:04:26 ===
Error in process <0.30.0> with exit value:
{{badfun,{{pmod,3,4},sum}},[{shell,apply_fun,3},{shell,exprs,6},{shell,eval_loop,3}]}
** exited: {{badfun,{{pmod,3,4},sum}},
[{shell,apply_fun,3},{shell,exprs,6},{shell,eval_loop,3}]} **
4> M:new_Y(5).
=ERROR REPORT==== 2-Oct-2007::10:09:13 ===
Error in process <0.38.0> with exit value:
{{badfun,{{pmod,3,4},new_Y}},[{shell,apply_fun,3},{shell,exprs,6},{shell,eval_loop,3}]}
** exited: {{badfun,{{pmod,3,4},new_Y}},
[{shell,apply_fun,3},{shell,exprs,6},{shell,eval_loop,3}]} **
5>
Thanks,
yc
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20071004/40c599bf/attachment.htm>
More information about the erlang-questions
mailing list