Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disregard matches inside multi-line comments #57

Open
polaris6933 opened this issue Apr 11, 2020 · 2 comments
Open

Disregard matches inside multi-line comments #57

polaris6933 opened this issue Apr 11, 2020 · 2 comments

Comments

@polaris6933
Copy link

Say we have a function foo(). Somewhere in the codebase (e.g. some_file.cpp) a multi-line comment references it:

...
/**
 * This function wraps foo()
 */
Bar()
...

And when I try to find the definition for foo() I see some_file.cpp:42 * This function wraps foo() listed. Obviously this is undesired.

@pechorin
Copy link
Owner

Yes, and the problem is what multiline comments handling is smth what can take much longer execution time, so i think i will check and maybe i can implement optional support for this.

@polaris6933
Copy link
Author

polaris6933 commented Apr 14, 2020

I think a good solution (at least for me :D) would be setting a regex (preferably specific for a file type) which, if matched, causes the result to be dropped.

For example: I setup the regex ^[\t ]*\* for c++ files and any match (from my original comment that would be * This function wraps foo()) for a function definition which also matches the regex will be excluded from the list of definitions. It would be a good idea to keep them in the list of references, though.

This is purely from a user perspective, though. I have no idea how this would impact performance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants