[uim-commit] r1335 - in branches/r5rs: sigscheme uim

kzk at freedesktop.org kzk at freedesktop.org
Fri Aug 26 07:53:14 PDT 2005


Author: kzk
Date: 2005-08-26 07:53:12 -0700 (Fri, 26 Aug 2005)
New Revision: 1335

Modified:
   branches/r5rs/sigscheme/datas.c
   branches/r5rs/sigscheme/io.c
   branches/r5rs/sigscheme/main.c
   branches/r5rs/sigscheme/operations-siod.c
   branches/r5rs/sigscheme/sigscheme.c
   branches/r5rs/sigscheme/sigscheme.h
   branches/r5rs/uim/uim-scm.c
Log:
* consistent function naming of SigScheme

* uim/uim-scm.c
* sigscheme/sigscheme.c
* sigscheme/io.c
* sigscheme/sigscheme.h
* sigscheme/operations-siod.c
* sigscheme/main.c
* sigscheme/datas.c
  - (SigScm_GC_Protect): renamed from SigScm_gc_protect
  - (SigScm_GC_ProtectStack): renamed from SigScm_gc_protect_stack
  - (SigScm_GC_UnprotectStack): renamed from SigScm_gc_unprotect_stack
  - (SigScm_GetVerboseLevel): renamed from SigScm_get_verbose_level
  - (SigScm_SetVerboseLevel): renamed from SigScm_set_verbose_level



Modified: branches/r5rs/sigscheme/datas.c
===================================================================
--- branches/r5rs/sigscheme/datas.c	2005-08-26 12:11:13 UTC (rev 1334)
+++ branches/r5rs/sigscheme/datas.c	2005-08-26 14:53:12 UTC (rev 1335)
@@ -42,7 +42,7 @@
  *       marking the Scheme object which are stored in the registers.
  *
  *   - gc_mark_protected_obj()
- *       marking the protected Scheme object which are protected by calling SigScm_gc_protect().
+ *       marking the protected Scheme object which are protected by calling SigScm_GC_Protect().
  *
  *   - gc_mark_locations()
  *       marking the Scheme object which are pushed to the stack, so we need to
@@ -368,7 +368,7 @@
     }
 }
 
-void SigScm_gc_protect(ScmObj obj)
+void SigScm_GC_Protect(ScmObj obj)
 {
     gc_protected_obj *item = (gc_protected_obj*)malloc(sizeof(gc_protected_obj));
     item->obj = obj;
@@ -566,13 +566,13 @@
     scm_freelist = scm_new_freelist;
 }
 
-void SigScm_gc_protect_stack(ScmObj *stack_start)
+void SigScm_GC_ProtectStack(ScmObj *stack_start)
 {
     if (!scm_stack_start_pointer)
         scm_stack_start_pointer = stack_start;
 }
 
-void SigScm_gc_unprotect_stack(ScmObj *stack_start)
+void SigScm_GC_UnprotectStack(ScmObj *stack_start)
 {
     if (scm_stack_start_pointer == stack_start)
         scm_stack_start_pointer = NULL;
@@ -911,7 +911,7 @@
     ScmObj ret = SCM_NULL;
 
     /* start protecting stack */
-    SigScm_gc_protect_stack(&stack_start);
+    SigScm_GC_ProtectStack(&stack_start);
 
     str_port = Scm_NewStringPort(exp);
 
@@ -923,7 +923,7 @@
 #endif
 
     /* now no need to protect stack */
-    SigScm_gc_unprotect_stack(&stack_start);
+    SigScm_GC_UnprotectStack(&stack_start);
 
     return ret;
 }

Modified: branches/r5rs/sigscheme/io.c
===================================================================
--- branches/r5rs/sigscheme/io.c	2005-08-26 12:11:13 UTC (rev 1334)
+++ branches/r5rs/sigscheme/io.c	2005-08-26 14:53:12 UTC (rev 1335)
@@ -446,7 +446,7 @@
     char  *filepath     = create_valid_path(filename);
 
     /* start protecting stack */
-    SigScm_gc_protect_stack(&stack_start);
+    SigScm_GC_ProtectStack(&stack_start);
 
     /* sanity check */
     /*
@@ -473,7 +473,7 @@
     ScmOp_close_input_port(port);
 
     /* now no need to protect stack */
-    SigScm_gc_unprotect_stack(&stack_start);
+    SigScm_GC_UnprotectStack(&stack_start);
 
     /* free str */
     free(filepath);
@@ -539,7 +539,7 @@
         SigScm_ErrorObj("require : string required but got ", filename);
 
     /* start protecting stack */
-    SigScm_gc_protect_stack(&stack_start);
+    SigScm_GC_ProtectStack(&stack_start);
 
     /* construct loaded_str */
     loaded_str = create_loaded_str(filename);
@@ -553,7 +553,7 @@
     }
 
     /* now no need to protect stack */
-    SigScm_gc_unprotect_stack(&stack_start);
+    SigScm_GC_UnprotectStack(&stack_start);
 
     return SCM_TRUE;
 }

Modified: branches/r5rs/sigscheme/main.c
===================================================================
--- branches/r5rs/sigscheme/main.c	2005-08-26 12:11:13 UTC (rev 1334)
+++ branches/r5rs/sigscheme/main.c	2005-08-26 14:53:12 UTC (rev 1335)
@@ -64,7 +64,7 @@
     ScmObj result = SCM_NULL;
 
     /* start protecting stack */
-    SigScm_gc_protect_stack(&stack_start);
+    SigScm_GC_ProtectStack(&stack_start);
 
     /* init variable */
     stdin_port  = Scm_NewFilePort(stdin,  "stdin",  PORT_INPUT);
@@ -85,7 +85,7 @@
     ScmOp_close_input_port(stdout_port);
 
     /* now no need to protect stack */
-    SigScm_gc_unprotect_stack(&stack_start);
+    SigScm_GC_UnprotectStack(&stack_start);
 }
 
 /*=======================================

Modified: branches/r5rs/sigscheme/operations-siod.c
===================================================================
--- branches/r5rs/sigscheme/operations-siod.c	2005-08-26 12:11:13 UTC (rev 1334)
+++ branches/r5rs/sigscheme/operations-siod.c	2005-08-26 14:53:12 UTC (rev 1335)
@@ -157,12 +157,12 @@
     return Scm_NewInt(sscm_verbose_level);
 }
 
-long SigScm_get_verbose_level(void)
+long SigScm_GetVerboseLevel(void)
 {
     return sscm_verbose_level;
 }
 
-void SigScm_set_verbose_level(long level)
+void SigScm_SetVerboseLevel(long level)
 {
     sscm_verbose_level = level;
 }

Modified: branches/r5rs/sigscheme/sigscheme.c
===================================================================
--- branches/r5rs/sigscheme/sigscheme.c	2005-08-26 12:11:13 UTC (rev 1334)
+++ branches/r5rs/sigscheme/sigscheme.c	2005-08-26 14:53:12 UTC (rev 1335)
@@ -75,7 +75,7 @@
 void SigScm_Initialize(void)
 {
     ScmObj obj;
-    SigScm_gc_protect_stack(&obj);
+    SigScm_GC_ProtectStack(&obj);
 
     /*=======================================================================
       Etc Variable Initialization
@@ -297,11 +297,11 @@
       Current Input & Output Initialization
     =======================================================================*/
     scm_current_input_port  = Scm_NewFilePort(stdin,  "stdin",  PORT_INPUT);
-    SigScm_gc_protect(scm_current_input_port);
     scm_current_output_port = Scm_NewFilePort(stdout, "stdout", PORT_OUTPUT);
-    SigScm_gc_protect(scm_current_output_port);
     scm_current_error_port  = Scm_NewFilePort(stderr, "stderr", PORT_OUTPUT);
-    SigScm_gc_protect(scm_current_error_port);
+    SigScm_GC_Protect(scm_current_input_port);
+    SigScm_GC_Protect(scm_current_output_port);
+    SigScm_GC_Protect(scm_current_error_port);
 
 #if SCM_USE_SRFI1
     /*=======================================================================
@@ -341,7 +341,7 @@
     scm_return_value = SCM_NULL;
 #endif
 
-    SigScm_gc_unprotect_stack(&obj);
+    SigScm_GC_UnprotectStack(&obj);
 }
 
 void SigScm_Finalize()

Modified: branches/r5rs/sigscheme/sigscheme.h
===================================================================
--- branches/r5rs/sigscheme/sigscheme.h	2005-08-26 12:11:13 UTC (rev 1334)
+++ branches/r5rs/sigscheme/sigscheme.h	2005-08-26 14:53:12 UTC (rev 1335)
@@ -97,9 +97,9 @@
 /* datas.c */
 void   SigScm_InitStorage(void);
 void   SigScm_FinalizeStorage(void);
-void   SigScm_gc_protect(ScmObj obj);
-void   SigScm_gc_protect_stack(ScmObj *stack_start);
-void   SigScm_gc_unprotect_stack(ScmObj *stack_start);
+void   SigScm_GC_Protect(ScmObj obj);
+void   SigScm_GC_ProtectStack(ScmObj *stack_start);
+void   SigScm_GC_UnprotectStack(ScmObj *stack_start);
 ScmObj Scm_NewCons(ScmObj a, ScmObj b);
 ScmObj Scm_NewInt(int val);
 ScmObj Scm_NewSymbol(char *name, ScmObj v_cell);
@@ -362,8 +362,8 @@
 ScmObj ScmOp_the_environment(ScmObj arg, ScmObj env);
 ScmObj ScmOp_closure_code(ScmObj closure);
 ScmObj ScmOp_verbose(ScmObj args, ScmObj env);
-long   SigScm_get_verbose_level(void);
-void   SigScm_set_verbose_level(long level);
+long   SigScm_GetVerboseLevel(void);
+void   SigScm_SetVerboseLevel(long level);
 #endif
 
 #ifdef __cplusplus

Modified: branches/r5rs/uim/uim-scm.c
===================================================================
--- branches/r5rs/uim/uim-scm.c	2005-08-26 12:11:13 UTC (rev 1334)
+++ branches/r5rs/uim/uim-scm.c	2005-08-26 14:53:12 UTC (rev 1335)
@@ -170,19 +170,19 @@
 void
 uim_scm_gc_protect(uim_lisp *location)
 {
-  SigScm_gc_protect((ScmObj)(*location));
+  SigScm_GC_Protect((ScmObj)(*location));
 }
 
 void
 uim_scm_gc_protect_stack(uim_lisp *stack_start)
 {
-  SigScm_gc_protect_stack((ScmObj*)stack_start);
+  SigScm_GC_ProtectStack((ScmObj*)stack_start);
 }
 
 void
 uim_scm_gc_unprotect_stack(uim_lisp *stack_start)
 {
-  SigScm_gc_unprotect_stack((ScmObj*)stack_start);
+  SigScm_GC_UnprotectStack((ScmObj*)stack_start);
 }
 
 uim_bool
@@ -194,13 +194,13 @@
 long
 uim_scm_get_verbose_level(void)
 {
-  return (long)SigScm_get_verbose_level();
+  return (long)SigScm_GetVerboseLevel();
 }
 
 void
 uim_scm_set_verbose_level(long new_value)
 {
-  SigScm_set_verbose_level(new_value);
+  SigScm_SetVerboseLevel(new_value);
 }
 
 void



More information about the uim-commit mailing list