-
Notifications
You must be signed in to change notification settings - Fork 785
Fix #1999 : REFS aren't indexed if DEFS is empty #2624
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
Conversation
Pull Request Test Coverage Report for Build 3862
💛 - Coveralls |
protected int getSpecializedVersionNo() { | ||
return 20180208_00; // Edit comment above too! | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
* work around #1376: symbols search works like full text search. | ||
*/ | ||
OGKTextField ref = new OGKTextField(QueryBuilder.REFS, | ||
this.symbolTokenizer); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the new line break is not necessary here I think but that's not important
Looks ok. |
Thank you for the review, @tulinkry |
this looks OK, however I don't know if REFS have any value without DEFS in the file (yes, you should get existing symbols in index at least, if local file has none detected) |
so the question is whether this won't waste more cpu cycles than add value |
that said I am OK with merge |
Merged based on Slack #dev discussion. |
@tarzanek, OpenGrok REFS are of course also useful for linking to definitions in other files. While in e.g. Java or C it's difficult to come up with a useful, example source code file that has no DEFS from ctags, in Shell for example (and per the linked issue #1999), you can have a source code file that does useful things but which has no aliases, functions, or heredocs itself — and so has no results from ctags — but which includes another file using Without this change, the first example file's REFS would not be indexed, so the file would not be seen as a caller of the included file's functions. |
Hello,
Please consider for integration this patch to index REFS independently from DEFS and to bump the affected analyzers' specialized version numbers.
Thank you.