aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJuanma Barranquero2011-03-29 00:41:01 +0200
committerJuanma Barranquero2011-03-29 00:41:01 +0200
commit461c2ab9a5a244ec9a1b253d07c1a8bdfbd8c573 (patch)
treea702b0c29ce32e78717be01c112889684a0453f6 /src
parentf6d6298639ae43539581c2079666d76a54f1557e (diff)
downloademacs-461c2ab9a5a244ec9a1b253d07c1a8bdfbd8c573.tar.gz
emacs-461c2ab9a5a244ec9a1b253d07c1a8bdfbd8c573.zip
src/*.c: Remove some additional unused parameters.
* lisp.h (multibyte_char_to_unibyte): * character.c (multibyte_char_to_unibyte): Remove parameter `rev_tbl', unused since 2002-03-01T01:16:34Z!handa@m17n.org and 2008-02-01T16:01:31Z!miles@gnu.org. * character.h (CHAR_TO_BYTE8): * cmds.c (internal_self_insert): * editfns.c (general_insert_function): * keymap.c (push_key_description): * search.c (Freplace_match): * xdisp.c (message_dolog, set_message_1): All callers changed. * coding.c (encode_designation_at_bol): Remove parameter `charbuf_end', unused since 2002-03-01T01:17:24Z!handa@m17n.org and 2008-02-01T16:01:31Z!miles@gnu.org. All callers changed.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog18
-rw-r--r--src/character.c7
-rw-r--r--src/character.h2
-rw-r--r--src/cmds.c2
-rw-r--r--src/coding.c7
-rw-r--r--src/editfns.c2
-rw-r--r--src/keymap.c2
-rw-r--r--src/lisp.h2
-rw-r--r--src/search.c7
-rw-r--r--src/xdisp.c4
10 files changed, 31 insertions, 22 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index be55ef369b3..1e77a6439e1 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,19 @@
12011-03-28 Juanma Barranquero <lekktu@gmail.com>
2
3 * coding.c (encode_designation_at_bol): Remove parameter `charbuf_end',
4 unused since 2002-03-01T01:17:24Z!handa@m17n.org and 2008-02-01T16:01:31Z!miles@gnu.org.
5 All callers changed.
6
7 * lisp.h (multibyte_char_to_unibyte):
8 * character.c (multibyte_char_to_unibyte): Remove parameter `rev_tbl',
9 unused since 2002-03-01T01:16:34Z!handa@m17n.org and 2008-02-01T16:01:31Z!miles@gnu.org.
10 * character.h (CHAR_TO_BYTE8):
11 * cmds.c (internal_self_insert):
12 * editfns.c (general_insert_function):
13 * keymap.c (push_key_description):
14 * search.c (Freplace_match):
15 * xdisp.c (message_dolog, set_message_1): All callers changed.
16
12011-03-28 Stefan Monnier <monnier@iro.umontreal.ca> 172011-03-28 Stefan Monnier <monnier@iro.umontreal.ca>
2 18
3 * keyboard.c (safe_run_hook_funcall): New function. 19 * keyboard.c (safe_run_hook_funcall): New function.
@@ -43,7 +59,7 @@
43 59
44 * nsterm.m (syms_of_nsterm): Use doc: for ns-auto-hide-menu-bar. 60 * nsterm.m (syms_of_nsterm): Use doc: for ns-auto-hide-menu-bar.
45 61
462011-03-27 Anders Lindgren <andlind@gmail.com> 622011-03-27 Anders Lindgren <andlind@gmail.com>
47 63
48 * nsterm.m (ns_menu_bar_is_hidden): New variable. 64 * nsterm.m (ns_menu_bar_is_hidden): New variable.
49 (ns_constrain_all_frames, ns_menu_bar_should_be_hidden) 65 (ns_constrain_all_frames, ns_menu_bar_should_be_hidden)
diff --git a/src/character.c b/src/character.c
index fdaf22f04f8..41c692e7483 100644
--- a/src/character.c
+++ b/src/character.c
@@ -232,13 +232,10 @@ translate_char (Lisp_Object table, int c)
232} 232}
233 233
234/* Convert ASCII or 8-bit character C to unibyte. If C is none of 234/* Convert ASCII or 8-bit character C to unibyte. If C is none of
235 them, return (C & 0xFF). 235 them, return (C & 0xFF). */
236
237 The argument REV_TBL is now ignored. It will be removed in the
238 future. */
239 236
240int 237int
241multibyte_char_to_unibyte (int c, Lisp_Object rev_tbl) 238multibyte_char_to_unibyte (int c)
242{ 239{
243 if (c < 0x80) 240 if (c < 0x80)
244 return c; 241 return c;
diff --git a/src/character.h b/src/character.h
index 91020cadedc..7a75ac186fa 100644
--- a/src/character.h
+++ b/src/character.h
@@ -69,7 +69,7 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
69#define CHAR_TO_BYTE8(c) \ 69#define CHAR_TO_BYTE8(c) \
70 (CHAR_BYTE8_P (c) \ 70 (CHAR_BYTE8_P (c) \
71 ? (c) - 0x3FFF00 \ 71 ? (c) - 0x3FFF00 \
72 : multibyte_char_to_unibyte (c, Qnil)) 72 : multibyte_char_to_unibyte (c))
73 73
74/* Return the raw 8-bit byte for character C, 74/* Return the raw 8-bit byte for character C,
75 or -1 if C doesn't correspond to a byte. */ 75 or -1 if C doesn't correspond to a byte. */
diff --git a/src/cmds.c b/src/cmds.c
index ebbb223c2db..1cf7ff24fec 100644
--- a/src/cmds.c
+++ b/src/cmds.c
@@ -352,7 +352,7 @@ internal_self_insert (int c, EMACS_INT n)
352 { 352 {
353 str[0] = (SINGLE_BYTE_CHAR_P (c) 353 str[0] = (SINGLE_BYTE_CHAR_P (c)
354 ? c 354 ? c
355 : multibyte_char_to_unibyte (c, Qnil)); 355 : multibyte_char_to_unibyte (c));
356 len = 1; 356 len = 1;
357 } 357 }
358 if (!NILP (overwrite) 358 if (!NILP (overwrite)
diff --git a/src/coding.c b/src/coding.c
index 0596d16bf46..fd812148a26 100644
--- a/src/coding.c
+++ b/src/coding.c
@@ -853,8 +853,7 @@ static unsigned char *alloc_destination (struct coding_system *,
853 EMACS_INT, unsigned char *); 853 EMACS_INT, unsigned char *);
854static void setup_iso_safe_charsets (Lisp_Object); 854static void setup_iso_safe_charsets (Lisp_Object);
855static unsigned char *encode_designation_at_bol (struct coding_system *, 855static unsigned char *encode_designation_at_bol (struct coding_system *,
856 int *, int *, 856 int *, unsigned char *);
857 unsigned char *);
858static int detect_eol (const unsigned char *, 857static int detect_eol (const unsigned char *,
859 EMACS_INT, enum coding_category); 858 EMACS_INT, enum coding_category);
860static Lisp_Object adjust_coding_eol_type (struct coding_system *, int); 859static Lisp_Object adjust_coding_eol_type (struct coding_system *, int);
@@ -4299,7 +4298,7 @@ encode_invocation_designation (struct charset *charset,
4299 4298
4300static unsigned char * 4299static unsigned char *
4301encode_designation_at_bol (struct coding_system *coding, int *charbuf, 4300encode_designation_at_bol (struct coding_system *coding, int *charbuf,
4302 int *charbuf_end, unsigned char *dst) 4301 unsigned char *dst)
4303{ 4302{
4304 struct charset *charset; 4303 struct charset *charset;
4305 /* Table of charsets to be designated to each graphic register. */ 4304 /* Table of charsets to be designated to each graphic register. */
@@ -4390,7 +4389,7 @@ encode_coding_iso_2022 (struct coding_system *coding)
4390 unsigned char *dst_prev = dst; 4389 unsigned char *dst_prev = dst;
4391 4390
4392 /* We have to produce designation sequences if any now. */ 4391 /* We have to produce designation sequences if any now. */
4393 dst = encode_designation_at_bol (coding, charbuf, charbuf_end, dst); 4392 dst = encode_designation_at_bol (coding, charbuf, dst);
4394 bol_designation = 0; 4393 bol_designation = 0;
4395 /* We are sure that designation sequences are all ASCII bytes. */ 4394 /* We are sure that designation sequences are all ASCII bytes. */
4396 produced_chars += dst - dst_prev; 4395 produced_chars += dst - dst_prev;
diff --git a/src/editfns.c b/src/editfns.c
index 009e1d34bde..b04414e1ae6 100644
--- a/src/editfns.c
+++ b/src/editfns.c
@@ -2226,7 +2226,7 @@ general_insert_function (void (*insert_func)
2226 { 2226 {
2227 str[0] = (ASCII_CHAR_P (XINT (val)) 2227 str[0] = (ASCII_CHAR_P (XINT (val))
2228 ? XINT (val) 2228 ? XINT (val)
2229 : multibyte_char_to_unibyte (XINT (val), Qnil)); 2229 : multibyte_char_to_unibyte (XINT (val)));
2230 len = 1; 2230 len = 1;
2231 } 2231 }
2232 (*insert_func) ((char *) str, len); 2232 (*insert_func) ((char *) str, len);
diff --git a/src/keymap.c b/src/keymap.c
index 440df06ba4e..10000b935aa 100644
--- a/src/keymap.c
+++ b/src/keymap.c
@@ -2387,7 +2387,7 @@ push_key_description (register unsigned int c, register char *p, int force_multi
2387 /* Now we are sure that C is a valid character code. */ 2387 /* Now we are sure that C is a valid character code. */
2388 if (NILP (BVAR (current_buffer, enable_multibyte_characters)) 2388 if (NILP (BVAR (current_buffer, enable_multibyte_characters))
2389 && ! force_multibyte) 2389 && ! force_multibyte)
2390 *p++ = multibyte_char_to_unibyte (c, Qnil); 2390 *p++ = multibyte_char_to_unibyte (c);
2391 else 2391 else
2392 p += CHAR_STRING (c, (unsigned char *) p); 2392 p += CHAR_STRING (c, (unsigned char *) p);
2393 } 2393 }
diff --git a/src/lisp.h b/src/lisp.h
index 1e255df1ecc..a3c4d48b49c 100644
--- a/src/lisp.h
+++ b/src/lisp.h
@@ -2403,7 +2403,7 @@ EXFUN (Fchar_width, 1);
2403EXFUN (Fstring, MANY); 2403EXFUN (Fstring, MANY);
2404extern EMACS_INT chars_in_text (const unsigned char *, EMACS_INT); 2404extern EMACS_INT chars_in_text (const unsigned char *, EMACS_INT);
2405extern EMACS_INT multibyte_chars_in_text (const unsigned char *, EMACS_INT); 2405extern EMACS_INT multibyte_chars_in_text (const unsigned char *, EMACS_INT);
2406extern int multibyte_char_to_unibyte (int, Lisp_Object); 2406extern int multibyte_char_to_unibyte (int);
2407extern int multibyte_char_to_unibyte_safe (int); 2407extern int multibyte_char_to_unibyte_safe (int);
2408extern void init_character_once (void); 2408extern void init_character_once (void);
2409extern void syms_of_character (void); 2409extern void syms_of_character (void);
diff --git a/src/search.c b/src/search.c
index 59a530eff61..682fa185bbb 100644
--- a/src/search.c
+++ b/src/search.c
@@ -2634,11 +2634,8 @@ since only regular expressions have distinguished subexpressions. */)
2634 EMACS_INT substed_alloc_size, substed_len; 2634 EMACS_INT substed_alloc_size, substed_len;
2635 int buf_multibyte = !NILP (BVAR (current_buffer, enable_multibyte_characters)); 2635 int buf_multibyte = !NILP (BVAR (current_buffer, enable_multibyte_characters));
2636 int str_multibyte = STRING_MULTIBYTE (newtext); 2636 int str_multibyte = STRING_MULTIBYTE (newtext);
2637 Lisp_Object rev_tbl;
2638 int really_changed = 0; 2637 int really_changed = 0;
2639 2638
2640 rev_tbl = Qnil;
2641
2642 substed_alloc_size = length * 2 + 100; 2639 substed_alloc_size = length * 2 + 100;
2643 substed = (unsigned char *) xmalloc (substed_alloc_size + 1); 2640 substed = (unsigned char *) xmalloc (substed_alloc_size + 1);
2644 substed_len = 0; 2641 substed_len = 0;
@@ -2658,7 +2655,7 @@ since only regular expressions have distinguished subexpressions. */)
2658 { 2655 {
2659 FETCH_STRING_CHAR_ADVANCE_NO_CHECK (c, newtext, pos, pos_byte); 2656 FETCH_STRING_CHAR_ADVANCE_NO_CHECK (c, newtext, pos, pos_byte);
2660 if (!buf_multibyte) 2657 if (!buf_multibyte)
2661 c = multibyte_char_to_unibyte (c, rev_tbl); 2658 c = multibyte_char_to_unibyte (c);
2662 } 2659 }
2663 else 2660 else
2664 { 2661 {
@@ -2681,7 +2678,7 @@ since only regular expressions have distinguished subexpressions. */)
2681 FETCH_STRING_CHAR_ADVANCE_NO_CHECK (c, newtext, 2678 FETCH_STRING_CHAR_ADVANCE_NO_CHECK (c, newtext,
2682 pos, pos_byte); 2679 pos, pos_byte);
2683 if (!buf_multibyte && !ASCII_CHAR_P (c)) 2680 if (!buf_multibyte && !ASCII_CHAR_P (c))
2684 c = multibyte_char_to_unibyte (c, rev_tbl); 2681 c = multibyte_char_to_unibyte (c);
2685 } 2682 }
2686 else 2683 else
2687 { 2684 {
diff --git a/src/xdisp.c b/src/xdisp.c
index 148c7bc5ec6..308588101e2 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -7962,7 +7962,7 @@ message_dolog (const char *m, EMACS_INT nbytes, int nlflag, int multibyte)
7962 c = string_char_and_length (msg + i, &char_bytes); 7962 c = string_char_and_length (msg + i, &char_bytes);
7963 work[0] = (ASCII_CHAR_P (c) 7963 work[0] = (ASCII_CHAR_P (c)
7964 ? c 7964 ? c
7965 : multibyte_char_to_unibyte (c, Qnil)); 7965 : multibyte_char_to_unibyte (c));
7966 insert_1_both (work, 1, 1, 1, 0, 0); 7966 insert_1_both (work, 1, 1, 1, 0, 0);
7967 } 7967 }
7968 } 7968 }
@@ -9223,7 +9223,7 @@ set_message_1 (EMACS_INT a1, Lisp_Object a2, EMACS_INT nbytes, EMACS_INT multiby
9223 c = string_char_and_length (msg + i, &n); 9223 c = string_char_and_length (msg + i, &n);
9224 work[0] = (ASCII_CHAR_P (c) 9224 work[0] = (ASCII_CHAR_P (c)
9225 ? c 9225 ? c
9226 : multibyte_char_to_unibyte (c, Qnil)); 9226 : multibyte_char_to_unibyte (c));
9227 insert_1_both (work, 1, 1, 1, 0, 0); 9227 insert_1_both (work, 1, 1, 1, 0, 0);
9228 } 9228 }
9229 } 9229 }