#include "buffer.h"
#include "opaque.h"
-Lisp_Object Qcase_tablep;
+Lisp_Object Qcase_table_p;
Lisp_Object Vascii_downcase_table, Vascii_upcase_table;
Lisp_Object Vascii_canon_table, Vascii_eqv_table;
#ifdef MULE
Lisp_Object Vmirror_ascii_downcase_table, Vmirror_ascii_upcase_table;
Lisp_Object Vmirror_ascii_canon_table, Vmirror_ascii_eqv_table;
#endif
+Lisp_Object Qtranslate_table;
static void compute_trt_inverse (Lisp_Object trt, Lisp_Object inverse);
REGISTER Lisp_Object tem;
while (tem = Fcase_table_p (obj), NILP (tem))
- obj = wrong_type_argument (Qcase_tablep, obj);
+ obj = wrong_type_argument (Qcase_table_p, obj);
return (obj);
}
set_case_table (Lisp_Object table, int standard)
{
Lisp_Object down, up, canon, eqv, tail = table;
- struct buffer *buf =
- standard ? XBUFFER(Vbuffer_defaults) : current_buffer;
+ struct buffer *buf = current_buffer;
check_case_table (table);
Vmirror_ascii_eqv_table = make_mirror_trt_table (eqv);
#endif
}
- buf->downcase_table = down;
- buf->upcase_table = up;
- buf->case_canon_table = canon;
- buf->case_eqv_table = eqv;
+ else
+ {
+ buf->downcase_table = down;
+ buf->upcase_table = up;
+ buf->case_canon_table = canon;
+ buf->case_eqv_table = eqv;
#ifdef MULE
- buf->mirror_downcase_table = make_mirror_trt_table (down);
- buf->mirror_upcase_table = make_mirror_trt_table (up);
- buf->mirror_case_canon_table = make_mirror_trt_table (canon);
- buf->mirror_case_eqv_table = make_mirror_trt_table (eqv);
+ buf->mirror_downcase_table = make_mirror_trt_table (down);
+ buf->mirror_upcase_table = make_mirror_trt_table (up);
+ buf->mirror_case_canon_table = make_mirror_trt_table (canon);
+ buf->mirror_case_eqv_table = make_mirror_trt_table (eqv);
#endif
-
+ }
return table;
}
\f
void
syms_of_casetab (void)
{
- defsymbol (&Qcase_tablep, "case-table-p");
+ defsymbol (&Qcase_table_p, "case-table-p");
+ defsymbol (&Qtranslate_table, "translate-table");
DEFSUBR (Fcase_table_p);
DEFSUBR (Fcurrent_case_table);
staticpro (&Vascii_canon_table);
staticpro (&Vascii_eqv_table);
-#ifdef MULE
- staticpro (&Vmirror_ascii_downcase_table);
- staticpro (&Vmirror_ascii_upcase_table);
- staticpro (&Vmirror_ascii_canon_table);
- staticpro (&Vmirror_ascii_eqv_table);
-#endif
-
tem = MAKE_TRT_TABLE ();
Vascii_downcase_table = tem;
Vascii_canon_table = tem;