mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-26 15:21:51 -08:00
Change comparison functions =, <, >, <=, >= to take many arguments.
* src/data.c: Change comparison functions' interface and implementation * src/lisp.h: Make arithcompare available for efficient two arg comparisons * src/bytecode.c: Use arithcompare * src/fileio.c: Use new interface * test/automated/data-tests.el: New tests for comparison functions * etc/NEWS
This commit is contained in:
parent
1b3b87dfe0
commit
ebb9984728
6 changed files with 136 additions and 38 deletions
|
|
@ -1367,7 +1367,7 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth,
|
|||
Lisp_Object v1;
|
||||
BEFORE_POTENTIAL_GC ();
|
||||
v1 = POP;
|
||||
TOP = Fgtr (TOP, v1);
|
||||
TOP = arithcompare (TOP, v1, ARITH_GRTR);
|
||||
AFTER_POTENTIAL_GC ();
|
||||
NEXT;
|
||||
}
|
||||
|
|
@ -1377,7 +1377,7 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth,
|
|||
Lisp_Object v1;
|
||||
BEFORE_POTENTIAL_GC ();
|
||||
v1 = POP;
|
||||
TOP = Flss (TOP, v1);
|
||||
TOP = arithcompare (TOP, v1, ARITH_LESS);
|
||||
AFTER_POTENTIAL_GC ();
|
||||
NEXT;
|
||||
}
|
||||
|
|
@ -1387,7 +1387,7 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth,
|
|||
Lisp_Object v1;
|
||||
BEFORE_POTENTIAL_GC ();
|
||||
v1 = POP;
|
||||
TOP = Fleq (TOP, v1);
|
||||
TOP = arithcompare (TOP, v1, ARITH_LESS_OR_EQUAL);
|
||||
AFTER_POTENTIAL_GC ();
|
||||
NEXT;
|
||||
}
|
||||
|
|
@ -1397,7 +1397,7 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth,
|
|||
Lisp_Object v1;
|
||||
BEFORE_POTENTIAL_GC ();
|
||||
v1 = POP;
|
||||
TOP = Fgeq (TOP, v1);
|
||||
TOP = arithcompare (TOP, v1, ARITH_GRTR_OR_EQUAL);
|
||||
AFTER_POTENTIAL_GC ();
|
||||
NEXT;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue