unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Use file-attributes accesors in existing code
@ 2016-07-28 14:53 Tino Calancha
  2016-07-28 17:23 ` Ted Zlatanov
  2016-07-28 17:35 ` Michael Albinus
  0 siblings, 2 replies; 3+ messages in thread
From: Tino Calancha @ 2016-07-28 14:53 UTC (permalink / raw)
  To: emacs-devel


Dear all,

as you know in Emacs 25.2 we have accessors for each of
the values returned by 'file-attributes'.  These accessors
prevent from some hardcoded numbers in the code, that is,
write:
(file-attribute-size attr)
instead of:
(nth 5 attr)

I guess everyone would like to use these accesors in future code.

Is it worth to review the existing code, in a case by
case basis, to see where the use of these accesors may result in a
more readable code?

I am glad to carry this task in case the maintainers think is
useful.

How about another accesor returning a list (inode device)?
How to call it?
Is is too long 'file-attribute-inode-device-numbers'?

Regards,
Tino



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

end of thread, other threads:[~2016-07-28 17:35 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-28 14:53 Use file-attributes accesors in existing code Tino Calancha
2016-07-28 17:23 ` Ted Zlatanov
2016-07-28 17:35 ` Michael Albinus

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