문제

Dialyzer doesn't like calls to functions in the base module. Is there a dialyzer flag to skip this error or am I doing some wrong.

Here is a similar code:

-module(base).
-export(foo/1).

foo(X) -> X*2.


-module(derived).
-extends(base).
-export(xyz/0).

xyz() -> 
    ?MODULE:foo(5).

This piece of code works as I expect it to work. My only concern is the dialyzer warning;

---.erl:41: Call to missing or unexported function ---:---/3

Am I doing something wrong or is it dialyzer giving an unnecessary warning ?

도움이 되었습니까?

해결책

Dialyzer does not support extended modules, neither are there plans for such an extension. To the best of my knowledge, module inheritance is not even an official feature of Erlang.

Sorry...

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top