Guest User

Untitled

a guest
Mar 13th, 2018
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.19 KB | None | 0 0
  1. class Object
  2. def returning obj
  3. yield obj
  4. obj
  5. end
  6. def tap
  7. returning(self) { yield self }
  8. end
  9. def tapp
  10. tap { puts "#{File.basename caller[4]}: #{self.inspect}" }
  11. end
  12. end
Add Comment
Please, Sign In to add comment