From: Drew Adams <drew.adams@oracle.com>
To: Jean Louis <bugs@gnu.support>, Help GNU Emacs <help-gnu-emacs@gnu.org>
Subject: RE: [External] : Why I cannot use this variable in macro call from function?
Date: Tue, 8 Jun 2021 13:41:44 +0000 [thread overview]
Message-ID: <SA2PR10MB44746263C7C9A8F27D4A355BF3379@SA2PR10MB4474.namprd10.prod.outlook.com> (raw)
In-Reply-To: <courier.0000000060BF6C6E.00005F44@stw1.rcdrun.com>
> (defmacro rcd-db-completing-table-history (table)
> (let ((variable
> (intern
> (concat "rcd-db-completing-table-history-"
> table))))
> (defun my-fun-123 ()
> (let ((var "new"))
> (rcd-db-completing-table-history var)))
>
> (my-fun-123)
>
> Debugger entered--Lisp error: (wrong-type-argument sequencep var)
> concat("rcd-db-completing-table-history-" var)
You are passing the symbol `var' as the arg
to your macro. Macros don't automatically
evaluate their args. What you are expecting
is presumably to pass the _value_ of symbol
`var', i.e., treat the symbol as a variable
and pass its value.
next prev parent reply other threads:[~2021-06-08 13:41 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-08 13:10 Why I cannot use this variable in macro call from function? Jean Louis
2021-06-08 13:41 ` Drew Adams [this message]
2021-06-08 14:47 ` [External] : " Jean Louis
2021-06-08 17:14 ` Jean Louis
2021-06-08 18:31 ` tomas
2021-06-08 18:37 ` Oops function? tomas
2021-06-08 19:27 ` [SOLVED with `eval']: Why I cannot use this variable in macro call from function? Jean Louis
2021-06-08 20:03 ` tomas
2021-06-08 20:06 ` Sorry again tomas
2021-06-08 20:12 ` [SOLVED with `eval']: Why I cannot use this variable in macro call from function? Jean Louis
2021-06-08 20:23 ` tomas
2021-06-08 20:38 ` Jean Louis
2021-06-08 20:47 ` Jean Louis
2021-06-09 6:09 ` tomas
2021-06-09 6:42 ` Jean Louis
2021-06-09 6:51 ` tomas
2021-06-09 7:03 ` Jean Louis
2021-06-09 7:39 ` tomas
2021-06-09 8:22 ` Jean Louis
2021-06-09 8:54 ` tomas
2021-06-09 10:56 ` Jean Louis
2021-06-09 11:33 ` tomas
2021-06-09 14:39 ` Jean Louis
2021-06-09 16:41 ` tomas
2021-06-10 2:10 ` Robert Thorpe
2021-06-10 6:56 ` Jean Louis
2021-06-11 6:33 ` Robert Thorpe
2021-06-11 7:03 ` Jean Louis
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=SA2PR10MB44746263C7C9A8F27D4A355BF3379@SA2PR10MB4474.namprd10.prod.outlook.com \
--to=drew.adams@oracle.com \
--cc=bugs@gnu.support \
--cc=help-gnu-emacs@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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.