Newsgroups: comp.lang.smalltalk
Path: cantaloupe.srv.cs.cmu.edu!rochester!udel!delmarva.com!newsfeed.internetmci.com!howland.reston.ans.net!torn!nott!cunews!dbuck
From: dbuck@superior.carleton.ca (Dave Buck)
Subject: Re: Confused
X-Nntp-Posting-Host: superior.carleton.ca
Message-ID: <DFyHBH.6sr@cunews.carleton.ca>
Sender: news@cunews.carleton.ca (News Administrator)
Organization: Carleton University, Ottawa, Canada
References: <223321Z04101995@anon.penet.fi>
Date: Thu, 5 Oct 1995 03:21:17 GMT
Lines: 27

In article <223321Z04101995@anon.penet.fi>,
The Unknown Ranger <an397723@anon.penet.fi> wrote:
>
>
>I'm confused.
>
>anArray := Array with: 10@20 with: 20@10.
>anArray := (Array new: 2) at: 1 put: 10@20; at: 2 put: 20@10.
>
>where is the 'new' message in the first example?
>

There is none.  The with:with: method is a class method, hence, you
don't need to create a new instance - the with:with: method will do
that for you.

Also, your second line won't work.  You need to add a ";yourself" at
the end of the line before the period.

David Buck
dbuck@ccs.carleton.ca

_________________________________
| David K. Buck                 |
| dbuck@ccs.carleton.ca         |
| The Object People             |
|_______________________________|
