bad characters in tutorial (was: Self Objects)
Jecel Assumpcao Jr
jecel at merlintec.com
Wed Nov 30 22:09:44 UTC 2005
> Thanks for your quick response Jecel. It was very helful altough I
> have to admit that I really don't understand everything you wrote.
> Maybe the fault are my poor english-skills or maybe it is the rather
> complex syntax of self that's that is confusing me. Here is my short
> interpration of what you've written:
> "define a object with the two objects x and y."
> (| x. y |
> x: 3.··y: 4. "set the object x to 3, set y to 4"
> x squared + y squared) "return (x squared) + (y squared) "
Correct, but note that this is a code fragment and it doesn't make sense
to have this except inside another object definition as part as some
> Could you please explain me why you have to send "--" to self ?
> Wouldn't this example without the "--" also work as expected and did i
> get this right: the method actually has no name ? How do you call the
> method ?
> The code for the sample was taken from the sun-website:
You are correct that this code fragment is not a complete method
definition. You would not expect to see that in a real program.
There is no "--". It seems that someone has messed up the HTML
formatting originally created by Steve Dekorte (as noted at the bottom
of each page) in the process of updating the look of the Sun site. If
you are able to use the Postscript version I would recommend that (the
slides and the texts are two separate files, unfortunately):
I imagine that the tar.gz version of the tutorial is the HTML pages with
Steve's formatting. That might be a better option for you. There used to
be a copy online at UCSB but it is now gone.
Besides the "--" I also see "<-" rendered very oddly (with a
plus-and-minus character I can't type here instead of the "-") and also
some "Ê" characters in the right side text. These little things will
make your study a lot more complicated than it would have to be.
Hmmm... looking at an old copy I have of the tutorial I see it has the
first two problems already, though instead of "--" I see "......". I am
sure that it didn't use to look like that so obviously browsers have
changed how they do things since Netscape 4.
More information about the Self-interest