[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Print column of search result
From: |
Jonas H. |
Subject: |
Re: Print column of search result |
Date: |
Thu, 20 Aug 2015 17:18:25 +0200 |
> On 20 Aug 2015, at 15:23, Shigio YAMAGUCHI <address@hidden> wrote:
>
> I don't know that meaning well.
> Could you please explain it by example?
int arg() { return 42; }
void func(int x) { }
int main() {
func(arg(), arg());
}
$ global -r -x arg
arg 6 multiple-users.c func(arg(), arg());
OK so this actually even worse for script usage than expected:
* The usage of `arg` is displayed only once
* The code context shown doesn’t start at the place/column `arg` is used but
somewhere else
What I’d like to see is an output like this:
$ machine-readable-global -r arg
6:8,13
6:15,20
These are the line, start and end column numbers.
Is there some easy way to extract this information directly from the DB?
Thanks
Jonas