Arc Forumnew | comments | leaders | submitlogin
1 point by akkartik 3741 days ago | link | parent

Yeah I've run into this already. In the screenshot for my original solution I highlighted a variable called test. Oops, poor name. Trouble is that this change now causes poor names in tightly localized contexts to bleed through the entire codebase :/

There's two directions to solve this:

a) Automatically detect variables with long lifetimes (measured in lines) to highlight. Perhaps this is a refinement of highlighting for

  *globals*
b) A way to attach metadata on a per-function or per-fragment basis. Highlight test in this function but not elsewhere, etc.


1 point by akkartik 3741 days ago | link

Heh, I just thought of a name for the plugin that turns the bug into a feature: synaesthesia.vim :)

-----

2 points by rocketnia 3741 days ago | link

There was some interesting discussion on that in the Reddit thread. :)

-----

2 points by akkartik 3741 days ago | link

You got me, that's where I stole the idea from.

-----