aboutsummaryrefslogtreecommitdiffstats
path: root/src/coding.c
diff options
context:
space:
mode:
authorMattias EngdegÄrd2022-06-16 14:11:03 +0200
committerMattias EngdegÄrd2022-06-16 14:49:58 +0200
commit946d70a8910a827d74a384ff6421b9e952e0df2e (patch)
tree455daa0feaa6cd7edf01a14a697bf7be5d77d0b2 /src/coding.c
parentdecb64fd835ef1740d720ff877788eb0626737b5 (diff)
downloademacs-946d70a8910a827d74a384ff6421b9e952e0df2e.tar.gz
emacs-946d70a8910a827d74a384ff6421b9e952e0df2e.zip
Use BASE_EQ instead of EQ where obviously safe
* src/alloc.c (deadp): * src/buffer.c (reset_buffer_local_variables, candidate_buffer) (Fkill_buffer, Fbuffer_swap_text, Fmake_overlay, Fmove_overlay): * src/callint.c (Fcall_interactively): * src/coding.c (decode_coding_object, encode_coding_object) (code_convert_region, Ffind_operation_coding_system): * src/comp.c (Fcomp_el_to_eln_rel_filename): * src/conf_post.h (RE_TRANSLATE_P): * src/data.c (Fkill_local_variable, Fash, expt_integer): * src/dired.c (file_name_completion): * src/dispnew.c (set_window_cursor_after_update, update_frame_1) (Fframe_or_buffer_changed_p): * src/doc.c (Fdocumentation, Fdocumentation_property) (default_to_grave_quoting_style): * src/editfns.c (Fconstrain_to_field, save_excursion_save) (save_excursion_restore, Fngettext): * src/eval.c (Fautoload, un_autoload, specbind): * src/fileio.c (Fmake_temp_file_internal): * src/fns.c (string_char_to_byte, string_byte_to_char) (Fnthcdr, Fnreverse): * src/indent.c (vmotion): * src/inotify.c (add_watch): * src/keyboard.c (command_loop_1, read_char) (read_char_minibuf_menu_prompt): * src/lread.c (oblookup): * src/macfont.m (macfont_descriptor_entity, macfont_open): * src/minibuf.c (Finnermost_minibuffer_p, Ftry_completion) (Ftest_completion): * src/nsfns.m (ns_set_icon_name): * src/pdumper.c (dump_queue_dequeue): * src/pgtkfns.c (pgtk_set_icon_type, pgtk_set_icon_name): * src/process.c (Faccept_process_output): * src/textprop.c (set_text_properties): * src/w32fns.c (w32_set_icon_type, w32_set_icon_name): * src/w32select.c (validate_coding_system): * src/window.c (decode_next_window_args, window_loop) (save_window_save): * src/xdisp.c (wset_redisplay): * src/xfaces.c (Fx_family_fonts, resolve_face_name) (gui_supports_face_attributes_p): * src/xfns.c (x_set_icon_type, x_set_icon_name): * src/xselect.c (clean_local_selection_data): Use BASE_EQ instead of EQ where it is obvious that neither argument can be a symbol with properties or at least one argument is a non-symbol.
Diffstat (limited to 'src/coding.c')
-rw-r--r--src/coding.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/coding.c b/src/coding.c
index aa32efc3f61..68f3201de80 100644
--- a/src/coding.c
+++ b/src/coding.c
@@ -8194,7 +8194,7 @@ decode_coding_object (struct coding_system *coding,
8194 if (saved_pt >= 0) 8194 if (saved_pt >= 0)
8195 { 8195 {
8196 /* This is the case of: 8196 /* This is the case of:
8197 (BUFFERP (src_object) && EQ (src_object, dst_object)) 8197 (BUFFERP (src_object) && BASE_EQ (src_object, dst_object))
8198 As we have moved PT while replacing the original buffer 8198 As we have moved PT while replacing the original buffer
8199 contents, we must recover it now. */ 8199 contents, we must recover it now. */
8200 set_buffer_internal (XBUFFER (src_object)); 8200 set_buffer_internal (XBUFFER (src_object));
@@ -8298,7 +8298,7 @@ encode_coding_object (struct coding_system *coding,
8298 attrs = CODING_ID_ATTRS (coding->id); 8298 attrs = CODING_ID_ATTRS (coding->id);
8299 8299
8300 bool same_buffer = false; 8300 bool same_buffer = false;
8301 if (EQ (src_object, dst_object) && BUFFERP (src_object)) 8301 if (BASE_EQ (src_object, dst_object) && BUFFERP (src_object))
8302 { 8302 {
8303 struct Lisp_Marker *tail; 8303 struct Lisp_Marker *tail;
8304 8304
@@ -8379,7 +8379,7 @@ encode_coding_object (struct coding_system *coding,
8379 if (BUFFERP (dst_object)) 8379 if (BUFFERP (dst_object))
8380 { 8380 {
8381 coding->dst_object = dst_object; 8381 coding->dst_object = dst_object;
8382 if (EQ (src_object, dst_object)) 8382 if (BASE_EQ (src_object, dst_object))
8383 { 8383 {
8384 coding->dst_pos = from; 8384 coding->dst_pos = from;
8385 coding->dst_pos_byte = from_byte; 8385 coding->dst_pos_byte = from_byte;
@@ -8434,7 +8434,7 @@ encode_coding_object (struct coding_system *coding,
8434 if (saved_pt >= 0) 8434 if (saved_pt >= 0)
8435 { 8435 {
8436 /* This is the case of: 8436 /* This is the case of:
8437 (BUFFERP (src_object) && EQ (src_object, dst_object)) 8437 (BUFFERP (src_object) && BASE_EQ (src_object, dst_object))
8438 As we have moved PT while replacing the original buffer 8438 As we have moved PT while replacing the original buffer
8439 contents, we must recover it now. */ 8439 contents, we must recover it now. */
8440 set_buffer_internal (XBUFFER (src_object)); 8440 set_buffer_internal (XBUFFER (src_object));
@@ -9416,7 +9416,7 @@ code_convert_region (Lisp_Object start, Lisp_Object end,
9416 setup_coding_system (coding_system, &coding); 9416 setup_coding_system (coding_system, &coding);
9417 coding.mode |= CODING_MODE_LAST_BLOCK; 9417 coding.mode |= CODING_MODE_LAST_BLOCK;
9418 9418
9419 if (BUFFERP (dst_object) && !EQ (dst_object, src_object)) 9419 if (BUFFERP (dst_object) && !BASE_EQ (dst_object, src_object))
9420 { 9420 {
9421 struct buffer *buf = XBUFFER (dst_object); 9421 struct buffer *buf = XBUFFER (dst_object);
9422 ptrdiff_t buf_pt = BUF_PT (buf); 9422 ptrdiff_t buf_pt = BUF_PT (buf);
@@ -10785,7 +10785,7 @@ usage: (find-operation-coding-system OPERATION ARGUMENTS...) */)
10785 && ((STRINGP (target) 10785 && ((STRINGP (target)
10786 && STRINGP (XCAR (elt)) 10786 && STRINGP (XCAR (elt))
10787 && fast_string_match (XCAR (elt), target) >= 0) 10787 && fast_string_match (XCAR (elt), target) >= 0)
10788 || (FIXNUMP (target) && EQ (target, XCAR (elt))))) 10788 || (FIXNUMP (target) && BASE_EQ (target, XCAR (elt)))))
10789 { 10789 {
10790 val = XCDR (elt); 10790 val = XCDR (elt);
10791 /* Here, if VAL is both a valid coding system and a valid 10791 /* Here, if VAL is both a valid coding system and a valid