[BUG] in color (Color r: 1 g:0 b:0) * #(1 1 1) -> DNU

Frank Shearar Frank.Shearar at rnid.org.uk
Thu Feb 3 11:47:53 UTC 2005


stéphane ducasse <ducasse at iam.unibe.ch> wrote:
> 
> in the comment of Color we read that we can * a color by an 
> array to get
> 
> 	self assert: (Color r: 1 g:0 b:0) * #(1 1 1) = Color red
> 
> But  (Color r: 1 g:0 b:0) * #(1 1 1) raises an error

Hm yes; Color>>* has a method pattern (I can't recall the proper name?) of

* aNumber
	"Answer this color with its RGB multiplied by the given number. "
	"(Color brown * 2) display"

and dates from 1997/02/11 - it looks like the comment is just plain wrong?

I don't mind writing a fix, if someone tells me which solution to use: fix the comment, or fix the code (and of course write a test).

frank


*******************************************************************
This email and any files transmitted with it are confidential
and intended solely for the use of the individual or entity to
whom they are addressed. Any views or opinions expressed
are solely those of the author and do not necessarily represent
RNID policy.
If you are not the intended recipient you are advised that any
use, dissemination, forwarding, printing or copying of this
email is strictly prohibited.
If you have received this email in error please notify the RNID
Helpdesk by telephone on: +44 (0) 207 296 8282.
The Royal National Institute for Deaf People
Registered Office 19*23 Featherstone Street
London EC1Y 8SL No. 454169 (England)
Registered Charity No. 207720
********************************************************************




More information about the Squeak-dev mailing list