From ffcd490cb49ba86d625288ea425d98e8cac22a05 Mon Sep 17 00:00:00 2001 From: Andrea Corallo Date: Wed, 23 Dec 2020 15:51:55 +0100 Subject: Negate only values while constraining variables (bug#45376) * lisp/emacs-lisp/comp-cstr.el (comp-cstr-value-negation): New function. * lisp/emacs-lisp/comp.el (comp-fwprop-insn): Use `comp-cstr-value-negation'. * test/src/comp-test-funcs.el (comp-test-45376-1-f): Rename. (comp-test-45376-2-f): New funcion. * test/src/comp-tests.el (bug-45376-1): Rename test. (bug-45376-2): Add test. --- lisp/emacs-lisp/comp.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lisp/emacs-lisp/comp.el') diff --git a/lisp/emacs-lisp/comp.el b/lisp/emacs-lisp/comp.el index 485e5dc6ad2..6ed50dc0122 100644 --- a/lisp/emacs-lisp/comp.el +++ b/lisp/emacs-lisp/comp.el @@ -2534,7 +2534,7 @@ Fold the call in case." (not ;; Prevent double negation! (unless (comp-cstr-neg (car operands)) - (comp-cstr-negation lval (car operands)))))) + (comp-cstr-value-negation lval (car operands)))))) (`(setimm ,lval ,v) (setf (comp-mvar-value lval) v)) (`(phi ,lval . ,rest) -- cgit v1.2.3