+2002-07-22 Kenichi Handa <handa@etl.go.jp>
+
+ * character.h (TRAILING_CODE_P): New macro.
+ (MAYBE_UNIFY_CHAR): Adjusted for the change of Funify_charset.
+ (string_char_with_unification): Fix prototype.
+ (Vscript_alist): Extern it.
+
+ * charset.h (Vcharset_ordered_list): Extern it.
+ (charset_ordered_list_tick): Extern it.
+ (EMACS_MULE_LEADING_CODE_PRIVATE_11,
+ EMACS_MULE_LEADING_CODE_PRIVATE_12,
+ EMACS_MULE_LEADING_CODE_PRIVATE_21,
+ EMACS_MULE_LEADING_CODE_PRIVATE_22): New macros
+ (Funify_charset): Adjusted for the change of Funify_charset.
+
+ * charset.c (charset_ordered_list_tick): New variable.
+ (Fdefine_charset_internal): Increment charset_ordered_list_tick.
+ (Funify_charset): New optional arg DEUNIFY. If it is non-nil,
+ deunify intead of unify a charset.
+ (string_xstring_p): Add `const' to local variables.
+ (find_charsets_in_text): Add `const' to arguemnts and local
+ variables.
+ (encode_char): Adjusted for the change of Funify_charset. Fix
+ detecting of invalid code.
+ (Fset_charset_priority): Increment charset_ordered_list_tick.
+
+ * coding.c (LEADING_CODE_PRIVATE_11, LEADING_CODE_PRIVATE_12,
+ LEADING_CODE_PRIVATE_21, LEADING_CODE_PRIVATE_22): Macros
+ deleted. Callers changes to use
+ EMACS_MULE_LEADING_CODE_PRIVATE_11, etc.
+ (decode_coding_ccl): Add `const' to local variables.
+ (consume_chars): Likewise.
+ (Ffind_coding_systems_region_internal): Likewise.
+ (Fcheck_coding_systems_region): Likewise.
+
+ * print.c (print_object): Use octal form for printing the
+ contents of a bool vector.
+
2002-07-18 Dave Love <fx@gnu.org>
* lread.c (Fload) <!load_dangerous_libraries>: Don't leak fd.
char emacs_mule_bytes[256];
-/* Leading-code followed by extended leading-code. */
-#define LEADING_CODE_PRIVATE_11 0x9A /* for private DIMENSION1 of 1-column */
-#define LEADING_CODE_PRIVATE_12 0x9B /* for private DIMENSION1 of 2-column */
-#define LEADING_CODE_PRIVATE_21 0x9C /* for private DIMENSION2 of 1-column */
-#define LEADING_CODE_PRIVATE_22 0x9D /* for private DIMENSION2 of 2-column */
-
-
int
emacs_mule_char (coding, src, nbytes, nchars)
struct coding_system *coding;
break;
case 3:
- if (c == LEADING_CODE_PRIVATE_11
- || c == LEADING_CODE_PRIVATE_12)
+ if (c == EMACS_MULE_LEADING_CODE_PRIVATE_11
+ || c == EMACS_MULE_LEADING_CODE_PRIVATE_12)
{
ONE_MORE_BYTE (c);
if (! (charset = emacs_mule_charset[c]))
decode_coding_ccl (coding)
struct coding_system *coding;
{
- unsigned char *src = coding->source + coding->consumed;
+ const unsigned char *src = coding->source + coding->consumed;
unsigned char *src_end = coding->source + coding->src_bytes;
int *charbuf = coding->charbuf;
int *charbuf_end = charbuf + coding->charbuf_size;
while (src < src_end)
{
- unsigned char *p = src;
+ const unsigned char *p = src;
int *source, *source_end;
int i = 0;
int *buf = coding->charbuf;
/* -1 is to compensate for CRLF. */
int *buf_end = coding->charbuf + coding->charbuf_size - 1;
- unsigned char *src = coding->source + coding->consumed;
+ const unsigned char *src = coding->source + coding->consumed;
int pos = coding->src_pos + coding->consumed_char;
int end_pos = coding->src_pos + coding->src_chars;
int multibytep = coding->src_multibyte;
{
Lisp_Object coding_attrs_list, safe_codings;
EMACS_INT start_byte, end_byte;
- unsigned char *p, *pbeg, *pend;
+ const unsigned char *p, *pbeg, *pend;
int c;
Lisp_Object tail, elt;
Lisp_Object list;
EMACS_INT start_byte, end_byte;
int pos;
- unsigned char *p, *pbeg, *pend;
+ const unsigned char *p, *pbeg, *pend;
int c;
Lisp_Object tail, elt;
{
emacs_mule_bytes[i] = 1;
}
- emacs_mule_bytes[LEADING_CODE_PRIVATE_11] = 3;
- emacs_mule_bytes[LEADING_CODE_PRIVATE_12] = 3;
- emacs_mule_bytes[LEADING_CODE_PRIVATE_21] = 4;
- emacs_mule_bytes[LEADING_CODE_PRIVATE_22] = 4;
+ emacs_mule_bytes[EMACS_MULE_LEADING_CODE_PRIVATE_11] = 3;
+ emacs_mule_bytes[EMACS_MULE_LEADING_CODE_PRIVATE_12] = 3;
+ emacs_mule_bytes[EMACS_MULE_LEADING_CODE_PRIVATE_21] = 4;
+ emacs_mule_bytes[EMACS_MULE_LEADING_CODE_PRIVATE_22] = 4;
}
#ifdef emacs