OK, but I don't know how to make an issue, sorry. :(
Yes, Jos�, that is a bug and your solution is correct.
On 14 Jun 2013, at 11:44, Jos� Comesa�a <jose.comesana@gmail.com> wrote:
> I think I've found a bug in String class>>readFrom:. This sentence fails:
>
> z := String readFrom: 'Good morning' readStream.
>
> I think that the bug is on the first line, saying: ^ self class streamContents:. The 'class' message shouldn't be here, because 'self' itself refers to the String class.
>
> Present in Pharo 2.0 and 3.0.
>
> Thanks a lot.
That also means that this code path is not covered by any tests.
Could you make an issue and make a slice (adding a test) ?
Sven
--
Sven Van Caekenberghe
Proudly supporting Pharo
http://pharo.org
http://association.pharo.org
http://consortium.pharo.org