aboutsummaryrefslogtreecommitdiffstats
path: root/src/eval.c
diff options
context:
space:
mode:
authorTom Tromey2018-08-09 17:56:53 -0600
committerTom Tromey2018-08-09 17:56:53 -0600
commitaccb7b7ecc19f85c2750ded1046a464bc73c6a52 (patch)
tree1aa94af022d6700a93a8ff2b73f5b210046ac010 /src/eval.c
parentf822a2516d88eeb2118fbbc8554f155e86dfd74e (diff)
parent53483df0de0085dbc9ef0b15a0f629ab808b0147 (diff)
downloademacs-accb7b7ecc19f85c2750ded1046a464bc73c6a52.tar.gz
emacs-accb7b7ecc19f85c2750ded1046a464bc73c6a52.zip
Merge remote-tracking branch 'origin/master' into feature/bignum
Diffstat (limited to 'src/eval.c')
-rw-r--r--src/eval.c20
1 files changed, 2 insertions, 18 deletions
diff --git a/src/eval.c b/src/eval.c
index f7d4d5be2aa..8745ba9ef99 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -1732,28 +1732,12 @@ xsignal3 (Lisp_Object error_symbol, Lisp_Object arg1, Lisp_Object arg2, Lisp_Obj
1732} 1732}
1733 1733
1734/* Signal `error' with message S, and additional arg ARG. 1734/* Signal `error' with message S, and additional arg ARG.
1735 If ARG is not a genuine list, make it a one-element list. */ 1735 If ARG is not a proper list, make it a one-element list. */
1736 1736
1737void 1737void
1738signal_error (const char *s, Lisp_Object arg) 1738signal_error (const char *s, Lisp_Object arg)
1739{ 1739{
1740 Lisp_Object tortoise, hare; 1740 if (NILP (Fproper_list_p (arg)))
1741
1742 hare = tortoise = arg;
1743 while (CONSP (hare))
1744 {
1745 hare = XCDR (hare);
1746 if (!CONSP (hare))
1747 break;
1748
1749 hare = XCDR (hare);
1750 tortoise = XCDR (tortoise);
1751
1752 if (EQ (hare, tortoise))
1753 break;
1754 }
1755
1756 if (!NILP (hare))
1757 arg = list1 (arg); 1741 arg = list1 (arg);
1758 1742
1759 xsignal (Qerror, Fcons (build_string (s), arg)); 1743 xsignal (Qerror, Fcons (build_string (s), arg));