changeset 30501:2c2ed2dae36f

file-name-extension
author Dave Love <fx@gnu.org>
date Thu, 27 Jul 2000 13:13:23 +0000
parents 1d1ab0dfb528
children 0dca3aa6405a
files lispref/files.texi
diffstat 1 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lispref/files.texi	Thu Jul 27 13:12:14 2000 +0000
+++ b/lispref/files.texi	Thu Jul 27 13:13:23 2000 +0000
@@ -1526,6 +1526,14 @@
 @end defvar
 @end ignore
 
+@defun file-name-extension filename &optional period
+This function returns @var{filename}'s final ``extension,'' if any,
+after applying @code{file-name-sans-versions} to remove any
+version/backup part.  If @var{period} is non-nil, then the returned
+value includes the period that delimits the extension, and if
+@var{filename} has no extension, the value is @code{""}.
+@end defun
+
 @node Directory Names
 @comment  node-name,  next,  previous,  up
 @subsection Directory Names