Re: What's cooking in git.git (Feb 2017, #03; Fri, 10)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am 10.02.2017 um 23:24 schrieb Junio C Hamano:
* vn/xdiff-func-context (2017-01-15) 1 commit
 - xdiff -W: relax end-of-file function detection

 "git diff -W" has been taught to handle the case where a new
 function is added at the end of the file better.

 Will hold.
 Discussion on an follow-up change to go back from the line that
 matches the funcline to show comments before the function
 definition has not resulted in an actionable conclusion.

This one is a bug fix and can be merged already IMHO.


I have raw patches for showing comments before functions with -W, but they don't handle the case of a change being within such a comment. We'd want to show the trailing function which it is referring to in such a case, right?

And that's a bit tricky because it requires a more complicated model: Currently we distinguish only between function lines and the rest, while the new way would require identifying leading comment lines and probably also trailing function body lines in addition to that, and neither can be classified simply by looking at the line in question -- their type depends on that of neighboring lines.

René



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]