[Newbies] About methods and parameters

2008-12-03 Thread Delyan Kalchev
I have several questions: 1. As I see parameter passing in Smalltalk is always call-by-reference, so within a method it is possible to do any destructive actions over the passed object. Is there a way to pass/accept a parameter as const so that it won't be changed in the method. 2. When we pass

Re: [Newbies] About methods and parameters

2008-12-03 Thread Lukas Renggli
1. As I see parameter passing in Smalltalk is always call-by-reference, so within a method it is possible to do any destructive actions over the passed object. Is there a way to pass/accept a parameter as const so that it won't be changed in the method. No, not out of the box. 2. When we

Re: [Newbies] About methods and parameters

2008-12-03 Thread Bert Freudenberg
On 03.12.2008, at 10:23, Delyan Kalchev wrote: I have several questions: Hi! Welcome to a truly object-oriented system, where you might be in for some surprises :) 1. As I see parameter passing in Smalltalk is always call-by-reference, so within a method it is possible to do any

Re: [Newbies] About methods and parameters

2008-12-03 Thread Delyan Kalchev
Hello Bert and Lukas. Thank you both for the helpful answers and thanks Bert for the warm welcome. About the first question: Actually I cannot think of a philosophical reason to limit the access to an object that the object itself permits. It seems natural with the encapsulation and now I feel

[Newbies] Smalltalk and coroutines

2008-12-03 Thread Delyan Kalchev
Hello! According to this: http://en.wikipedia.org/wiki/Coroutine#Implementations_for_Smalltalk and other sources coroutines can be implemented in Smalltalk, but I've not had the chance to find a way to do it. Can you please help me, if you know how this can be done? -- Delyan Kalchev

Re: [Newbies] Smalltalk and coroutines

2008-12-03 Thread Lukas Renggli
According to this: http://en.wikipedia.org/wiki/Coroutine#Implementations_for_Smalltalk and other sources coroutines can be implemented in Smalltalk, but I've not had the chance to find a way to do it. Can you please help me, if you know how this can be done? Have a look at the class

[Newbies] Transcript usage

2008-12-03 Thread Sophie (itsme213)
How do I programatically: - Find an existing Transcript window, or create a new one - View it (if it was previously docked or minimized) Thanks ___ Beginners mailing list Beginners@lists.squeakfoundation.org