aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChong Yidong2007-04-04 15:57:04 +0000
committerChong Yidong2007-04-04 15:57:04 +0000
commit45948ea1b40e5ea0f1009c11845dd4ffd13860f6 (patch)
tree7cfabd1f75224d6ae4d308b072c4284b4032f088
parent322cbd38d4609c3b23fa6ade2acdac2c93ee298d (diff)
downloademacs-45948ea1b40e5ea0f1009c11845dd4ffd13860f6.tar.gz
emacs-45948ea1b40e5ea0f1009c11845dd4ffd13860f6.zip
(Case Tables): Document with-case-table and ascii-case-table.
-rw-r--r--lispref/strings.texi23
1 files changed, 23 insertions, 0 deletions
diff --git a/lispref/strings.texi b/lispref/strings.texi
index 0b2cd0e8685..788a7948b4f 100644
--- a/lispref/strings.texi
+++ b/lispref/strings.texi
@@ -1108,6 +1108,29 @@ This function returns the current buffer's case table.
1108This sets the current buffer's case table to @var{table}. 1108This sets the current buffer's case table to @var{table}.
1109@end defun 1109@end defun
1110 1110
1111@defmac with-case-table table body@dots{}
1112The @code{with-case-table} macro saves the current case table, makes
1113@var{table} the current case table, evaluates the @var{body} forms,
1114and finally restores the case table. The return value is the value of
1115the last form in @var{body}. The case table is restored even in case
1116of an abnormal exit via @code{throw} or error (@pxref{Nonlocal
1117Exits}).
1118@end defmac
1119
1120 Some language environments may modify the case conversions of ASCII
1121characters; for example, in the Turkish language environment, the
1122ASCII character ``I'' is downcased into a Turkish ``dotless i''. This
1123can interfere with code that requires ordinary ASCII case conversion,
1124such as implementations of ASCII-based network protocols. In that
1125case, use the @code{with-case-table} macro with the variable
1126@var{ascii-case-table}, which stores the unmodified case table for the
1127ASCII character set.
1128
1129@defvar ascii-case-table
1130The case table for the ASCII character set. This should not be
1131modified by any language environment settings.
1132@end defvar
1133
1111 The following three functions are convenient subroutines for packages 1134 The following three functions are convenient subroutines for packages
1112that define non-@acronym{ASCII} character sets. They modify the specified 1135that define non-@acronym{ASCII} character sets. They modify the specified
1113case table @var{case-table}; they also modify the standard syntax table. 1136case table @var{case-table}; they also modify the standard syntax table.