aboutsummaryrefslogtreecommitdiffstats
path: root/src/data.c
diff options
context:
space:
mode:
authorPip Cet2024-12-11 22:31:07 +0000
committerAndrea Corallo2025-09-22 10:28:40 +0200
commit020e2f5ddbbc2f380f694e1537aaa8405daf5829 (patch)
treecb773d9142a1e9bd79baf03c5c2670cedc53bef3 /src/data.c
parente58efac78eed96842e4b6cbc64a1633e74edd6c1 (diff)
downloademacs-020e2f5ddbbc2f380f694e1537aaa8405daf5829.tar.gz
emacs-020e2f5ddbbc2f380f694e1537aaa8405daf5829.zip
Change EQ to move slow code path into a separate function
* src/data.c (slow_eq): New function. * src/lisp.h (EQ): Call it.
Diffstat (limited to 'src/data.c')
-rw-r--r--src/data.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/data.c b/src/data.c
index 5b3c9792ea0..333d908aedc 100644
--- a/src/data.c
+++ b/src/data.c
@@ -155,6 +155,16 @@ circular_list (Lisp_Object list)
155 155
156/* Data type predicates. */ 156/* Data type predicates. */
157 157
158/* NO_INLINE to avoid excessive code growth when LTO is in use. */
159NO_INLINE bool
160slow_eq (Lisp_Object x, Lisp_Object y)
161{
162 return BASE_EQ ((symbols_with_pos_enabled && SYMBOL_WITH_POS_P (x)
163 ? XSYMBOL_WITH_POS_SYM (x) : x),
164 (symbols_with_pos_enabled && SYMBOL_WITH_POS_P (y)
165 ? XSYMBOL_WITH_POS_SYM (y) : y));
166}
167
158DEFUN ("eq", Feq, Seq, 2, 2, 0, 168DEFUN ("eq", Feq, Seq, 2, 2, 0,
159 doc: /* Return t if the two args are the same Lisp object. */ 169 doc: /* Return t if the two args are the same Lisp object. */
160 attributes: const) 170 attributes: const)