/[gcl]/gcl/o/list.d
ViewVC logotype

Diff of /gcl/o/list.d

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.6 by camm, Tue Aug 20 05:42:47 2002 UTC revision 1.7 by camm, Tue Aug 20 23:23:57 2002 UTC
# Line 1283  void Lrassoc() { car_or_cdr = cdr; Lasso Line 1283  void Lrassoc() { car_or_cdr = cdr; Lasso
1283    
1284  static bool true_or_false;  static bool true_or_false;
1285    
1286  @(defun assoc_or_rassoc_predicate (predicate a_list)  @(defun assoc_or_rassoc_predicate (predicate a_list &key key)
1287          object endp_temp;          object endp_temp;
1288            object x;
1289  @  @
1290          while (!endp(a_list)) {          while (!endp(a_list)) {
1291                  if ((ifuncall1(predicate,                  if (a_list->c.c_car==Cnil)
1292                                 (*car_or_cdr)(a_list->c.c_car)) != Cnil)                          continue;
1293                      == true_or_false) {                  x=(*car_or_cdr)(a_list->c.c_car);
1294                    if (key!=Cnil)
1295                            x=ifuncall1(key,x);
1296                    if ((ifuncall1(predicate,x) != Cnil) == true_or_false)
1297                          @(return `a_list->c.c_car`)                          @(return `a_list->c.c_car`)
                 }  
1298                  a_list = a_list->c.c_cdr;                  a_list = a_list->c.c_cdr;
1299          }          }
1300          @(return a_list)          @(return a_list)

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.7

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26