6 ms·
Use the `method` method to get a reference to the one you are concerned with, then call `source_location` on it.
by sethrin 1y ago
Use the `method` method to get a reference to the one you are concerned with, then call `source_location` on it.
- irjustin 1y agoThat's only during runtime. Simply reading code can be annoyingly difficult without hard references. Especially when the code is coming from a gem. Many times LSP's can't figure out where the code is coming from if it's a few layers deep. Then you're stuck with the time consuming method of running the code and doing something like what you're describing above just to read it.