unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: jemarch@gnu.org
Cc: emacs-devel@gnu.org, jemarch@gnu.org
Subject: Re: newbie hacker question: how to add eval-to-texinfo?
Date: Fri, 30 Apr 2004 16:36:51 +0200	[thread overview]
Message-ID: <16530.25731.386271.206297@termi.eui.upm.es> (raw)
In-Reply-To: <jwvllk93bgd.fsf-monnier+emacs@gnu.org>


    > I want to add a function called 'eval-to-texi' to emacs (i already
    > signed papers for that).
    
    The name does not make it very clear to me what it does.  Could you explain?

Oh, sorry. 

(defun eval-to-texi (form &optional tostring)
  "Evaluates FORM, dumping a @lisp texinfo environment with the
action.

If TOSTRING is t, then the @lisp environment is returned into a string,
rather than being inserted into the buffer."

  ...)

Examples:

@lisp
(car '(a b c))
      @result{} a
@end lisp

@lisp
(car (a b c))
      @error{} Symbol's function definition is void: a
@end lisp


    
    > - I suppose texinfo.el is the right way to add it. ¿It is right?.
    
    Depends on the patch.  But it's a very minor issue.  Most patches are not
    applied as is but are first sent back for a few minor changes: just send
    the patch and we'll tell you what needs to be changed, if anything.
    
    > - All functions in texinfo.el start with a 'texinfo-' prefix. May i to
    >   set that prefix to 'eval-to-texi' naming it 'texinfo-eval-to-texi'?
    
    Again, depends on the patch.

Ok.
    
    > - May i to include an autoload for 'eval-to-texi'?
    
    I don't see why not.
    
    > - To make the patch in unidiff format, would be right to generate it
    >   using 'cvs diff texinfo.el' on a fresh emacs cvs checkout? Or from
    >   the root directory: 'cvs diff lisp/textmodes/texinfo.el'
    
    Same difference.
     
    > - May i to add an entry to lisp/ChangeLog and send a patch for it too?
    
    Better to send the ChangeLog entry separately, but in a patch is
    also acceptable.  In most cases the patch is wrong (because the date
    needs to be changed, the file has changed in the mean time, etc..)
    so it has to be inserted by hand anyway.
    
    
Ok. Many thanks.

-- 
José E. Marchesi 

<jemarch@gnu.org>         http://www.gnu.org     GNU No es Unix!
<jemarch@es.gnu.org>      http://es.gnu.org      GNU España

.---------------.
|    .-[]--.    |
|   [] `>[]-|   |  BEE GNU/Hurd            http://bee.es.gnu.org
|    `-.[]<-'   |               
._______________.    

  reply	other threads:[~2004-04-30 14:36 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-04-30 10:29 newbie hacker question: how to add eval-to-texinfo? jemarch
2004-05-03 13:12 ` Stefan Monnier
2004-04-30 14:36   ` jemarch [this message]
2004-05-03 22:21   ` Richard Stallman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=16530.25731.386271.206297@termi.eui.upm.es \
    --to=jemarch@gnu.org \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).