/binary problem in R10B
Bjorn Gustavsson
<>
Wed Nov 3 10:21:57 CET 2004
"Ulf Wiger (AL/EAB)" <> writes:
> Perhaps it would be a good idea to design test cases
> verifying all examples in the documentation? ;-)
>
Yes, it is a good idea. :)
As pointed out in another answer, the bug only occurs in the shell.
The compiler generates correct code.
There will be correction for the bug in a future release.
/Bjorn
> /Uffe
>
> > -----Original Message-----
> > From:
> > [mailto:]On Behalf Of Vance Shipley
> > Sent: den 2 november 2004 16:29
> > To:
> > Subject: /binary problem in R10B
> >
> >
> >
> > The following was taken verbatim from the programming examples
> > however it is giving me an error using R10B.
> >
> > Eshell V5.4 (abort with ^G)
> > 1> A = 1, B = 17, C = 42,
> > 1> Bin2 = <<A, B, C:16>>.
> > <<1,17,0,42>>
> > 2> <<D:16, E, F/binary>> = Bin2.
> > ** exited: {{illegal_pattern,{bin,1,
> > [{bin_element,
> > 1,
> > {var,1,'D'},
> > {integer,1,16},
> >
> > [integer,{unit,1},unsigned,big]},
> > {bin_element,
> > 1,
> > {var,1,'E'},
> > {integer,1,8},
> >
> > [integer,{unit,1},unsigned,big]},
> > {bin_element,
> > 1,
> > {var,1,'F'},
> > {atom,1,all},
> >
> > [binary,{unit,8},unsigned,big]}]}},
> > [{erl_eval,expr,3}]} **
> >
> > Checking with R9C-0 I see that it works as expected.
> >
> > Eshell V5.3 (abort with ^G)
> > 1> A = 1, B = 17, C = 42,
> > 1> Bin2 = <<A, B, C:16>>.
> > <<1,17,0,42>>
> > 2> <<D:16, E, F/binary>> = Bin2.
> > <<1,17,0,42>>
> >
> >
> > -Vance
> >
>
--
Björn Gustavsson, Erlang/OTP, Ericsson AB
More information about the erlang-questions
mailing list