Conversation

RSpec is kind of a fascinating use of dynamic scoping+lazy evaluation, implemented by piggybacking on top of inheritance. Each `:let` definition is actually translated into a class member, and each new scope is a subclass of its parent scope.
1
Was kind of terrifying when I first encountered it and then learned how it worked, but is actually super handy in practice. You do need to be careful not to let it turn into a mess though. 😅
1