What languages are there with a message-passing syntax similar to Smalltalk's? Objective-C is the only one I'm familiar with. Specifically, I was wondering if any other language implementations exist which allow for syntax in a form like: [anObject methodWithParam:aParam andParam:anotherParam]
, having messages that allow for named parameters as part of method definitions.
In general I find that this syntax can be conducive to more consistent method names that more clearly show the methods' intent, and that the price you pay in wordiness is generally worth it. I would love to know if there are any other languages that support this.
Ruby borrows OOP from Smalltalk, but otherwise is a very much different language. I'm going to argue that Smalltalk is still technically a better choice than Ruby. Ruby appeals to programmers because of its clean, simpler syntax. However, Smalltalk is the ultimate in clean, simple, and minimalist.
Smalltalk is a "pure" object-oriented programming language, meaning that, unlike C++ and Java, there is no difference between values which are objects and values which are primitive types.
It should feel familiar, because Smalltalk's implementation of the object-oriented (OO) paradigm is so excellent that it has influenced an entire generation of OO languages, such as Objective-C, Python, Ruby, CLOS, PHP 5, Perl 6, Erlang, Groovy, Scala, Dart, Swift, and so on.
Smalltalk do not have a syntax. Instead it has a simple, consistent format for sending messages. Java, like other languages of the C family, has a complex syntax. Environment. Most Smalltalk implementations provide a complete, standalone, live computing environment with image based persistence.
Here is a list of languages supporting keyword messages syntax similar to Smalltalk:
In addition to the other languages mentioned here, Fancy:
osna = City new: "Osnabrück" p = Person new: "Christopher" age: 23 city: osna p println berlin = City new: "Berlin" p go_to: berlin p println
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With