From: Oleksandr Gavenko <gavenkoa@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: :name or 'name?
Date: Mon, 21 Jan 2013 21:36:51 +0200 [thread overview]
Message-ID: <87y5fmjpkc.fsf@gavenkoa.example.com> (raw)
In-Reply-To: 87ip6q4bor@ch.ristopher.com
On 2013-01-21, Christopher Schmidt wrote:
> Oleksandr Gavenko <gavenkoa@gmail.com> writes:
>> Is that usual use :name instead of 'name in elisp code (in places
>> where you need symbol)?
>
> (info "(elisp)Symbol Type")
> (info "(elisp)Quoting")
>
Seems that I understand and already know those topics...
My question is that usual instead of quoting symbol use "keyword symbol" which
you don't need to quote...
So you can write:
(put :mylib-error 'error-message "Unknown mylib error")
instead of:
(put 'mylib-error 'error-message "Unknown mylib error")
or:
(put (quote mylib-error) 'error-message "Unknown mylib error")
or
(put (make-symbol "mylib-error") 'error-message "Unknown mylib error")
So avoid quoting by special naming conventions...
--
Best regards!
next prev parent reply other threads:[~2013-01-21 19:36 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-21 18:26 :name or 'name? Oleksandr Gavenko
2013-01-21 18:45 ` Christopher Schmidt
2013-01-21 19:36 ` Oleksandr Gavenko [this message]
2013-01-21 21:07 ` Drew Adams
2013-01-21 18:53 ` Suvayu Ali
2013-01-21 19:29 ` Oleksandr Gavenko
[not found] <mailman.18029.1358793499.855.help-gnu-emacs@gnu.org>
2013-01-21 23:47 ` Pascal J. Bourguignon
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=87y5fmjpkc.fsf@gavenkoa.example.com \
--to=gavenkoa@gmail.com \
--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.
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).