[erlang-questions] Erlang/OTP R13A has been released

Kostis Sagonas kostis@REDACTED
Wed Mar 18 11:42:12 CET 2009

Thorsten Schuett wrote:
> Hi all,
> I have two comments on dialyzer in the beta version:
> - The opaqueness checks are great.

Thanks!  I also think so ;-)

> Already found a mix up with gb_sets and 
> gb_trees. However, the change also effects type-declarations:
> R13:
> -type(db()::gb_tree()).
> R12:
> -type(db()::gb_trees:gb_tree()).
> You are not allowed to specify the module of opaque types anymore.

This is not an accurate description of the issue.  What has happened is 
that R13 comes with some more built-in types (some opaque types are just 
a subset of these built-ins, but there are more of them e.g. timeout()).

The reader/linter (note: not dialyzer) prefers that these are not 
module-qualified -- otherwise you would have to write erlang:timeout() 
and gb_trees:gb_tree() all over the place.

But you are right that this has not been documented anywhere and it's a 
bit of a pain if you want to use different Erlang/OTP versions to 
compile the same source file.

> We had to 
> add an autoconf test because there seems to be no version which works with 
> both. This behavior doesn't seem to be documented in the ChangeLog.
> - To solve the problem above, our configure now adds a define for the 
> preprocessor ({d, types_are_builtin}) for R13. And we have to do the same for 
> dialyzer. According to the docs, dialyzer supports two versions for specifying 
> defines "-Dname (or -Dname=value)". Unfortunately only the latter seems to 
> work:

I was not aware that this got broken.  It will be fixed for R13B.

Thanks for your report!


More information about the erlang-questions mailing list