[net.micro.68k] MicroEMACS 3.7 for CP/M-68K

context@uw-june (Ronald Blanford) (08/20/86)

I've got the new version of microEmacs 3.7 running under CP/M-68K.
The diff file follows.  Although the new functions are nice, the
screen performance is worse than Conroy's version 30 because it
rewrites the screen rather than making use of scroll regions or
line insert/delete functions.

Most of the changes are due to apparent limitations in the CP/M-68K
compiler: identifiers unique in 7 characters, redundant `struct'
not accepted, parse error on `int (*fncmatch(fname))()', etc.  The
file I/O is standard, and the tty I/O simple.

ansi.c

34,35c34,35
< extern  int     ansieeol();
< extern  int     ansieeop();
---
> extern  int     anseeol();
> extern  int     anseeop();

65,66c65,66
<         ansieeol,
<         ansieeop,
---
>         anseeol,
>         anseeop,

115c115
< ansieeol()
---
> anseeol()

122c122
< ansieeop()
---
> anseeop()


bind.c

166,167c166,168
< int (*fncmatch(fname))() /* match fname to a function in the names table
< 			    and return any match or NULL if none		*/
---
> typedef int (*PFI)();
> PFI fncmatch(fname) 	/* match fname to a function in the names table
> 			    and return any match or NULL if none	*/


display.c

583c583
< struct VIDEO *vp1;	/* virtual screen image */
---
> VIDEO *vp1;		/* virtual screen image */

605,606c605,606
< struct VIDEO *vp1;	/* virtual screen image */
< struct VIDEO *vp2;	/* physical screen image */
---
> VIDEO *vp1;		/* virtual screen image */
> VIDEO *vp2;		/* physical screen image */

730c730
< 		if (cp3-cp5 <= 3)		/* Use only if erase is */
---
> 		if ((int)(cp3-cp5) <= 3)	/* Use only if erase is */

734c734
< 	movecursor(row, cp1 - &vp1->v_text[0]);	/* Go to start of line. */
---
> 	movecursor(row, (int)(cp1 - &vp1->v_text[0]));	/* Go to start of line. */


ebind.h

93c93
< 	{META|CTRL|'V',		scrnextdw},
---
> 	{META|CTRL|'V',		scrnxtdw},

97c97
< 	{META|CTRL|'Z',		scrnextup},
---
> 	{META|CTRL|'Z',		scrnxtup},


edef.h

36c36
< struct	BUFFER *bstore = NULL;		/* buffer to store macro text to*/
---
> BUFFER *bstore = NULL;		/* buffer to store macro text to*/

97c97
< extern	struct	BUFFER *bstore;		/* buffer to store macro text to*/
---
> extern	BUFFER *bstore;		/* buffer to store macro text to*/


efunc.h

96,97c96,97
< extern	int	scrnextup();		/* scroll next window back	*/
< extern	int	scrnextdw();		/* scroll next window down	*/
---
> extern	int	scrnxtup();		/* scroll next window back	*/
> extern	int	scrnxtdw();		/* scroll next window down	*/

328,329c328,329
< 	{"scroll-next-up",		scrnextup},
< 	{"scroll-next-down",		scrnextdw},
---
> 	{"scroll-next-up",		scrnxtup},
> 	{"scroll-next-down",		scrnxtdw},


epath.h

32a33,50
> #if	CPM
> {
> 	"emacs.rc",
> 	"emacs.hlp",
> 	"A:",
> 	""
> };
> #endif
> 
> #if	CPM68K
> {
> 	"emacs.rc",
> 	"emacs.hlp",
> 	"0A:",
> 	""
> };
> #endif
> 


estruct.h

23a24
> #define CPM68K  1                       /* CP/M-68K                     */


exec.c

81c81
< 	struct LINE *lp;	/* a line pointer */
---
> 	LINE *lp;		/* a line pointer */

287c287
< 	register struct BUFFER *bp;	/* pointer to macro buffer */
---
> 	register BUFFER *bp;		/* pointer to macro buffer */


file.c

179c179
< 		   *(sptr + 1) == 'c' || *(sptr + 1) == 'h')
---
> 		   (*(sptr + 1) == 'c' || *(sptr + 1) == 'h'))

261c261
< #if     CPM
---
> #if     CPM | CPM68K


input.c

55c55
< 	return(mlreplyt(prompt,buf,nbuf,'\n'));
---
> 	return(mlreplt(prompt,buf,nbuf,'\n'));

62c62
< mlreplyt(prompt, buf, nbuf, eolchar)
---
> mlreplt(prompt, buf, nbuf, eolchar)


random.c

723c723
< 	status = mlreplyt("String to insert<ESC>: ", tstring, NPAT, 27);
---
> 	status = mlreplt("String to insert<ESC>: ", tstring, NPAT, 27);


search.c

250c250
< 	s = mlreplyt(tpat, tpat, NPAT, 27);	/* Read pattern */
---
> 	s = mlreplt(tpat, tpat, NPAT, 27);	/* Read pattern */


spawn.c

66,67c66,67
< #if     CPM
<         mlwrite("Not in CP/M-86");
---
> #if     CPM | CPM68K
>         mlwrite("Not in CP/M");

158,159c158,159
< #if     CPM
<         mlwrite("Not in CP/M-86");
---
> #if     CPM | CPM68K
>         mlwrite("Not in CP/M");

214,215c214,215
< #if     CPM
<         mlwrite("Not availible under CP/M-86");
---
> #if     CPM | CPM68K
>         mlwrite("Not available under CP/M");

320,321c320,321
< #if     CPM
<         mlwrite("Not availible under CP/M-86");
---
> #if     CPM | CPM68K
>         mlwrite("Not available under CP/M");


termio.c

141c141
< #if     CPM
---
> #if     CPM | CPM68K

206c206
< #if     CPM
---
> #if     CPM | CPM68K

251a252,255
> #if     CPM68K
>         __BDOS(6, (long)c);
> #endif
> 

303c307
< #if     CPM
---
> #if     CPM | CPM68K

359a364,367
> #if     CPM68K
>         return (__BDOS(6, (long)0xFF));
> #endif
> 

454a463,466
> #if	CPM68K
> 	return (__BDOS(6, (long)0xFE));
> #endif
> 


window.c

531c531
< scrnextup(f, n)		/* scroll the next window up (back) a page */
---
> scrnxtup(f, n)		/* scroll the next window up (back) a page */

539c539
< scrnextdw(f, n)		/* scroll the next window down (forward) a page */
---
> scrnxtdw(f, n)		/* scroll the next window down (forward) a page */