solnic/virtus — pull request #74 by solnic (2012-02-24 16:12:40+00:00)
Title: Introduce new classes for handling default values

This is a small refactor of the way we handle default values. I added separate classes for handling different use-cases:

* value is callable
* value is clonable
* value is a method name (this is actually a new feature coming with this refactor)

It seems like it's better from OOP point of view. It eliminates the branching logic in #evaluate and make things slightly faster too.

I'm opening the PR early so we can discuss things here. Lemme know what you think.

/cc @senny