[arch-projects] New small project proposition
aaronmgriffin at gmail.com
Fri Apr 8 18:27:37 EDT 2005
So, I always screw myself up when using vim - I work professionally
using VS.NET, and there's alot of features that are real nice... most
can be worked into vim somehow (for instance, the way the HOME key
will toggle between column 0 and the first non-whitespace char). The
only one I miss is the context-sensitive completion of VS.NET...
Now I'm not talking about a little popup window with all the
accessability and things like that... I'm just looking for <C-N> and
<C-P> to complete within the context of the class/struct/union...
I've looked a bit into some of the plugins that vim has right now and
most of them suck. There are 3 though, that I cannot test yet... 2
are ruby-based, another perl-based... stupid win32 and their paths and
grrr... "cannot load library perl58.dll, aborting" I give up...
Anyway, what I'd like to do is create a little stand alone app that
could very easilly be integrated into vim, or anything else... seeing
as I like to think from the outside inward, here's the interface I
have in my head:
$ findsyms "XCreateSimpleW" /usr/include/X11/Xlib.h
$ findsyms --signature "signal5::conn" /usr/include/sigc++
void sigc::signal5::connect(const slot5&)
$ cat "my_file.c" | findsyms --signature "foo"
$ findsyms "java.lang.String" /path/to/java/jar
...list all public String members...
# from vim:
:!findsyms <cword> % "well, not exactly... I'd need to get the type of
a variable in the case of OO
simple: scan file + included files for matching definitions
basically, if finds matching patterns... not too hard... ideally, I'd
go really generic and create language files to describe what each
scope looks like, what an include file looks like, and how to
determine if something is visible at that scope of not
c++ would be rough when you get into templates (that sigc:: one would
fail unless it ignores templates), but c would be easy, as would
things like python... and maybe perl
I want to be able to use this in vim somehow as a dict file...
Now I may be way off with this, and there may be a simple way to do it
*within* vim... but I don't know...
Anyone have any opinions? Feel free to debase me or whatever... or
suggest a language that would do this easiest... just really thinking
More information about the arch-projects