Finding function definition in package

I am trying to understand how a particular package is working and I don’t know how to find the definitions of some functions. I can Ctrl click some functions to go to the definitions but others I don’t know how to reach, usually functions used within defined functions in packages.

For example how can I reach the definitions of the functions handle_complex() or
make_pdesys_compatible() from the function excerpt shown?

function SciMLBase.symbolic_discretize(pdesys::PDESystem, discretization::AbstractDiscretization)
    t = get_time(discretization)
    pdesys, complexmap = handle_complex(pdesys)
    cardinalize_eqs!(pdesys)
    pdesys, replaced_vars = make_pdesys_compatible(pdesys)

You can use a macro: @edit func(a, b) with the argument types of interest, to see the source of the method for that signature. For your problem with the functions called by other functions, you’ll have to first import the packages where they’re defined.

1 Like

For relatively unique names like this one, a JuliaHub search is quick and easy:

image

4 Likes