The hidden features of `caller`
25-Nov-2021 1616
I use Ruby’s caller feature a lot when I’m debugging and trying to figure out the stack trace of a particular code path. I used to think that it couldn’t do much beyond returning the full stack trace as an Array. But it’s got some tricks!Here’s the basic usage. Let’s say we’re debugging this code:.
The hidden features of `caller` #ruby #rubydeveloper #rubyonrails #hidden #features #`caller` https://rubyonrails.ba/link/the-hidden-features-of-caller