[Newbies] indenting code

Norbert Hartl norbert at hartl.name
Wed Dec 13 14:31:46 UTC 2006


On Wed, 2006-12-13 at 09:09 -0500, Benjamin Schroeder wrote:
> Hi Norbert,
> 
> > Hi,
> >
> > I'm asking myself if there is any common sense about
> > how to indent the code in smalltalk/squeak.
> >
> > Most of the time I see something like
> >
> > statement do: [ :parameter |
> >    otherStatement selector: [
> > 	mostinnerstatement ] ].
> >
> > or
> >
> > statement do: [ :parameter | otherStatement ].
> 
> Kent Beck's "Smalltalk Best Practice Patterns" has a good section on  
> this. He presents ten simple patterns to drive the formatting of  
> Smalltalk code.
> 
Ok, that is nice. I have this book for several years now :) 
Thank you for pointing this out. As I have some 
experience in smalltalk now it is maybe a good time to
read it again.

thanks,

Norbert



More information about the Beginners mailing list