unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* purpose of (provide 'hashtable-print-readable) in subr.el?
@ 2012-04-13 20:04 Michael Heerdegen
  2012-04-14  3:36 ` Leo
  2012-04-14  7:01 ` Andreas Schwab
  0 siblings, 2 replies; 4+ messages in thread
From: Michael Heerdegen @ 2012-04-13 20:04 UTC (permalink / raw)
  To: emacs-devel

Hi,

This looks odd to me: subr.el end with these lines:

| ;; The following statement ought to be in print.c, but `provide' can't
| ;; be used there.
| ;; http://lists.gnu.org/archive/html/emacs-devel/2009-08/msg00236.html
| (when (hash-table-p (car (read-from-string
| 			  (prin1-to-string (make-hash-table)))))
|   (provide 'hashtable-print-readable))

(Yes, I've read the mentioned thread in emacs-dev.)

What's the purpose of this `provide' call?  I've downloaded
emacs-23.4.tar.gz from ftp.gnu.org.  The only place where
hashtable-print-readable occurs in code (including C) is the above
occurrence in subr.el.  And I don't see any reason why third party code
should want to test for such a feature.  So, why is it provided at all?
Just curious...


Regards,

Michael.



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

* Re: purpose of (provide 'hashtable-print-readable) in subr.el?
  2012-04-13 20:04 purpose of (provide 'hashtable-print-readable) in subr.el? Michael Heerdegen
@ 2012-04-14  3:36 ` Leo
  2012-04-14  7:01 ` Andreas Schwab
  1 sibling, 0 replies; 4+ messages in thread
From: Leo @ 2012-04-14  3:36 UTC (permalink / raw)
  To: emacs-devel

On 2012-04-14 04:04 +0800, Michael Heerdegen wrote:
> (Yes, I've read the mentioned thread in emacs-dev.)
>
> What's the purpose of this `provide' call?  I've downloaded
> emacs-23.4.tar.gz from ftp.gnu.org.  The only place where
> hashtable-print-readable occurs in code (including C) is the above
> occurrence in subr.el.  And I don't see any reason why third party code
> should want to test for such a feature.  So, why is it provided at all?
> Just curious...

Should just add (provide 'hashtable-print-readable) to bindings.el.

Leo




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

* Re: purpose of (provide 'hashtable-print-readable) in subr.el?
  2012-04-13 20:04 purpose of (provide 'hashtable-print-readable) in subr.el? Michael Heerdegen
  2012-04-14  3:36 ` Leo
@ 2012-04-14  7:01 ` Andreas Schwab
  2012-04-15 17:29   ` Michael Heerdegen
  1 sibling, 1 reply; 4+ messages in thread
From: Andreas Schwab @ 2012-04-14  7:01 UTC (permalink / raw)
  To: Michael Heerdegen; +Cc: emacs-devel

Michael Heerdegen <michael_heerdegen@web.de> writes:

> Hi,
>
> This looks odd to me: subr.el end with these lines:
>
> | ;; The following statement ought to be in print.c, but `provide' can't
> | ;; be used there.
> | ;; http://lists.gnu.org/archive/html/emacs-devel/2009-08/msg00236.html
> | (when (hash-table-p (car (read-from-string
> | 			  (prin1-to-string (make-hash-table)))))
> |   (provide 'hashtable-print-readable))
>
> (Yes, I've read the mentioned thread in emacs-dev.)
>
> What's the purpose of this `provide' call?

http://comments.gmane.org/gmane.emacs.gnus.general/79821
https://raw.github.com/skeeto/emacs-java/master/java-docs.el

Andreas.

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."



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

* Re: purpose of (provide 'hashtable-print-readable) in subr.el?
  2012-04-14  7:01 ` Andreas Schwab
@ 2012-04-15 17:29   ` Michael Heerdegen
  0 siblings, 0 replies; 4+ messages in thread
From: Michael Heerdegen @ 2012-04-15 17:29 UTC (permalink / raw)
  To: emacs-devel

Hello,

> > |   (provide 'hashtable-print-readable))
> > What's the purpose of this `provide' call?
>
> http://comments.gmane.org/gmane.emacs.gnus.general/79821
> https://raw.github.com/skeeto/emacs-java/master/java-docs.el

Ok, so it indeed is used somewhere.  Thanks for the links.


Michael.



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

end of thread, other threads:[~2012-04-15 17:29 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-04-13 20:04 purpose of (provide 'hashtable-print-readable) in subr.el? Michael Heerdegen
2012-04-14  3:36 ` Leo
2012-04-14  7:01 ` Andreas Schwab
2012-04-15 17:29   ` Michael Heerdegen

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