mirror of
https://github.com/Interlisp/maiko.git
synced 2026-05-01 06:09:21 +00:00
Combine three small arithmetic opcode implementation files into one
Combines arith2.c ... arith4.c files and their associated header files into new arithops.c/arithopsdefs.h files, and adjusts the CMakeLists.txt, and old-style makefile-tail. Also updates makefile-dos, inlnPS2.h, and inlndos.h to reflect these changes, though these are not used.
This commit is contained in:
15
inc/arith.h
15
inc/arith.h
@@ -126,19 +126,4 @@
|
||||
} \
|
||||
} while (0)
|
||||
|
||||
#define N_IARITH_BODY_2(a, tos, op) \
|
||||
do { \
|
||||
register int arg1, arg2; \
|
||||
\
|
||||
N_IGETNUMBER(a, arg1, do_ufn); \
|
||||
N_IGETNUMBER(tos, arg2, do_ufn); \
|
||||
\
|
||||
arg1 = arg1 op arg2; \
|
||||
\
|
||||
N_ARITH_SWITCH(arg1); \
|
||||
\
|
||||
do_ufn: \
|
||||
ERROR_EXIT(tos); \
|
||||
} while (0)
|
||||
|
||||
#endif /* ARITH_H */
|
||||
|
||||
@@ -1,7 +0,0 @@
|
||||
#ifndef ARITH3DEFS_H
|
||||
#define ARITH3DEFS_H 1
|
||||
#include "lispemul.h" /* for LispPTR */
|
||||
LispPTR N_OP_makenumber(int tosm1, int tos);
|
||||
LispPTR N_OP_boxiplus(register int a, int tos);
|
||||
LispPTR N_OP_boxidiff(register int a, int tos);
|
||||
#endif
|
||||
@@ -1,9 +0,0 @@
|
||||
#ifndef ARITH4DEFS_H
|
||||
#define ARITH4DEFS_H 1
|
||||
#include "lispemul.h" /* for LispPTR */
|
||||
LispPTR N_OP_times2(int tosm1, int tos);
|
||||
LispPTR N_OP_itimes2(int tosm1, int tos);
|
||||
LispPTR N_OP_quot(int tosm1, int tos);
|
||||
LispPTR N_OP_iquot(int tosm1, int tos);
|
||||
LispPTR N_OP_iremainder(int tosm1, int tos);
|
||||
#endif
|
||||
@@ -1,5 +1,5 @@
|
||||
#ifndef ARITH2DEFS_H
|
||||
#define ARITH2DEFS_H 1
|
||||
#ifndef ARITHOPSDEFS_H
|
||||
#define ARITHOPSDEFS_H 1
|
||||
#include "lispemul.h" /* for LispPTR */
|
||||
LispPTR N_OP_plus2(int tosm1, int tos);
|
||||
LispPTR N_OP_iplus2(int tosm1, int tos);
|
||||
@@ -12,4 +12,12 @@ LispPTR N_OP_greaterp(int tosm1, int tos);
|
||||
LispPTR N_OP_igreaterp(int tosm1, int tos);
|
||||
LispPTR N_OP_iplusn(int tos, int n);
|
||||
LispPTR N_OP_idifferencen(int tos, int n);
|
||||
LispPTR N_OP_makenumber(int tosm1, int tos);
|
||||
LispPTR N_OP_boxiplus(int a, int tos);
|
||||
LispPTR N_OP_boxidiff(int a, int tos);
|
||||
LispPTR N_OP_times2(int tosm1, int tos);
|
||||
LispPTR N_OP_itimes2(int tosm1, int tos);
|
||||
LispPTR N_OP_quot(int tosm1, int tos);
|
||||
LispPTR N_OP_iquot(int tosm1, int tos);
|
||||
LispPTR N_OP_iremainder(int tosm1, int tos);
|
||||
#endif
|
||||
@@ -48,7 +48,7 @@
|
||||
/* */
|
||||
/* */
|
||||
/* Register conventions within arithmetic functions in the files */
|
||||
/* arith2.c - arith4.c, etc.: */
|
||||
/* arithops.c, etc.: */
|
||||
/* */
|
||||
/* esi first argument to the function */
|
||||
/* edi second argument to the function */
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
/* */
|
||||
/* */
|
||||
/* Register conventions within arithmetic functions in the files */
|
||||
/* arith2.c - arith4.c, etc.: */
|
||||
/* arithops.c etc.: */
|
||||
/* */
|
||||
/* esi first argument to the function */
|
||||
/* edi second argument to the function */
|
||||
|
||||
Reference in New Issue
Block a user