Re: Adding Node support in outfuncs.c and readfuncs.c

From: Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>
To: Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Adding Node support in outfuncs.c and readfuncs.c
Date: 2011-11-11 11:55:53
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr> writes:
> What about adding that into src/tools/editors/pgsrc.el?

Of course after having used it some more, I fixed a bug and added a
function to start from the readfunc node name rather than the enum node
number in the interactive calls.

Please find attached a newer version of the pgsrc.el file, in case it is
to get included. Also note that it's possible to just use those read
only commands:

M-x pgsrc:get-node-name RET 718 RET
Node 718 is T_DropStmt.

M-x pgsrc:get-node-number RET COLUMNDEF RET
Node COLUMNDEF is 917 in enum NodeTag.

Also, the code generated is not handling the more complex case, for
example I had to adapt of rewrite some nodes (the constraint reading is
not something easy to generate from a script). But even with such
limitations, I still find the tool helping a lot.

Dimitri Fontaine PostgreSQL : Expertise, Formation et Support

Attachment Content-Type Size
pgsrc.el application/emacs-lisp 13.5 KB

In response to


Browse pgsql-hackers by date

  From Date Subject
Next Message Dimitri Fontaine 2011-11-11 12:27:10 Re: Multiple Extensions
Previous Message Heikki Linnakangas 2011-11-11 09:29:30 Re: Allow substitute allocators for PGresult.