Author: yamakenz
Date: Sat Apr 26 13:19:48 2008
New Revision: 5443

Modified:
  branches/sigscheme-0.8/NEWS
  branches/sigscheme-0.8/RELNOTE
  branches/sigscheme-0.8/configure.in
  branches/sigscheme-0.8/make-dist.sh
  branches/sigscheme-0.8/src/sigscheme.h
  branches/sigscheme-0.8/test-c/test-format.c
  branches/sigscheme-0.8/test-c/test-gc-protect.c
  branches/sigscheme-0.8/test-c/test-storage.c
  branches/sigscheme-0.8/test/test-sscm-ext.scm

Log:
* Merge r5440-5442 from trunk


Modified: branches/sigscheme-0.8/NEWS
==============================================================================
--- branches/sigscheme-0.8/NEWS (original)
+++ branches/sigscheme-0.8/NEWS Sat Apr 26 13:19:48 2008
@@ -1,3 +1,15 @@
+Overview of changes from 0.8.2 to 0.8.3
+=======================================
+
+* Fixes
+
+  - Disable some GC protection tests that produce indifinite result on make
+    check
+  - Re-enable following unintentionally disabled tests
+    * test-format.c
+    * test-storage.c
+
+
Overview of changes from 0.8.1 to 0.8.2
=======================================

@@ -9,7 +21,7 @@
* Fixes

- Fix bogus result of 'make check'. 0.8.1 and earlier passes all tests even
-    if sme tests are failed
+    if some tests are failed


Overview of changes from 0.8.0 to 0.8.1

Modified: branches/sigscheme-0.8/RELNOTE
==============================================================================
--- branches/sigscheme-0.8/RELNOTE      (original)
+++ branches/sigscheme-0.8/RELNOTE      Sat Apr 26 13:19:48 2008
@@ -1,4 +1,4 @@
-SigScheme 0.8.2 Release Note
+SigScheme 0.8.3 Release Note
============================

What's SigScheme
@@ -19,7 +19,7 @@
About This Release
------------------

-This distribution of SigScheme 0.8.2 is latest stable release of the
+This distribution of SigScheme 0.8.3 is latest stable release of the
software. And this release will be adopted for uim 1.5.0, the primary
application of SigScheme.


Modified: branches/sigscheme-0.8/configure.in
==============================================================================
--- branches/sigscheme-0.8/configure.in (original)
+++ branches/sigscheme-0.8/configure.in Sat Apr 26 13:19:48 2008
@@ -1,5 +1,5 @@
AC_PREREQ(2.60b)
-AC_INIT([SigScheme], [0.8.2], [EMAIL PROTECTED], [sigscheme])
+AC_INIT([SigScheme], [0.8.3], [EMAIL PROTECTED], [sigscheme])
AC_CONFIG_SRCDIR([src/sigscheme.c])
AC_CONFIG_HEADERS([src/config.h])
AM_INIT_AUTOMAKE([1.10 dist-bzip2])

Modified: branches/sigscheme-0.8/make-dist.sh
==============================================================================
--- branches/sigscheme-0.8/make-dist.sh (original)
+++ branches/sigscheme-0.8/make-dist.sh Sat Apr 26 13:19:48 2008
@@ -5,7 +5,7 @@
UIM_REPOSITORY="http://uim.googlecode.com/svn";
TAGS_REPOSITORY="${UIM_REPOSITORY}/tags"
#SSCM_REPOSITORY="${UIM_REPOSITORY}/sigscheme-trunk"
-SSCM_REPOSITORY="${TAGS_REPOSITORY}/sigscheme-0.8.2"
+SSCM_REPOSITORY="${TAGS_REPOSITORY}/sigscheme-0.8.3"
#LIBGCROOTS_URL="${UIM_REPOSITORY}/libgcroots-trunk"
LIBGCROOTS_URL="${TAGS_REPOSITORY}/libgcroots-0.2.1"


Modified: branches/sigscheme-0.8/src/sigscheme.h
==============================================================================
--- branches/sigscheme-0.8/src/sigscheme.h      (original)
+++ branches/sigscheme-0.8/src/sigscheme.h      Sat Apr 26 13:19:48 2008
@@ -65,10 +65,10 @@
/*=======================================
  Macro Definitions
=======================================*/
-#define SSCM_VERSION_STRING     "0.8.2"
+#define SSCM_VERSION_STRING     "0.8.3"
#define SSCM_VERSION_MAJOR      (0)
#define SSCM_VERSION_MINOR      (8)
-#define SSCM_VERSION_PATCHLEVEL (2)
+#define SSCM_VERSION_PATCHLEVEL (3)
#define SSCM_VERSION_REQUIRE(major, minor, patchlevel)                       \
  ((major) < SSCM_VERSION_MAJOR                                                 
  \
|| ((major) == SSCM_VERSION_MAJOR && (minor) < SSCM_VERSION_MINOR) \

Modified: branches/sigscheme-0.8/test-c/test-format.c
==============================================================================
--- branches/sigscheme-0.8/test-c/test-format.c (original)
+++ branches/sigscheme-0.8/test-c/test-format.c Sat Apr 26 13:19:48 2008
@@ -37,6 +37,7 @@
#include <stdarg.h>
#include <string.h>

+#include <sigscheme/config.h>
#if (!SCM_USE_CHAR || !SCM_USE_STRING || !SCM_USE_INT)
#define TST_EXCLUDE_THIS
#endif
@@ -105,7 +106,7 @@
{
    tst_suite_info suite = TST_DEFAULT_SUITE_SETUP;

-    scm_initialize(NULL);
+    scm_initialize(NULL, NULL);

    scm_gc_protect_with_init(&lst,
                             LIST_5(SCM_TRUE,

Modified: branches/sigscheme-0.8/test-c/test-gc-protect.c
==============================================================================
--- branches/sigscheme-0.8/test-c/test-gc-protect.c     (original)
+++ branches/sigscheme-0.8/test-c/test-gc-protect.c     Sat Apr 26 13:19:48 2008
@@ -38,6 +38,12 @@
#include "sigscheme.h"
#include "sigschemeinternal.h"

+/* Due to the conservative GC algorithm, an object cannot be detected as "this
+ * object is NOT protected", although "IS protected" can. But since testing
+ * such uncertain unprotected objects helps GC debugging, this file try such
+ * tests iff --enable-debug is specified although they may fail.
+ *   -- YamaKen 2008-04-27 */
+#define TRY_TESTS_THAT_PASS_IN_MOST_CASES SCM_DEBUG

static ScmObj make_obj(void);
static void *make_obj_internal(void *dummy);
@@ -85,9 +91,13 @@
{
    TST_TN_FALSE(scm_gc_protected_contextp());

+#if TRY_TESTS_THAT_PASS_IN_MOST_CASES
    TST_TN_FALSE(var_in_protected_func(NULL));
+#endif
    TST_TN_TRUE (scm_call_with_gc_ready_stack(var_in_protected_func, NULL));
+#if TRY_TESTS_THAT_PASS_IN_MOST_CASES
    TST_TN_FALSE(var_in_protected_func(NULL));
+#endif
}

static void *
@@ -103,9 +113,13 @@
{
    TST_TN_FALSE(scm_gc_protected_contextp());

+#if TRY_TESTS_THAT_PASS_IN_MOST_CASES
    TST_TN_FALSE(vars_in_protected_func(NULL));
+#endif
    TST_TN_TRUE (scm_call_with_gc_ready_stack(vars_in_protected_func, NULL));
+#if TRY_TESTS_THAT_PASS_IN_MOST_CASES
    TST_TN_FALSE(vars_in_protected_func(NULL));
+#endif
}

static void *
@@ -129,11 +143,13 @@

    TST_TN_FALSE(scm_gc_protected_contextp());

+#if TRY_TESTS_THAT_PASS_IN_MOST_CASES
    /* unprotected */
    for (i = 0; i < N_OBJS; i++)
        static_objs[i] = make_obj();
    for (i = 0; i < N_OBJS; i++)
        TST_TN_FALSE(scm_gc_protectedp(static_objs[i]));
+#endif

    /* protected */
    for (i = 0; i < N_OBJS; i++) {
@@ -143,11 +159,13 @@
    for (i = 0; i < N_OBJS; i++)
        TST_TN_TRUE(scm_gc_protectedp(static_objs[i]));

+#if TRY_TESTS_THAT_PASS_IN_MOST_CASES
    /* unprotect again */
    for (i = 0; i < N_OBJS; i++)
        scm_gc_unprotect(&static_objs[i]);
    for (i = 0; i < N_OBJS; i++)
        TST_TN_FALSE(scm_gc_protectedp(static_objs[i]));
+#endif
}

TST_CASE("GC auto variable protection with scm_gc_protect()")
@@ -157,11 +175,13 @@

    TST_TN_FALSE(scm_gc_protected_contextp());

+#if TRY_TESTS_THAT_PASS_IN_MOST_CASES
    /* unprotected */
    for (i = 0; i < N_OBJS; i++)
        auto_objs[i] = make_obj();
    for (i = 0; i < N_OBJS; i++)
        TST_TN_FALSE(scm_gc_protectedp(auto_objs[i]));
+#endif

    /* protected */
    for (i = 0; i < N_OBJS; i++) {
@@ -171,11 +191,13 @@
    for (i = 0; i < N_OBJS; i++)
        TST_TN_TRUE(scm_gc_protectedp(auto_objs[i]));

+#if TRY_TESTS_THAT_PASS_IN_MOST_CASES
    /* unprotect again */
    for (i = 0; i < N_OBJS; i++)
        scm_gc_unprotect(&auto_objs[i]);
    for (i = 0; i < N_OBJS; i++)
        TST_TN_FALSE(scm_gc_protectedp(auto_objs[i]));
+#endif
}

static void *
@@ -210,6 +232,7 @@

TST_TN_TRUE (scm_call_with_gc_ready_stack(test_implicit_protection, NULL));

+#if TRY_TESTS_THAT_PASS_IN_MOST_CASES
    /* unprotected lst */
    lst = LIST_2(SCM_FALSE, SCM_FALSE);
    unprotected_lst = CDR(lst);
@@ -227,6 +250,7 @@
    TST_TN_FALSE(scm_gc_protectedp(unprotected_lst));
    lst = SCM_FALSE;
    TST_TN_FALSE(scm_gc_protectedp(unprotected_lst));
+#endif

    /* protected static lst */
    scm_gc_protect(&protected_lst);
@@ -236,5 +260,7 @@
    TST_TN_TRUE (scm_gc_protectedp(protected_lst));
    TST_TN_TRUE (scm_gc_protectedp(unprotected_lst));
    protected_lst = SCM_FALSE;
+#if TRY_TESTS_THAT_PASS_IN_MOST_CASES
    TST_TN_FALSE(scm_gc_protectedp(unprotected_lst));
+#endif
}

Modified: branches/sigscheme-0.8/test-c/test-storage.c
==============================================================================
--- branches/sigscheme-0.8/test-c/test-storage.c        (original)
+++ branches/sigscheme-0.8/test-c/test-storage.c        Sat Apr 26 13:19:48 2008
@@ -37,6 +37,7 @@
#include <stdio.h>
#include <stdlib.h>

+#include <sigscheme/config.h>
#if (!SCM_USE_CHAR || !SCM_USE_VECTOR)
#define TST_EXCLUDE_THIS
#endif
@@ -417,13 +418,13 @@
}
#endif /* use sscm extension mechanism */

-#if SCM_USE_HYGIENIC_MACRO
#if SCM_USE_UNHYGIENIC_MACRO
#error "No test implemented."
#endif

TST_CASE("subpat")
{
+#if SCM_USE_HYGIENIC_MACRO
    ScmObj obj;
#define SUBPAT_TST(tst, pat, meta)              \
    tst(obj, SUBPAT,                            \
@@ -432,10 +433,12 @@

    SUBPAT_TST(TST_INIT2, LIST_1(SCM_NULL), -1);
    SUBPAT_TST(TST_SET2, SCM_NULL, 5);
+#endif /* SCM_USE_HYGIENIC_MACRO */
}

TST_CASE("far symbol")
{
+#if SCM_USE_HYGIENIC_MACRO
    ScmObj obj;
#if SCM_USE_UNHYGIENIC_MACRO
#error "Packed env handling must be revised."
@@ -453,10 +456,12 @@
    FARSYMBOL_TST(TST_INIT2, SCM_SYM_QUOTE, null);
    FARSYMBOL_TST(TST_SET2, SCM_MAKE_FARSYMBOL(SCM_SYM_QUOTE, null),
                  scm_pack_env(env));
+#endif /* SCM_USE_HYGIENIC_MACRO */
}

TST_CASE(hmacro, "hmacro")
{
+#if SCM_USE_HYGIENIC_MACRO
    ScmObj obj;
    ScmObj env, rules;

@@ -487,7 +492,7 @@
    SCM_HMACRO_SET_ENV(obj, scm_pack_env(env));
    HMACRO_TST(TST2, rules, scm_pack_env(env),
               "after SET_ENV");
+#endif /* SCM_USE_HYGIENIC_MACRO */
}

-#endif /* use hygienic macro */
#endif /* !TST_EXCLUDE_THIS */

Modified: branches/sigscheme-0.8/test/test-sscm-ext.scm
==============================================================================
--- branches/sigscheme-0.8/test/test-sscm-ext.scm       (original)
+++ branches/sigscheme-0.8/test/test-sscm-ext.scm       Sat Apr 26 13:19:48 2008
@@ -43,7 +43,7 @@
(define ud (undef))

(tn "sscm-version")
-(assert-equal? (tn) "0.8.2"      (sscm-version))
+(assert-equal? (tn) "0.8.3"      (sscm-version))

(tn "%%current-char-codec")
(assert-equal? (tn) "UTF-8"      (%%current-char-codec))

Reply via email to