Erlang Development Environment

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Erlang Development Environment

Mats Cronqvist-2
> From: Sean Hinde <Sean.Hinde>
<...>

> 1. Function name completion on tab,
> 2. 'f1' to take you to the detailed doc for that function
> 3. or even just bring up the possible function headers with the names of the
> variables (kind of like you get when entering an equation in M$ Excel) -
> this could even work without access to any docs and for our own functions in
> our own modules in the current path.
> 4. Click to jump to the function implementation.
> 5. .. Take a look at Visual C++ or some of those things and steal (without
> breaking any software copyright laws of course ;) ) the best and most
> relevant ideas.

  not that i would ever try to pass myself off as an emacs expert, but i
believe points 2 & 4 are implemented in emacs/erlang.el

2. bind the 'f1' (or any other key) to erlang-man-function
     i have this in my .emacs;
(setq erlang-root-dir "~/OTP"))
(add-hook 'erlang-mode-hook 'my-erlang-mode-hook)
(defun my-erlang-mode-hook ()
(local-set-key "\C-x\?" 'erlang-man-function))

4. 'meta-.' should run the function erlang-find-tag (you could of course bind a
click to this function). it grabs the function name at point and moves point to
the function definition (possibly in a different module).
  you'll have to generate a tags file first, e.g. by running etags (in a
unix shell it's "etags *erl")

  mats




Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Erlang Development Environment

Ulf Wiger-4
On Wed, 7 Mar 2001, Mats Cronqvist wrote:

>2. bind the 'f1' (or any other key) to erlang-man-function
>     i have this in my .emacs;
>(setq erlang-root-dir "~/OTP"))
>(add-hook 'erlang-mode-hook 'my-erlang-mode-hook)
>(defun my-erlang-mode-hook ()
>(local-set-key "\C-x\?" 'erlang-man-function))
>
>4. 'meta-.' should run the function erlang-find-tag (you could of
>course bind a click to this function). it grabs the function name at
>point and moves point to the function definition (possibly in a
>different module).

>you'll have to generate a tags file first, e.g. by running etags (in a
>unix shell it's "etags *erl")


Just a wild idea: I've looked at the TAGS format, and it's simple
enough. It could be created as a side-effect as CCviewer builds
its source code and hypertext link cache.

If some elisp-savvy hacker could modify erlang.el so that it
fetches TAGS information via HTTP as needed, perhaps this
functionality could be made available without having to explicitly
build a TAGS file; and your TAGS information would be able to adapt
to what branch of the source code you're looking at.

Tell me if I'm smoking something funny.

/Uffe
--
Ulf Wiger                                    tfn: +46  8 719 81 95
Senior System Architect                      mob: +46 70 519 81 95
Strategic Product & System Management    ATM Multiservice Networks
Data Backbone & Optical Services Division      Ericsson Telecom AB



Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Erlang Development Environment

David Gould-2
On Wed, Mar 07, 2001 at 04:26:20PM +0100, Ulf Wiger wrote:

> On Wed, 7 Mar 2001, Mats Cronqvist wrote:
>
> >2. bind the 'f1' (or any other key) to erlang-man-function
> >     i have this in my .emacs;
> >(setq erlang-root-dir "~/OTP"))
> >(add-hook 'erlang-mode-hook 'my-erlang-mode-hook)
> >(defun my-erlang-mode-hook ()
> >(local-set-key "\C-x\?" 'erlang-man-function))
> >
> >4. 'meta-.' should run the function erlang-find-tag (you could of
> >course bind a click to this function). it grabs the function name at
> >point and moves point to the function definition (possibly in a
> >different module).
>
> >you'll have to generate a tags file first, e.g. by running etags (in a
> >unix shell it's "etags *erl")
>
>
> Just a wild idea: I've looked at the TAGS format, and it's simple
> enough. It could be created as a side-effect as CCviewer builds
> its source code and hypertext link cache.
>
> If some elisp-savvy hacker could modify erlang.el so that it
> fetches TAGS information via HTTP as needed, perhaps this
> functionality could be made available without having to explicitly
> build a TAGS file; and your TAGS information would be able to adapt
> to what branch of the source code you're looking at.
>
> Tell me if I'm smoking something funny.

No, this could work. Of course it would not be particularly useful being
so emacs specific. If regular ctags format tags could be made so that
vi could use it too, well, that would be useful! ;-)

More seriously, vim is pretty configurable (ok, too configurable), and
there is already a vim syntax highlighter for Erlang. Is there any
interest in a real vim erlang mode?

-dg

--
David Gould                davidg               510 536 1443
If simplicity worked, the world would be overrun with insects.


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Erlang Development Environment

Ulf Wiger-4
On Wed, 7 Mar 2001, David Gould wrote:

>> If some elisp-savvy hacker could modify erlang.el so that it
>> fetches TAGS information via HTTP as needed, perhaps this
>> functionality could be made available without having to explicitly
>> build a TAGS file; and your TAGS information would be able to adapt
>> to what branch of the source code you're looking at.
>>
>> Tell me if I'm smoking something funny.
>
>No, this could work. Of course it would not be particularly useful
>being so emacs specific. If regular ctags format tags could be made
>so that vi could use it too, well, that would be useful! ;-)

We had a couple of people who swore by vi and wouldn't program in
anything else. I don't know if any of them are still here...

I'd need help with the LISP hacking, though.

/Uffe
--
Ulf Wiger                                    tfn: +46  8 719 81 95
Senior System Architect                      mob: +46 70 519 81 95
Strategic Product & System Management    ATM Multiservice Networks
Data Backbone & Optical Services Division      Ericsson Telecom AB



Loading...