Thursday, October 8, 2020

Writing the correct object equality

 While working with scala, object equality is a very important feature that we get for free while in the other programming languages such as C# or Java is quite challenging to implement. In scala, there is the case class, which is just like a normal class but is used to represent data only, it just like POJO in Java or POCO in C#.

Today, I came across an interesting article written by:

Martin Odersky is the creator of the Scala language. As a professor at EPFL in Lausanne, Switzerland, he works on programming languages, more specifically languages for object-oriented and functional programming. His research thesis is that the two paradigms are two sides of the same coin, to be unified as much as possible. To prove this, he has experimented with a number of language designs, from Pizza to GJ to Functional Nets. He has also influenced the development of Java as a co-designer of Java generics and as the original author of the current javac reference compiler. Since 2001 he has concentrated on designing, implementing, and refining the Scala programming language.

Lex Spoon is a software engineer at Google, Inc. He worked on Scala for two years as a post-doc at EPFL. He has a Ph.D. in computer science from Georgia Tech, where he worked on static analysis of dynamic languages. In addition to Scala, he has worked on a wide variety of programming languages, ranging from the dynamic language Smalltalk to the scientific language X10. He and his wife currently live in Atlanta with two cats, a chihuahua, and a turtle.

Bill Venners is president of Artima, Inc., publisher of the Artima Developer website (www.artima.com). He is the author of the book, Inside the Java Virtual Machine, a programmer-oriented survey of the Java platform's architecture and internals. His popular columns in JavaWorld magazine covered Java internals, object-oriented design, and Jini. Active in the Jini Community since its inception, Bill led the Jini Community's ServiceUI project, whose ServiceUI API became the de facto standard way to associate user interfaces to Jini services. Bill is also the lead developer and designer of ScalaTest, an open-source testing tool for Scala and Java developers.

Enjoy the article below:

https://www.artima.com/lejava/articles/equality.html



Finally, C# 9 record, the equivalent of Scala's case class

While C# is a wonderful programming language, there is something that I would like to see to make our life programmer easier. If you are fam...