[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Guile-commits] GNU Guile branch, stable-2.0, updated. v2.0.3-174-g73c08
From: |
Ludovic Courtès |
Subject: |
[Guile-commits] GNU Guile branch, stable-2.0, updated. v2.0.3-174-g73c080f |
Date: |
Sun, 22 Jan 2012 23:44:38 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Guile".
http://git.savannah.gnu.org/cgit/guile.git/commit/?id=73c080f9c07a8eed713c0e62bdbdce31ac5bbf86
The branch, stable-2.0 has been updated
via 73c080f9c07a8eed713c0e62bdbdce31ac5bbf86 (commit)
from fb8b2a9d6006077700e84b24d824180d2a433e1c (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 73c080f9c07a8eed713c0e62bdbdce31ac5bbf86
Author: Ludovic Courtès <address@hidden>
Date: Mon Jan 23 00:44:29 2012 +0100
Adjust tests that relied on the output of the hash table printer.
* libguile/hashtab.c (scm_i_hashtable_print): Use `SCM_UNPACK', not
`SCM2PTR'.
* test-suite/tests/hash.test: Adjust tests that rely on the output of
the printer to just check for the suffix of the hash table's external
representation.
-----------------------------------------------------------------------
Summary of changes:
libguile/hashtab.c | 2 +-
test-suite/tests/hash.test | 19 +++++++++++--------
2 files changed, 12 insertions(+), 9 deletions(-)
diff --git a/libguile/hashtab.c b/libguile/hashtab.c
index 1b02d4b..f337ebf 100644
--- a/libguile/hashtab.c
+++ b/libguile/hashtab.c
@@ -395,7 +395,7 @@ scm_i_hashtable_print (SCM exp, SCM port, scm_print_state
*pstate)
else if (SCM_HASHTABLE_DOUBLY_WEAK_P (exp))
scm_puts ("doubly-weak-", port);
scm_puts ("hash-table ", port);
- scm_uintprint (SCM2PTR (exp), 16, port);
+ scm_uintprint (SCM_UNPACK (exp), 16, port);
scm_putc (' ', port);
scm_uintprint (SCM_HASHTABLE_N_ITEMS (exp), 10, port);
scm_putc ('/', port);
diff --git a/test-suite/tests/hash.test b/test-suite/tests/hash.test
index f3d603d..bcdfe91 100644
--- a/test-suite/tests/hash.test
+++ b/test-suite/tests/hash.test
@@ -1,6 +1,6 @@
;;;; hash.test --- test guile hashing -*- scheme -*-
;;;;
-;;;; Copyright (C) 2004, 2005, 2006, 2008, 2011 Free Software Foundation, Inc.
+;;;; Copyright (C) 2004, 2005, 2006, 2008, 2011, 2012 Free Software
Foundation, Inc.
;;;;
;;;; This library is free software; you can redistribute it and/or
;;;; modify it under the terms of the GNU Lesser General Public
@@ -75,9 +75,10 @@
(make-hash-table -1))
(pass-if (hash-table? (make-hash-table 0))) ;; default
(pass-if (not (hash-table? 'not-a-hash-table)))
- (pass-if (equal? "#<hash-table 0/113>"
- (with-output-to-string
- (lambda () (write (make-hash-table 100)))))))
+ (pass-if (string-suffix? " 0/113>"
+ (with-output-to-string
+ (lambda ()
+ (write (make-hash-table 100)))))))
;;;
;;; usual set and reference
@@ -129,8 +130,9 @@
(equal? 'thirty (hash-ref table 30))
(equal? 'thirty-three (hash-ref table 33))
(equal? 'bar (hash-ref table 'foo))
- (equal? "#<hash-table 36/61>"
- (with-output-to-string (lambda () (write table)))))))
+ (string-suffix? " 36/61>"
+ (with-output-to-string
+ (lambda () (write table)))))))
;; 1 and 1 are equal? and eqv? and eq?
(pass-if (equal? 'foo
@@ -240,8 +242,9 @@
(pass-if (equal? 'equal (hashx-ref hash assoc table 2/64)))
(pass-if (equal? 'equal (hashx-ref hash assoc table 2/66)))
(pass-if (equal? 'equal (hashx-ref hash assoc table 34)))
- (pass-if (equal? "#<hash-table 33/61>"
- (with-output-to-string (lambda () (write table)))))))
+ (pass-if (string-suffix? " 33/61>"
+ (with-output-to-string
+ (lambda () (write table)))))))
(with-test-prefix
"hashx"
hooks/post-receive
--
GNU Guile
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Guile-commits] GNU Guile branch, stable-2.0, updated. v2.0.3-174-g73c080f,
Ludovic Courtès <=