unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* function arguments
@ 2013-10-25  4:07 Rustom Mody
  2013-10-25  4:50 ` Michael Heerdegen
  0 siblings, 1 reply; 3+ messages in thread
From: Rustom Mody @ 2013-10-25  4:07 UTC (permalink / raw)
  To: emacs-devel

The function make-translation-table shows its help like so:

-----------------------
make-translation-table is a compiled Lisp function in `mule.el'.

(make-translation-table &rest ARGS)

Make a translation table from arguments.
<etc etc>
----------------


However Ive to call it like so

(defvar apl-translation-table
  (make-translation-table '((?a . ?α) (?b . ?β) (?c . ?γ) (?d . ?δ) (?e . ?ε))))

and not

(make-translation-table (?a . ?α) (?b . ?β) (?c . ?γ) (?d . ?δ) (?e . ?ε)))


Am I missing something basic??

Rusi
-- 
http://www.the-magus.in
http://blog.languager.org



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: function arguments
  2013-10-25  4:07 function arguments Rustom Mody
@ 2013-10-25  4:50 ` Michael Heerdegen
  2013-10-25  5:18   ` Rustom Mody
  0 siblings, 1 reply; 3+ messages in thread
From: Michael Heerdegen @ 2013-10-25  4:50 UTC (permalink / raw)
  To: emacs-devel

Rustom Mody <rustompmody@gmail.com> writes:

> The function make-translation-table shows its help like so:
>
> -----------------------
> make-translation-table is a compiled Lisp function in `mule.el'.
>
> (make-translation-table &rest ARGS)
>
> Make a translation table from arguments.
> <etc etc>
> ----------------
>
>
> However Ive to call it like so
>
> (defvar apl-translation-table
>   (make-translation-table '((?a . ?α) (?b . ?β) (?c . ?γ) (?d . ?δ)
> (?e . ?ε))))
>
> and not
>
> (make-translation-table (?a . ?α) (?b . ?β) (?c . ?γ) (?d . ?δ) (?e . ?ε)))
>
>
> Am I missing something basic??

From the doc:

,----------------------------------------------------------------------
| Each argument is a list of elements of the form (FROM . TO), where FROM
| is a character to be translated to TO.
`----------------------------------------------------------------------

Your first example is valid (with one such argument given), but not
your second (because your arguments are not _lists_ of elements of the
form (FROM . TO)).  So, the doc seems to be correct, but you must not
get confused by the list of lists of blah structure ;-)


Regards,

Michael. 




^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: function arguments
  2013-10-25  4:50 ` Michael Heerdegen
@ 2013-10-25  5:18   ` Rustom Mody
  0 siblings, 0 replies; 3+ messages in thread
From: Rustom Mody @ 2013-10-25  5:18 UTC (permalink / raw)
  To: Michael Heerdegen; +Cc: emacs-devel

On Fri, Oct 25, 2013 at 10:20 AM, Michael Heerdegen
<michael_heerdegen@web.de> wrote:
> From the doc:
>
> ,----------------------------------------------------------------------
> | Each argument is a list of elements of the form (FROM . TO), where FROM
> | is a character to be translated to TO.
> `----------------------------------------------------------------------
>
> Your first example is valid (with one such argument given), but not
> your second (because your arguments are not _lists_ of elements of the
> form (FROM . TO)).  So, the doc seems to be correct, but you must not
> get confused by the list of lists of blah structure ;-)

Ok now I see it (and the nested dolist's in the code).
A little more redundant docs would of course help the idiots like..
yours truly

Rusi

-- 
http://www.the-magus.in
http://blog.languager.org



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-10-25  5:18 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-25  4:07 function arguments Rustom Mody
2013-10-25  4:50 ` Michael Heerdegen
2013-10-25  5:18   ` Rustom Mody

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).