tag:blogger.com,1999:blog-8814261378695867419.post2668849305110410580..comments2023-02-28T00:33:36.443-08:00Comments on Kent Tong's personal thoughts on information technology: Revealing the Scala magician's code: expressionAnonymoushttp://www.blogger.com/profile/07077712132467251275noreply@blogger.comBlogger4125tag:blogger.com,1999:blog-8814261378695867419.post-79043295864951804582011-10-26T14:16:12.000-07:002011-10-26T14:16:12.000-07:00Hi Kent,thanks for this explanation especially the...Hi Kent,<br>thanks for this explanation especially the step by step discussion and what the Scala compiler generates from the code.<br>Just one thing where I hesitated a bit while reading, was the term “top level” expression. <br>Level in which sense, had been a question in my mind. What qualifies an expression to be a top level expression?<br>Apart from that your post is worth to be bookmarked. :-)<br>Thanks for that.Lutz Hankewitznoreply@blogger.comtag:blogger.com,1999:blog-8814261378695867419.post-57857806539910239322011-05-02T10:11:26.000-07:002011-05-02T10:11:26.000-07:00Good explanations on errors I (a Scala newbie) am ...Good explanations on errors I (a Scala newbie) am likely to make... Not only you show what doesn't work, but you explain why, and how to fix that. Excellent. I particularly appreciate the function _ trick, it explains the error message which always seemed obscure.<br>Note: compiling your code to see what error messages I get on the "wrong" code, I also got deprecation warnings on "good" code (I always compile -deprecation -Xmigration flags as we often find obsolete code on the Net...).<br>warning: object Math in package scala is deprecated: use scala.math package instead<br>(no preview of comments =>code tag can be ignored...)<br>Applying the given advice removes the warning. It doesn't depreciate the value of your article, though.PhiLhohttp://Phi.Lho.free.frnoreply@blogger.comtag:blogger.com,1999:blog-8814261378695867419.post-89904287674238014662011-05-02T12:04:56.000-07:002011-05-02T12:04:56.000-07:00Hi PhiLho,I am glad that you like my article. Also...Hi PhiLho,<br>I am glad that you like my article. Also thanks to pointing out the warning! Just like you I also use the -deprecation option. I guess that you're using a more recent version of Scala than I. That's why I didn't see the warning :-)<br>BTW, you may want to use the Scala interpreter to experiment with the code. Just run "scala" and type the code line by line. It's a great way to get quick feedback.Kent Tonghttp://agileskills2.orgnoreply@blogger.comtag:blogger.com,1999:blog-8814261378695867419.post-51289385063661492252012-05-05T11:44:38.000-07:002012-05-05T11:44:38.000-07:00you explained the concept very good, keep posting ...you explained the concept very good, keep posting the good stuff . thanksitplanethttp://www.itplanet20.comnoreply@blogger.com