Closed omnium21 closed 10 years ago
That should be possible.
In your case, just removing the $
at the end of the pattern should work:
let names = matchlist( file, '\(.\{-1,}\):\%(\(\d\+\)\%(:\(\d*\):\?\)\?\)\?')
(the $
anchors the pattern to the end of the string)
While at it, I would like to have it support /path/to/file.py(27)
also - which is used with Python's ipdb for example.
Thanks! Yes, removing the $ works great
This should be working now.
When I grep for some source, I might get output like this:
Double clicking will give me the extra "extern" (or some other text) after the : where file_line expects a column number.
I've tried to decypher the matchlist expression, but I cannot work out how to make it pass when "garbage" is passed instead of a column number.
Also keep in mind, at least in C, some of the lines might also have things like # in them:
Is it possible to parse this and discard the garbage?