|
|
385abae |
Description: <short summary of the patch>
|
|
|
385abae |
TODO: Put a short summary on the line above and replace this paragraph
|
|
|
385abae |
with a longer explanation of this change. Complete the meta-information
|
|
|
385abae |
with other relevant fields (see below for details). To make it easier, the
|
|
|
385abae |
information below has been extracted from the changelog. Adjust it or drop
|
|
|
385abae |
it.
|
|
|
385abae |
.
|
|
|
385abae |
gcl (2.6.12-56) unstable; urgency=medium
|
|
|
385abae |
.
|
|
|
385abae |
* list_order.12
|
|
|
385abae |
Author: Camm Maguire <camm@debian.org>
|
|
|
385abae |
|
|
|
385abae |
---
|
|
|
385abae |
The information above should follow the Patch Tagging Guidelines, please
|
|
|
385abae |
checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
|
|
|
385abae |
are templates for supplementary fields that you might want to add:
|
|
|
385abae |
|
|
|
385abae |
Origin: <vendor|upstream|other>, <url of original patch>
|
|
|
385abae |
Bug: <url in upstream bugtracker>
|
|
|
385abae |
Bug-Debian: https://bugs.debian.org/<bugnumber>
|
|
|
385abae |
Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
|
|
|
385abae |
Forwarded: <no|not-needed|url proving that it has been forwarded>
|
|
|
385abae |
Reviewed-By: <name and email of someone who approved the patch>
|
|
|
385abae |
Last-Update: 2017-08-25
|
|
|
385abae |
|
|
|
385abae |
--- gcl-2.6.12.orig/o/print.d
|
|
|
385abae |
+++ gcl-2.6.12/o/print.d
|
|
|
385abae |
@@ -702,18 +702,18 @@ print_symbol_name_body(object x) {
|
|
|
385abae |
#define FOUND -1
|
|
|
385abae |
|
|
|
385abae |
static int
|
|
|
385abae |
-write_sharp_eq(object *vp,bool dot) {
|
|
|
385abae |
+do_write_sharp_eq(object x,bool dot) {
|
|
|
385abae |
|
|
|
385abae |
- bool defined=vp[1]!=Cnil;
|
|
|
385abae |
+ bool defined=x->c.c_cdr!=Cnil;
|
|
|
385abae |
|
|
|
385abae |
if (dot) {
|
|
|
385abae |
write_str(" . ");
|
|
|
385abae |
if (!defined) return FOUND;
|
|
|
385abae |
}
|
|
|
385abae |
|
|
|
385abae |
- vp[1]=Ct;
|
|
|
385abae |
+ x->c.c_cdr=Ct;
|
|
|
385abae |
write_ch('#');
|
|
|
385abae |
- write_decimal((vp-PRINTvs_top)/2);
|
|
|
385abae |
+ write_decimal(fix(x->c.c_car));
|
|
|
385abae |
write_ch(defined ? '#' : '=');
|
|
|
385abae |
|
|
|
385abae |
return defined ? DONE : FOUND;
|
|
|
385abae |
@@ -721,15 +721,12 @@ write_sharp_eq(object *vp,bool dot) {
|
|
|
385abae |
}
|
|
|
385abae |
|
|
|
385abae |
static int
|
|
|
385abae |
-write_sharp_eqs(object x,bool dot) {
|
|
|
385abae |
+write_sharp_eq(object x,bool dot) {
|
|
|
385abae |
|
|
|
385abae |
- object *vp;
|
|
|
385abae |
+ struct htent *e;
|
|
|
385abae |
|
|
|
385abae |
- for (vp = PRINTvs_top; vp < PRINTvs_limit; vp += 2)
|
|
|
385abae |
- if (x == *vp)
|
|
|
385abae |
- return write_sharp_eq(vp,dot);
|
|
|
385abae |
-
|
|
|
385abae |
- return 0;
|
|
|
385abae |
+ return PRINTvs_top[0]!=Cnil && (e=gethash(x,PRINTvs_top[0]))->hte_key!=OBJNULL ?
|
|
|
385abae |
+ do_write_sharp_eq(e->hte_value,dot) : 0;
|
|
|
385abae |
|
|
|
385abae |
}
|
|
|
385abae |
|
|
|
385abae |
@@ -916,7 +913,7 @@ int level;
|
|
|
385abae |
if (PRINTescape) {
|
|
|
385abae |
if (x->s.s_hpack == Cnil) {
|
|
|
385abae |
if (PRINTcircle)
|
|
|
385abae |
- if (write_sharp_eqs(x,FALSE)==DONE) return;
|
|
|
385abae |
+ if (write_sharp_eq(x,FALSE)==DONE) return;
|
|
|
385abae |
if (PRINTgensym)
|
|
|
385abae |
write_str("#:");
|
|
|
385abae |
} else if (x->s.s_hpack == keyword_package) {
|
|
|
385abae |
@@ -952,7 +949,7 @@ int level;
|
|
|
385abae |
break;
|
|
|
385abae |
}
|
|
|
385abae |
if (PRINTcircle)
|
|
|
385abae |
- if (write_sharp_eqs(x,FALSE)==DONE) return;
|
|
|
385abae |
+ if (write_sharp_eq(x,FALSE)==DONE) return;
|
|
|
385abae |
if (PRINTlevel >= 0 && level >= PRINTlevel) {
|
|
|
385abae |
write_ch('#');
|
|
|
385abae |
break;
|
|
|
385abae |
@@ -1028,7 +1025,7 @@ int level;
|
|
|
385abae |
break;
|
|
|
385abae |
}
|
|
|
385abae |
if (PRINTcircle)
|
|
|
385abae |
- if (write_sharp_eqs(x,FALSE)==DONE) return;
|
|
|
385abae |
+ if (write_sharp_eq(x,FALSE)==DONE) return;
|
|
|
385abae |
if (PRINTlevel >= 0 && level >= PRINTlevel) {
|
|
|
385abae |
write_ch('#');
|
|
|
385abae |
break;
|
|
|
385abae |
@@ -1099,7 +1096,7 @@ int level;
|
|
|
385abae |
break;
|
|
|
385abae |
}
|
|
|
385abae |
if (PRINTcircle)
|
|
|
385abae |
- if (write_sharp_eqs(x,FALSE)==DONE) return;
|
|
|
385abae |
+ if (write_sharp_eq(x,FALSE)==DONE) return;
|
|
|
385abae |
if (PRINTpretty) {
|
|
|
385abae |
if (x->c.c_car == sLquote &&
|
|
|
385abae |
type_of(x->c.c_cdr) == t_cons &&
|
|
|
385abae |
@@ -1146,7 +1143,7 @@ int level;
|
|
|
385abae |
break;
|
|
|
385abae |
}
|
|
|
385abae |
if (PRINTcircle)
|
|
|
385abae |
- switch (write_sharp_eqs(x,TRUE)) {
|
|
|
385abae |
+ switch (write_sharp_eq(x,TRUE)) {
|
|
|
385abae |
case FOUND:
|
|
|
385abae |
write_object(x, level);
|
|
|
385abae |
case DONE:
|
|
|
385abae |
@@ -1316,7 +1313,7 @@ int level;
|
|
|
385abae |
|
|
|
385abae |
case t_structure:
|
|
|
385abae |
if (PRINTcircle)
|
|
|
385abae |
- if (write_sharp_eqs(x,FALSE)==DONE) return;
|
|
|
385abae |
+ if (write_sharp_eq(x,FALSE)==DONE) return;
|
|
|
385abae |
if (PRINTlevel >= 0 && level >= PRINTlevel) {
|
|
|
385abae |
write_ch('#');
|
|
|
385abae |
break;
|
|
|
385abae |
@@ -1415,7 +1412,6 @@ travel_push(object x) {
|
|
|
385abae |
|
|
|
385abae |
if (!travel_pushed(x)) {
|
|
|
385abae |
vs_check_push(x);
|
|
|
385abae |
- vs_check_push(Cnil);
|
|
|
385abae |
travel_pushed(x)=1;
|
|
|
385abae |
}
|
|
|
385abae |
|
|
|
385abae |
@@ -1519,10 +1515,13 @@ travel_clear(object x) {
|
|
|
385abae |
|
|
|
385abae |
}
|
|
|
385abae |
|
|
|
385abae |
+object sLeq;
|
|
|
385abae |
|
|
|
385abae |
static void
|
|
|
385abae |
setupPRINTcircle(object x,int dogensyms) {
|
|
|
385abae |
|
|
|
385abae |
+ object *xp;
|
|
|
385abae |
+
|
|
|
385abae |
BEGIN_NO_INTERRUPT;
|
|
|
385abae |
dgs=dogensyms;
|
|
|
385abae |
travel_push(x);
|
|
|
385abae |
@@ -1531,6 +1530,12 @@ setupPRINTcircle(object x,int dogensyms)
|
|
|
385abae |
travel_clear(x);
|
|
|
385abae |
END_NO_INTERRUPT;
|
|
|
385abae |
|
|
|
385abae |
+ vs_check_push(PRINTvs_limit>PRINTvs_top ? funcall_cfun(Lmake_hash_table,2,sKtest,sLeq) : Cnil);
|
|
|
385abae |
+ for (xp=PRINTvs_top;xp
|
|
|
385abae |
+ sethash(*xp,vs_head,MMcons(make_fixnum(xp-PRINTvs_top),Cnil));
|
|
|
385abae |
+ PRINTvs_top[0]=vs_head;
|
|
|
385abae |
+ PRINTvs_limit=vs_top=PRINTvs_top+1;
|
|
|
385abae |
+
|
|
|
385abae |
}
|
|
|
385abae |
|
|
|
385abae |
void
|