blocks are important for rubys concept of iterators.

Proc versus lambda

Proc

when a proc exits or returns it exits or returns from the enclosing context where invocation occurred. Can cause LocalJumpError

Lambda

lambda exits and returns are scoped to the context of the lambda * favor lambdas

Method Objects

instance_eval

target.instance_eval(&block) # invoke against instance of object
  target.class_eval(&block) # invoke against class object.

Binding

binding is a kernel method on Proc.

target.binding
  eval("number=4",binding)

rails is a ghetto

GRASP patterns - Applying UML and patterns

vim keyboard shortcuts CTRL+X+L # line completion CTRL+X+F # file completion CTRL+P f5 # refresh ctrlp cache

Start building rarrays

comments powered by Disqus