summaryrefslogtreecommitdiffstats
path: root/crs.c
diff options
context:
space:
mode:
authorSteve Langasek <vorlon@debian.org>2004-12-07 23:23:48 -0800
committerBryan Newbold <bnewbold@robocracy.org>2017-02-20 00:05:28 -0800
commit37f2f5e0bb11a18deecf48c7ad6bcbf7bd932db2 (patch)
tree692caebb60ec5f80ce528a403b69351ca756d530 /crs.c
parente21d47d7813159bb71e0671df9b52ec0470c358d (diff)
parentc7d035ae1a729232579a0fe41ed5affa131d3623 (diff)
downloadscm-37f2f5e0bb11a18deecf48c7ad6bcbf7bd932db2.tar.gz
scm-37f2f5e0bb11a18deecf48c7ad6bcbf7bd932db2.zip
Import Debian changes 5d9-4.1debian/5d9-4.1
scm (5d9-4.1) unstable; urgency=high * Non-maintainer upload. * High-urgency upload for sarge-targetted RC bugfix. * Revert upstream "CAUTIOUS" define, which causes the scm build to fail its test suite on alpha (and, it appears, powerpc as well). Closes: #245810. scm (5d9-4) unstable; urgency=low * Apply patch from 144062 to fix hppa build (Closes: #144062) * Change scm.1 section from Jan 4 200 to 1. (lintian) scm (5d9-3) unstable; urgency=low * Properly clean up info files. * Make and install Xlibscm.info. scm (5d9-2) unstable; urgency=low * Fix path problem in slibcat. Hack at mklibcat.scm. (Closes: #241510) scm (5d9-1) unstable; urgency=low * New upstream release * Merge NMU sparc changes (Closes: #191171, #191356) * SHORT_INT is defined for ia64 upstream (Closes: #141928) * Scheme imps now grouped in info file (has been for a while) (Closes: #115452)
Diffstat (limited to 'crs.c')
-rw-r--r--crs.c78
1 files changed, 41 insertions, 37 deletions
diff --git a/crs.c b/crs.c
index 665b0bd..0b4fe5f 100644
--- a/crs.c
+++ b/crs.c
@@ -47,7 +47,11 @@
#ifdef __FreeBSD__
# include <ncurses.h>
#else
-# include <curses.h>
+# ifdef __NetBSD__
+# include <ncurses.h>
+# else
+# include <curses.h>
+# endif
#endif
#ifdef MWC
@@ -128,13 +132,13 @@ SCM lnewwin(lines, cols, args)
{
SCM begin_y, begin_x;
WINDOW *win;
- ASSERT(INUMP(lines), lines, ARG1, s_newwin);
- ASSERT(INUMP(cols), cols, ARG2, s_newwin);
- ASSERT(2==ilength(args), args, WNA, s_newwin);
+ ASRTER(INUMP(lines), lines, ARG1, s_newwin);
+ ASRTER(INUMP(cols), cols, ARG2, s_newwin);
+ ASRTER(2==ilength(args), args, WNA, s_newwin);
begin_y = CAR(args);
begin_x = CAR(CDR(args));
- ASSERT(INUMP(begin_y), begin_y, ARG3, s_newwin);
- ASSERT(INUMP(begin_x), begin_y, ARG4, s_newwin);
+ ASRTER(INUMP(begin_y), begin_y, ARG3, s_newwin);
+ ASRTER(INUMP(begin_x), begin_y, ARG4, s_newwin);
win = newwin(INUM(lines), INUM(cols),
INUM(begin_y), INUM(begin_x));
return mkwindow(win);
@@ -143,9 +147,9 @@ SCM lnewwin(lines, cols, args)
SCM lmvwin(win, y, x)
SCM win, y, x;
{
- ASSERT(NIMP(win) && WINP(win), win, ARG1, s_mvwin);
- ASSERT(INUMP(x), x, ARG2, s_mvwin);
- ASSERT(INUMP(y), y, ARG3, s_mvwin);
+ ASRTER(NIMP(win) && WINP(win), win, ARG1, s_mvwin);
+ ASRTER(INUMP(x), x, ARG2, s_mvwin);
+ ASRTER(INUMP(y), y, ARG3, s_mvwin);
return ERR==mvwin(WIN(win), INUM(y), INUM(x)) ? BOOL_F : BOOL_T;
}
@@ -154,16 +158,16 @@ SCM lsubwin(win, lines, args)
{
SCM cols, begin_y, begin_x;
WINDOW *nwin;
- ASSERT(NIMP(win) && WINP(win), win, ARG1, s_subwin);
- ASSERT(INUMP(lines), lines, ARG2, s_subwin);
- ASSERT(3==ilength(args), args, WNA, s_subwin);
+ ASRTER(NIMP(win) && WINP(win), win, ARG1, s_subwin);
+ ASRTER(INUMP(lines), lines, ARG2, s_subwin);
+ ASRTER(3==ilength(args), args, WNA, s_subwin);
cols = CAR(args);
args = CDR(args);
begin_y = CAR(args);
begin_x = CAR(CDR(args));
- ASSERT(INUMP(cols), cols, ARG3, s_subwin);
- ASSERT(INUMP(begin_y), begin_y, ARG3, s_subwin);
- ASSERT(INUMP(begin_x), begin_y, ARG4, s_subwin);
+ ASRTER(INUMP(cols), cols, ARG3, s_subwin);
+ ASRTER(INUMP(begin_y), begin_y, ARG3, s_subwin);
+ ASRTER(INUMP(begin_x), begin_y, ARG4, s_subwin);
nwin = subwin(WIN(win), INUM(lines), INUM(cols),
INUM(begin_y), INUM(begin_x));
return mkwindow(nwin);
@@ -172,16 +176,16 @@ SCM lsubwin(win, lines, args)
SCM loverlay(srcwin, dstwin)
SCM srcwin, dstwin;
{
- ASSERT(NIMP(srcwin) && WINP(srcwin), srcwin, ARG1, s_overlay);
- ASSERT(NIMP(dstwin) && WINP(dstwin), dstwin, ARG2, s_overlay);
+ ASRTER(NIMP(srcwin) && WINP(srcwin), srcwin, ARG1, s_overlay);
+ ASRTER(NIMP(dstwin) && WINP(dstwin), dstwin, ARG2, s_overlay);
return ERR==overlay(WIN(srcwin), WIN(dstwin)) ? BOOL_F : BOOL_T;
}
SCM loverwrite(srcwin, dstwin)
SCM srcwin, dstwin;
{
- ASSERT(NIMP(srcwin) && WINP(srcwin), srcwin, ARG1, s_overwrite);
- ASSERT(NIMP(dstwin) && WINP(dstwin), dstwin, ARG2, s_overwrite);
+ ASRTER(NIMP(srcwin) && WINP(srcwin), srcwin, ARG1, s_overwrite);
+ ASRTER(NIMP(dstwin) && WINP(dstwin), dstwin, ARG2, s_overwrite);
return ERR==overwrite(WIN(srcwin), WIN(dstwin)) ? BOOL_F : BOOL_T;
}
@@ -190,31 +194,31 @@ static char s_wmove[] = "wmove", s_wadd[] = "wadd", s_winsch[] = "winsch",
SCM lwmove(win, y, x)
SCM win, y, x;
{
- ASSERT(NIMP(win) && WINP(win), win, ARG1, s_wmove);
- ASSERT(INUMP(x), x, ARG2, s_wmove);
- ASSERT(INUMP(y), y, ARG3, s_wmove);
+ ASRTER(NIMP(win) && WINP(win), win, ARG1, s_wmove);
+ ASRTER(INUMP(x), x, ARG2, s_wmove);
+ ASRTER(INUMP(y), y, ARG3, s_wmove);
return ERR==wmove(WIN(win), INUM(y), INUM(x)) ? BOOL_F : BOOL_T;
}
SCM lwadd(win, obj)
SCM win, obj;
{
- ASSERT(NIMP(win) && WINP(win), win, ARG1, s_wadd);
+ ASRTER(NIMP(win) && WINP(win), win, ARG1, s_wadd);
if ICHRP(obj)
return ERR==waddch(WIN(win), ICHR(obj)) ? BOOL_F : BOOL_T;
if INUMP(obj)
return ERR==waddch(WIN(win), INUM(obj)) ? BOOL_F : BOOL_T;
- ASSERT(NIMP(obj) && STRINGP(obj), obj, ARG2, s_wadd);
+ ASRTER(NIMP(obj) && STRINGP(obj), obj, ARG2, s_wadd);
return ERR==waddstr(WIN(win), CHARS(obj)) ? BOOL_F : BOOL_T;
}
SCM lwinsch(win, obj)
SCM win, obj;
{
- ASSERT(NIMP(win) && WINP(win), win, ARG1, s_winsch);
+ ASRTER(NIMP(win) && WINP(win), win, ARG1, s_winsch);
if INUMP(obj)
return ERR==winsch(WIN(win), INUM(obj)) ? BOOL_F : BOOL_T;
- ASSERT(ICHRP(obj), obj, ARG2, s_winsch);
+ ASRTER(ICHRP(obj), obj, ARG2, s_winsch);
return ERR==winsch(WIN(win), ICHR(obj)) ? BOOL_F : BOOL_T;
}
@@ -222,15 +226,15 @@ SCM lbox(win, vertch, horch)
SCM win, vertch, horch;
{
int v, h;
- ASSERT(NIMP(win) && WINP(win), win, ARG1, s_box);
+ ASRTER(NIMP(win) && WINP(win), win, ARG1, s_box);
if INUMP(vertch) v = INUM(vertch);
else {
- ASSERT(ICHRP(vertch), vertch, ARG2, s_box);
+ ASRTER(ICHRP(vertch), vertch, ARG2, s_box);
v = ICHR(vertch);
}
if INUMP(horch) h = INUM(horch);
else {
- ASSERT(ICHRP(horch), horch, ARG3, s_box);
+ ASRTER(ICHRP(horch), horch, ARG3, s_box);
h = ICHR(horch);
}
return ERR==box(WIN(win), v, h) ? BOOL_F : BOOL_T;
@@ -241,7 +245,7 @@ SCM lgetyx(win)
SCM win;
{
int y, x;
- ASSERT(NIMP(win) && WINP(win), win, ARG1, s_getyx);
+ ASRTER(NIMP(win) && WINP(win), win, ARG1, s_getyx);
getyx(WIN(win), y, x);
return cons2(MAKINUM(y), MAKINUM(x), EOL);
}
@@ -249,14 +253,14 @@ SCM lgetyx(win)
SCM lwinch(win)
SCM win;
{
- ASSERT(NIMP(win) && WINP(win), win, ARG1, s_winch);
+ ASRTER(NIMP(win) && WINP(win), win, ARG1, s_winch);
return MAKICHR(winch(WIN(win)));
}
SCM lunctrl(c)
SCM c;
{
- ASSERT(ICHRP(c), c, ARG1, s_unctrl);
+ ASRTER(ICHRP(c), c, ARG1, s_unctrl);
{
char *str = unctrl(ICHR(c));
return makfrom0str(str);
@@ -268,7 +272,7 @@ SCM owidth(arg)
SCM arg;
{
if UNBNDP(arg) arg = cur_outp;
- ASSERT(NIMP(arg) && OPOUTPORTP(arg), arg, ARG1, s_owidth);
+ ASRTER(NIMP(arg) && OPOUTPORTP(arg), arg, ARG1, s_owidth);
if NIMP(*loc_stdscr)
if WINP(arg) return MAKINUM(WIN(arg)->_maxx+1);
else return MAKINUM(COLS);
@@ -278,7 +282,7 @@ SCM oheight(arg)
SCM arg;
{
if UNBNDP(arg) arg = cur_outp;
- ASSERT(NIMP(arg) && OPOUTPORTP(arg), arg, ARG1, s_owidth);
+ ASRTER(NIMP(arg) && OPOUTPORTP(arg), arg, ARG1, s_owidth);
if NIMP(*loc_stdscr)
if WINP(arg) return MAKINUM(WIN(arg)->_maxy+1);
else return MAKINUM(LINES);
@@ -322,7 +326,7 @@ static iproc subr0s[] = {
#define SUBRW(ln, n, s_n, sn) static char s_n[]=sn;\
SCM ln(w)SCM w;\
- {ASSERT(NIMP(w) && WINP(w), w, ARG1, sn);\
+ {ASRTER(NIMP(w) && WINP(w), w, ARG1, sn);\
return ERR==n(WIN(w))?BOOL_F:BOOL_T;}
SUBRW(lwerase, werase, s_werase, "werase")
@@ -356,7 +360,7 @@ static iproc subr1s[] = {
#define SUBROPT(ln, n, s_n, sn) static char s_n[]=sn;\
SCM ln(w, b)SCM w, b;\
- {ASSERT(NIMP(w) && WINP(w), w, ARG1, sn);\
+ {ASRTER(NIMP(w) && WINP(w), w, ARG1, sn);\
return ERR==n(WIN(w), BOOL_F != b)?BOOL_F:BOOL_T;}
SUBROPT(lidlok, idlok, s_idlok, "idlok")
@@ -369,7 +373,7 @@ static char s_clearok[] = "clearok";
SCM lclearok(w, b) SCM w, b;
{
if (BOOL_T==w) return ERR==clearok(curscr, BOOL_F != b)?BOOL_F:BOOL_T;
- ASSERT(NIMP(w) && WINP(w), w, ARG1, s_clearok);
+ ASRTER(NIMP(w) && WINP(w), w, ARG1, s_clearok);
return ERR==clearok(WIN(w), BOOL_F != b)?BOOL_F:BOOL_T;
}