Accessors
Well VB.Net has what appears to be a way of defining accessors that actually allows one to use the accessor as if it where a variable (assignment and fetching) from outside the class. A class definition would look like this:
Public Class Container Protected mContents As Integer
Public Property Contents() As Integer Get Return mContents End Get
Set(ByVal Value As Integer) mContents = Value End Set
End Property
End Class
Of course the getter portion of this is really already part of Smalltalk because it is basically a unary accessor. So there no significant difference with the getter. Of course the first thing you will notice is that the Property (getter and setter combo) does not have the exact same name as the variable. Why? Because it can't; the names will collide and they're case-insensitive. So instead you are forced to place an extraneous character in front of the name. This is going to make the code harder to read and is just plain stupid. Many examples I have seen use lowercase m (I think for "me" or "my"). So basically let's make you remember more syntax and keywords so you can do this:
New Container().Contents = 5
Instead of:
New Container().Contents(5)
Since it really doesn't save anything over:
Public Class Container Protected mContents As Integer
Public Sub Contents(ByVal anInteger As Integer) mContents = anInteger End Sub
Public Function Contents() As Integer Return mContents End Function
End Class
I think I will stick with one thing to remember and one way to code (at least my code) then deal with special syntax. Furthermore, I will consider returning self from the setter in the future (The default in Smalltalk).