I have a very large program with a lot of dependencies (objects,
functions that are linked togheter) and there is one particular function
that I want to strace troughout the program. (i.e find out every call it
makes(including its dependencies)), anyone have a good tips here?
I have a very large program with a lot of dependencies (objects,
functions that are linked togheter) and there is one particular function
that I want to strace troughout the program. (i.e find out every call it
makes(including its dependencies)), anyone have a good tips here?
You can use set_trace_func to trace execution and build up a data
structure that reflects the call graph. However, you need to be aware
that this will only yield actual method calls and not provide
information about all places where this method can be invoked. This
is next to impossible in a dynamic language like Ruby.
Kind regards
robert
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.