It amuses me greatly to see it point out how much more readable Smalltalk's method syntax is (i.e. "it skips the . operator") immediately before launching into an example of how great Smalltalk is that it doesn't have an if() construct and needs to define methods to dispatch on conditions.
Smalltalk is great (mostly for historic reasons these days) and definitely worth learning. But that bit is cognitive dissonance at its best.
Smalltalk is great (mostly for historic reasons these days)
In my experience coming to Pharo Smalltalk after a 15 year journey through C, C++, VB, PHP, ObjC, and Ruby (my second favorite lang), I can say that none of the reasons I find Smalltalk awesome are historical. This idea that one should "learn Smalltalk to bring those lessons with you to the language you 'really' plan on using" is a silly idea, often repeated.
Most importantly, Smalltalk is an environment, not a language...
The Smalltalk community is full of talented developers doing cutting edge research and serious commercial applications. We use Smalltalk, for example, because its live, open, dynamic environment makes it a joy to use and blows productivity through the roof. Having complete control over the IDE is a dream - as a small example, when I got tired of constantly navigating to my default code directory, I added a default setting to Pharo Smalltalk, in about 5 minutes, so I and every other user could benefit. This kind of enhancement is routine because it's so damn easy! Even in Ruby, it's a hassle to dig through a lib's source files and find the code to edit. In Smalltalk, one can drill down through the UI (from menus, windows, etc.) into the actual code, or set a breakpoint launching a debugger on the running system. What other OS (Squeak/Pharo can run on bare metal) lets you do that, all in the same language?!
Ruby is a language, not an environment. So why are you comparing Smalltalk environment to a language? (this applies largely to the original article as well - if you want to compare languages, compare languages; if you want to compare environments, compare environments).
There are Ruby environments that provide fairly deep introspection and live changes to a system, like Pry. It's just not the main way of doing things. For a reason: It's not the way most developers are used to working.
You are asking to force the question into an artificially created box that doesn't help us get to the truth. The Smalltalk experience is naturally - and more fairly - compared to Ruby as an experience.
They are both tools, and thus we're primarily concerned with their utility, not inherent value. One wants to know: how will these tools help me to achieve my goals. The answer is that the turtles-all-the-way-down experience of Smalltalk helps devs achieve those goals more quickly, easily, and joyfully.
p.s. Thanks for pointing out Pry! I didn't know about it and it looks really cool :) As it relates to this conversation though, a more-advanced repl is stone-age technology.
>> In Smalltalk, one can drill down through the UI (from menus, windows, etc.) into the actual code, or set a breakpoint launching a debugger on the running system. What other OS (Squeak/Pharo can run on bare metal) lets you do that, all in the same language?!
The same goes for looping and other control structures. This makes any DSL you write a first-class language construct equal to anything else in the language.
I know. What it is not is "clear", for any definition of the term understood by a working programmer who doesn't already know the language and grok the new abstraction.
The point was that this followed immediately an explanation of how much more readable (!) the OO syntax was because there was no separate operator (".") for method invocation. If the former is seriously a criteria for "being better than ruby", the Smalltalk condition trick is an abomination, and immensely inferior.
edit to avoid thread continuation: yet again the response boils down to "it's easy if you know it". So to be clear: 1.) I do know it; and 2.) Duh. But the previous point in the blog post seems to be predicated on the idea that learning the "." operator for method dispatch in ruby is somehow "hard" and that it's an advantage to Smalltalk that it has such a straightforward syntax. Those two opinions cannot logically be held in the same brain.
What it is not is "clear", for any definition of the term understood by a working programmer who doesn't already know the language and grok the new abstraction.
Browse menu, "implementors," select ifTrue:ifFalse:ifMaybe: and find yourself in a short method in under 3 seconds. (Most of that human menu-selection time.) Maybe another 5 seconds for someone familiar with the environment and its conventions to read and understand what they are seeing.
You have a different POV, because it's the POV of someone who doesn't yet know how to fend for yourself in a different environment. Once you learn a few tricks like this, it's very empowering. (And it's not an obscure trick. A seasoned Smalltalker lives by "senders" and "implementers")
Those two opinions cannot logically be held in the same brain.
I don't hold those two opinions. I don't think . is hard, and I don't think Smalltalk syntax is so much easier. What it is, combined with code blocks as literals, is a meta-syntax. I think it's more powerful in some ways.
I think the apparent contradiction is because you're subconsciously imposing your own ideas on the post, and those contradict what he's saying.
1. He didn't say Smalltalk's syntax was learnable — he said it was "readable". He'd probably agree that it's more learnable too, but his actual claim was more like "It's easier to mentally tokenize code that uses spaces to separate elements than code that uses dots." This is similar to how many Rubyists feel that using whitespace instead of parens can make code more readable.
2. He acknowledged that it will be awkward if you're already well-versed in languages that do things differently. But this is tautological. Attacking a programming language for being different from other programming languages is a lot silly.
3. It is true that Smalltalk's pervasive object-orientation will be unfamiliar for people whose experience is limited to Algolish languages, but continuing off 2, that isn't really a bad thing. Smalltalk's model is more consistent than Ruby's. There are basically two things in the whole language: message sends and variable definitions. Your objection here isn't that there's a new abstraction, but that there isn't anything new — it's objects all the way down. It's new to you because you know Ruby, but it's not really a new thing in the course of learning Smalltalk.
I find the lack of a . makes it more visually obvious what you are doing -- sending a message. Maybe something like foo <- doSomething would be more clear, but I always thought foo.doSomething sort of feels backwards, since you are sending a message to foo, not manipulating a property of it.
Smalltalk is great (mostly for historic reasons these days) and definitely worth learning. But that bit is cognitive dissonance at its best.