[erlang-questions] Re: Erlang/OTP R14B01 has been released

Robert Virding <>
Mon Dec 13 11:24:43 CET 2010


In neither case are you running the compiler, both are handled by the interpreter, erl_eval, so they should behave in the same way. I would class this as a bug.

Robert

----- "Zvi" <> wrote:

> RE: OTP-8865  Code such as foo(A) -> <<A:0>> would crash the
> compiler.
> 
> It seems that compiler will totally ignore type of A in this case:
> 
> Eshell V5.8.2  (abort with ^G)
> 1> F = fun(A) -> <<A:0>> end.
> #Fun<erl_eval.6.13229925>
> 2>
> 2> F(0).
> <<>>
> 3> F(1).
> <<>>
> 4> F(10000).
> <<>>
> 5> F(1.4).
> <<>>
> 6> F(add).
> <<>>
> 7> F(kuku).
> <<>>
> 8>
> 8> F("adfd").
> <<>>
> 9>
> 9> F({1,2}).
> <<>>
> 10>
> 
> same for:
> 
> Eshell V5.8.2  (abort with ^G)
> 1>
> 1>
> 1> A = 0.
> 0
> 2> <<A:0>>.
> <<>>
> 3>
> 3> <<({1,2,3}):0>>.
> <<>>
> 4> <<([1,2,3]):0>>.
> <<>>
> 5> <<"hello":0>>.
> ** exception error: bad argument
> 6> <<("hello"):0>>.
> ** exception error: bad argument
> 7> <<1.6:0>>.
> <<>>
> 8> <<(fun()-> ok end):0>>.
> <<>>
> 9> <<(self()):0>>.
> <<>>
> 1
> 
> Zvi
> On Dec 8, 4:49 pm, Kenneth Lundin <> wrote:
> > Erlang/OTP R14B01 has been released.
> >
> > This release is mainly a stabilization of the R14B01 release (but
> there are
> > some new functionality as well).
> >
> > You can find the README file for the release at
> >
> > http://www.erlang.org/download/otp_src_R14B01.readme
> >
> > The source distribution and binary distribution for Windows can be
> > downloaded from
> >
> >
> http://www.erlang.org/download/otp_src_R14B01.tar.gzhttp://www.erlang.org/download/otp_win32_R14B01.exe
> >
> > The distribution can also be downloaded using the BitTorrent
> > protocol. Use the following torrent files to download the source
> > distribution and binary distribution for Windows:
> >
> >
> http://www.erlang.org/download/otp_src_R14B01.tar.gz.torrenthttp://www.erlang.org/download/otp_win32_R14B01.exe.torrent
> >
> > Note: To unpack the TAR archive you need a GNU TAR compatible
> program.
> >
> > For installation instructions please read the README file that is
> part
> > of the distribution.
> >
> > The on-line documentation can be found
> at:http://www.erlang.org/doc/
> > You can also download the complete HTML documentation or the Unix
> manual files
> >
> >
> http://www.erlang.org/download/otp_doc_html_R14B01.tar.gzhttp://www.erlang.org/download/otp_doc_man_R14B01.tar.gz
> >
> > We also want to thank those that sent us patches, suggestions and
> bug
> > reports,
> >
> > The Erlang/OTP Team
> > Kenneth Lundin, Erlang/OTP, Ericsson AB
> >
> > ________________________________________________________________
> > erlang-questions (at) erlang.org mailing list.
> > Seehttp://www.erlang.org/faq.html
> > To unsubscribe; mailto:
> 
> ________________________________________________________________
> erlang-questions (at) erlang.org mailing list.
> See http://www.erlang.org/faq.html
> To unsubscribe; mailto:


More information about the erlang-questions mailing list