Add feature: Go to definition#402
Conversation
0a4d76c to
eb6634c
Compare
|
Demo: Click on any function, variable or typedef and press F12 |
|
Also, I will add to SeerSourceBrowserWidget: |
|
Quite impressive! Let me go over your details. |
|
@epasveer What do you think about this MR? |
Apologies. I've been busy with the Holidays and New Years. I'll review this MR shortly. I hope you've had a good Holidays. |
My apologies. Christmas isn't typically celebrated in Vietnam, so I assumed you had forgotten about this PR 😂 |
It's all good. I'll be back at things next week 😃 |
|
Getting to this now. Sorry for the delay. |
|
I like adding this feature. My understanding is the "definition" can be a function or it can be a data type. Seer already has this ability via the "Functions" or "Types" tab in the "Source/Symbol" browser in the upper left corner. Your idea makes it much simpler, in a workflow way. Which is always good 😄 I'm a little concerned about introducing a mutex and introducing a work thread. It adds complexity. What I would have done here is:
This is basically what you have now in your idea. Below is another idea for the rest.
Like Note, the text you provide from the cursor position may result in multiple occurrences of symbols or types. Have to decide how to handle this. (Open all, open none, open first). The text may match a function and a type. Again, have to decide how to handle this. One thing to note, the I don't see the need of a mutex, unless I'm missing something. Also, I'm not clear on what you mean by "syncronizing". Anyway, give my idea some thought. Oh, in your code there was a table of keywords. What are they for? Thanks for you great ideas! |
|
Hi @epasveer |
|
Okay. I'll review it again when you're done. |
0d377f8 to
e5d47b0
Compare
e5d47b0 to
4737044
Compare
|
@epasveer |
Just so we're on the same page, solution for what? |
For distinguishing between variable, typedef, and function identifiers: |
I'm not surprised about this. With regular gdb, one has to decide to use one of these commands up front. ie: the user knows which one to use. I don't think we can read the user's mind to know which one to use. Perhaps, call each one, and if they result in multiple results, so be it. Open a source viewer for each one. I don't think we can do much else. |
|
Hi @epasveer , sorry for delay |
Sure. I'll review it again, just to be sure ("main" has other new changes) and will merge it if okay. |



This MR adds a “Go to Definition” feature, mimicking VS Code

In which, I will use 2 short cuts: "F12" and "Ctrl + left click"