1
0
mirror of https://github.com/Interlisp/maiko.git synced 2026-01-18 00:52:33 +00:00

Create conspage.h to declare functions defined in conspage.c

Update files that depend on conspage functions to include conspage.h
Declare as static all functions in conspage.c that are not needed externally.
Add dependencies to makefile.

	modified:   bin/makefile-darwin.386-x
	modified:   bin/makefile-tail
	new file:   inc/conspage.h
	modified:   src/conspage.c
	modified:   src/mvs.c
	modified:   src/rplcons.c
	modified:   src/xc.c
	modified:   src/z2.c
This commit is contained in:
Nick Briggs 2017-06-29 22:33:35 -07:00
parent d450521ffd
commit 0371f19167
8 changed files with 20 additions and 10 deletions

View File

@ -48,5 +48,5 @@ $(OBJECTDIR)xc.o: $(SRCDIR)xc.c $(INCDIR)lispemul.h $(INCDIR)emlglob.h \
$(INCDIR)initatms.h $(INCDIR)gc.h \
$(INCDIR)arith.h $(INCDIR)stream.h \
$(INCDIR)tos1defs.h $(INCDIR)tosret.h \
$(INCDIR)tosfns.h $(INCDIR)inlineC.h $(INCDIR)car-cdr.h
$(INCDIR)tosfns.h $(INCDIR)inlineC.h $(INCDIR)car-cdr.h $(INCDIR)conspage.h
$(CC) $(DISPRFLAGS) -UOPDISP $(SRCDIR)xc.c -I$(INCDIR) -o $(OBJECTDIR)xc.o

View File

@ -393,7 +393,7 @@ $(OBJECTDIR)common.o : $(SRCDIR)common.c $(REQUIRED-INCS) $(INCDIR)lispemul.h
$(OBJECTDIR)conspage.o : $(SRCDIR)conspage.c $(REQUIRED-INCS) $(INCDIR)lispemul.h \
$(INCDIR)address.h $(INCDIR)adr68k.h \
$(INCDIR)lsptypes.h $(INCDIR)cell.h $(INCDIR)lispmap.h \
$(INCDIR)gc.h $(INCDIR)lspglob.h
$(INCDIR)gc.h $(INCDIR)lspglob.h $(INCDIR)conspage.h
$(CC) $(RFLAGS) $(SRCDIR)conspage.c $(INLINE) -o $(OBJECTDIR)conspage$(OEXT)
$(OBJECTDIR)mkcell.o : $(SRCDIR)mkcell.c $(REQUIRED-INCS) $(INCDIR)lispemul.h \
@ -412,7 +412,7 @@ $(OBJECTDIR)z2.o : $(SRCDIR)z2.c $(REQUIRED-INCS) \
$(INCDIR)lispemul.h $(INCDIR)emlglob.h $(INCDIR)lspglob.h \
$(INCDIR)lispmap.h $(INCDIR)lsptypes.h $(INCDIR)address.h \
$(INCDIR)adr68k.h $(INCDIR)cell.h $(INCDIR)stack.h \
$(INCDIR)gc.h $(INCDIR)my.h $(INCDIR)car-cdr.h
$(INCDIR)gc.h $(INCDIR)my.h $(INCDIR)car-cdr.h $(INCDIR)conspage.h
$(CC) $(RFLAGS) $(SRCDIR)z2.c $(INLINE) -o $(OBJECTDIR)z2$(OEXT)
$(OBJECTDIR)eqf.o : $(SRCDIR)eqf.c $(REQUIRED-INCS) $(INCDIR)fp.h \
@ -669,7 +669,7 @@ $(OBJECTDIR)misc7.o : $(SRCDIR)misc7.c $(REQUIRED-INCS) $(INCDIR)lispemul.h \
$(OBJECTDIR)mvs.o : $(SRCDIR)mvs.c $(REQUIRED-INCS) $(INCDIR)lispemul.h \
$(INCDIR)lspglob.h $(INCDIR)adr68k.h \
$(INCDIR)lispmap.h $(INCDIR)lsptypes.h $(INCDIR)emlglob.h \
$(INCDIR)stack.h $(INCDIR)opcodes.h $(INCDIR)car-cdr.h
$(INCDIR)stack.h $(INCDIR)opcodes.h $(INCDIR)car-cdr.h $(INCDIR)conspage.h
$(CC) $(RFLAGS) $(SRCDIR)mvs.c $(INLINE) -o $(OBJECTDIR)mvs$(OEXT)
$(OBJECTDIR)mkatom.o : $(SRCDIR)mkatom.c $(REQUIRED-INCS) $(INCDIR)lispemul.h \
@ -692,7 +692,7 @@ $(OBJECTDIR)return.o : $(SRCDIR)return.c $(REQUIRED-INCS) $(INCDIR)lispemul.h
$(OBJECTDIR)rplcons.o : $(SRCDIR)rplcons.c $(REQUIRED-INCS) $(INCDIR)lispemul.h \
$(INCDIR)emlglob.h $(INCDIR)lspglob.h \
$(INCDIR)lsptypes.h $(INCDIR)address.h $(INCDIR)adr68k.h \
$(INCDIR)gc.h $(INCDIR)cell.h
$(INCDIR)gc.h $(INCDIR)cell.h $(INCDIR)conspage.h
$(CC) $(RFLAGS) $(SRCDIR)rplcons.c $(INLINE) -o $(OBJECTDIR)rplcons$(OEXT)
$(OBJECTDIR)rs232c.o : $(SRCDIR)rs232c.c $(REQUIRED-INCS) $(INCDIR)rs232c.h

3
inc/conspage.h Normal file
View File

@ -0,0 +1,3 @@
struct conspage *next_conspage(void);
LispPTR N_OP_cons(register int cons_car, register int cons_cdr);
LispPTR cons(LispPTR cons_car, LispPTR cons_cdr);

View File

@ -29,6 +29,7 @@ static char *id = "$Id: conspage.c,v 1.3 1999/05/31 23:35:27 sybalsky Exp $ Copy
#include "lispmap.h"
#include "lspglob.h"
#include "gc.h"
#include "conspage.h"
/************************************************************************/
/* */
@ -68,7 +69,7 @@ static char *id = "$Id: conspage.c,v 1.3 1999/05/31 23:35:27 sybalsky Exp $ Copy
/* */
/************************************************************************/
void init_conspage(register struct conspage *base, unsigned int link)
static void init_conspage(register struct conspage *base, unsigned int link)
/* Page Base */
/* Prev Link page number DL->int*/
{
@ -190,7 +191,7 @@ ex:
/* */
/************************************************************************/
ConsCell *find_pair_in_page(struct conspage *pg, LispPTR cdrval) {
static ConsCell *find_pair_in_page(struct conspage *pg, LispPTR cdrval) {
ConsCell *carcell, *cdrcell;
unsigned int offset, prior, priorprior, ppriorprior, noffset, nprior, poffset;
@ -249,7 +250,7 @@ ConsCell *find_pair_in_page(struct conspage *pg, LispPTR cdrval) {
return ((ConsCell *)0);
}
ConsCell *find_cdrcodable_pair(LispPTR cdrval) {
static ConsCell *find_cdrcodable_pair(LispPTR cdrval) {
ConsCell *cell;
struct conspage *pg;
unsigned pgno = ListpDTD->dtd_nextpage;
@ -263,7 +264,7 @@ ConsCell *find_cdrcodable_pair(LispPTR cdrval) {
return (cell);
} /* end of find_cdrcodable_pair */
ConsCell *find_free_cons_cell(void) {
static ConsCell *find_free_cons_cell(void) {
ConsCell *cell;
struct conspage *pg, *priorpg;
unsigned pgno = ListpDTD->dtd_nextpage;

View File

@ -34,6 +34,8 @@ static char *id = "$Id: mvs.c,v 1.3 1999/05/31 23:35:40 sybalsky Exp $ Copyright
#include "lsptypes.h"
#include "stack.h"
#include "opcodes.h"
#include "cell.h"
#include "conspage.h"
#include "car-cdr.h"
#ifdef AIXPS2

View File

@ -36,6 +36,8 @@ static char *id = "$Id: rplcons.c,v 1.3 1999/05/31 23:35:41 sybalsky Exp $ Copyr
#include "adr68k.h"
#include "gc.h"
#include "cell.h"
#include "conspage.h"
#include "car-cdr.h"
/***************************************************/

View File

@ -52,6 +52,7 @@ static char *id = "$Id: xc.c,v 1.4 2001/12/26 22:17:06 sybalsky Exp $ Copyright
#include "lispmap.h"
#include "cell.h"
#include "car-cdr.h"
#include "conspage.h"
#include "initatms.h"
#include "gc.h"
#include "arith.h"

View File

@ -38,10 +38,11 @@ static char *id = "$Id: z2.c,v 1.3 1999/05/31 23:35:47 sybalsky Exp $ Copyright
#include "address.h"
#include "adr68k.h"
#include "cell.h"
#include "car-cdr.h"
#include "conspage.h"
#include "stack.h"
#include "gc.h"
#include "my.h"
#include "car-cdr.h"
struct cadr_cell cadr(LispPTR cell_adr);