YAML™ is a readable text format for data structures. As you'll see below, YAML can handle many common data types and structures. And what YAML can't handle natively can be supported through flexible type families. For example, YAML for Ruby uses type families to support storage of regular expressions, ranges and object instances.
The Crossing borders series looks at how non-Java™ languages solve major problems and what those solutions mean to Java developers today. This article explores continuations, the technique behind frameworks like Smalltalk's Seaside. Continuation servers make it much easier to build Web a
The concept of symbols have been popular among the lisp community, yet not many people know about it mainly due to the general ignorance.
Then ruby came and made symbols be a commodity programming construct. People who were not aware of symbols now are.
And they are asking about it numerous times. There is not a week in the ruby mailing list that there isn't a question about symbols: what are they and what are they good for?
Inevitably, every Ruby nuby asks the question “What are symbols?”, and the standard answer is “A Symbol is an immutable string”. I have some issues with that answer.
With all the rage for reasons whatsoever about Ruby and its Symbols, people often start to compare Ruby symbols with Lisp symbols. Don’t do that, it’s just wrong.
Lots of people have been discussing symbols in Ruby, and seem have converged on the explanation that symbols should be used whenever you’re referring to a name (i.e. an identifier or keyword, essentially), even if you’re talking about a hypothetical name that doesn’t really exist in actual code yet.
Code Kata
Background
How do you get to be a great musician? It helps to know the theory, and to understand the mechanics of your instrument. It helps to have talent. But ultimately, greatness comes practicing; applying the theory over and over again, using feedback to get better every time.
In an article introducing Ruby on Rails' Active Record, Bruce Tate suggests that Java could enjoy some of the benefits of Rails by taking a wrapping rather than a mapping approach to persistence. I think this misses the point. What Rails really demonstrates is the benefit of code generation.
Broadly speaking, there are two ways to create a DSL. One is to invent a syntax from scratch, and build an interpreter or compiler. The other is to tailor an existing general-purpose language by adding or changing methods, operators, and default actions. This article explores using the latter method to build a DSL on top of Ruby.
Matz Presentation on why ruby sucks