Lambda Lounge Launch!

6

Wow! Tonight was the first meeting of the St. Louis Lambda Lounge, a brand new user group focused on functional and dynamic languages. I was hoping maybe 15 or 20 folks would show up but we had over 30 hard-core language geeks all in one room. Appistry hosted the meeting and very kindly provided beverages and food. Many, many, many thanks for all their kindness. Due to the larger than expected turnout, we started in the kitchen and upgraded to the conference room and even that was a little tight, but we all were very friendly. :)

We did some initial introductions and there were people in the room either working or interested in Java, Ruby, Groovy, Javascript, Scala, C++, C#, Perl, Python, Smalltalk, Clojure, Python, OCaml, and probably some more I missed. Over and over we heard, “I do Java during the day, but at night I hack “. Some variations on that theme were Weiqi saying he used “lambda-less” languages during the day, Mike claiming he was just there for the Bud Light, and Matt saying that functional and dynamic languages were the “rebel” languages and Java was the Empire. Kyle Cordes made the insightful comment that 10 years ago all the language geeks were running away from these languages toward Java and now it’s just the reverse.

I had written up some features, topics, and examples of functional and dynamic languages and we kicked that around a bit. Here’s my summary. Please feel free to pick it apart yourself. :)

Functional

Characteristics

  • Functions are first-class objects
  • Data is immutable
  • Functions don’t have side effects, variables, loops?
  • Continuations

Topics

  • closures / lambdas
  • lazy vs eager evaluation
  • recursion
  • pattern matching
  • monads

Examples

  • Lisp
  • ML
  • Haskell
  • Clojure
  • Erlang
  • F#
  • Scala
  • Scheme

Dynamic

Characteristics

  • Do at runtime what other langs do at compile time: adding new code, modifying types, modifying instances
  • Dynamic typing (usually)
  • Duck typing
  • eval – generating and executing new code at runtime

Topics

  • metaprogramming
  • dynamic typing / duck typing
  • DSLs
  • categories / mixins / traits?

Examples

  • Smalltalk
  • Ruby
  • Lisp
  • Python
  • Groovy
  • Perl
  • Erlang
  • Scala?
  • Javascript

After that Matt Taylor did a great overview of categories and mixins in Groovy. Categories are defined effectively as static methods in a class, which are then made active with a “use” block in a limited code scope. If a method is not available when it’s being called, an attempt is made to match the method in the category as well.

I was struck by how similar this sounded to the extension methods proposal for Java 7. One difference is that in the Java proposal, the extra methods are declared by statically importing them whereas the activation is more obvious and explicit in Groovy due to the use { } block. I like the Groovy version a lot better. Matt also covered mixins, which can be defined for a class (affecting all prior and future instances of the class) or for particular instances of the class.

After a quick break and some last minute computer issues, Ryan Senior came up and did a walkthrough of some of the basics of Object Caml, which is a functional language from the ML family. Ryan covered some of the basics, static typing and type inference, parametric polymorphism, lazy eval, currying, and pattern matching. Lots of interesting stuff there – would love to see some of the same examples in other languages.

In talking about lazy evaluation, Ryan had a great example using log4j to explain why lazy evaluation is useful. Instead of having user code call isDebugEnabled() to avoid incurring the string concatenation for a message, lazy evaluation would allow you to call the debug method with a function that could lazily compute the string concatenation only if the string will actually be printed.

After the meeting, lots of people hung out talking about all sorts of stuff. I seem to recall some discussion on open source, the singularity, how the brain works, the future of concurrency, and more!

In all, it was a terrific night and I’m glad everyone seemed to enjoy the evening. Next month (Wed January 7th) we have Mario Aquino talking about either Android or Dashboard development in Objective-C and Mark Volkmann talking about Clojure. Should be another great evening of fascinating discussion, stop on by!

Comments

6 Responses to “Lambda Lounge Launch!”
  1. Mario Aquino says:

    Meeting was teh awesome! Thank you for doing all the work to organize it, Alex. I figure that I’ll have to make a decision pretty soon about whether I’ll do a talk on Dashboard development with JavaScript or iPhone development with Objective-C… Decisions, decisions…

  2. Eric Burke says:

    I think you meant Mario might be talking about “iPhone development in Objective-C” or else “Dashboard development”.

  3. Alex,

    Would your group be interested in getting a tech presentation on Smalltalk and Seaside? I think I could arrange to get to St. Louis sometime in the 1st half of 2009

  4. Great meeting last night! I really enjoyed the presentations and the format of the meeting.

    In regards to the previous comment, I would be interested in seeing a presentation on Smalltalk and Seaside.

  5. MartinJ says:

    Awesome, Alex! Would love to have something like that in my area! Hope you keep us posted about discussions, topics, etc.

    Cheers, Martin

  6. I have to agree to Martin – please keep up on posting about your Meetings.

    As Martin said, i wouldn’t dare to dream of a similar group of interested individuals here in my area, since there’s not even a Java User Group near by ;o)

    Greetings

    Mario