lucy-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nwelln...@apache.org
Subject [lucy-commits] [15/15] git commit: refs/heads/cfish-string-prep1 - Rename Str_Immutable_Cat to Str_Cat
Date Mon, 02 Sep 2013 19:16:46 GMT
Rename Str_Immutable_Cat to Str_Cat


Project: http://git-wip-us.apache.org/repos/asf/lucy/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy/commit/56fb0e1d
Tree: http://git-wip-us.apache.org/repos/asf/lucy/tree/56fb0e1d
Diff: http://git-wip-us.apache.org/repos/asf/lucy/diff/56fb0e1d

Branch: refs/heads/cfish-string-prep1
Commit: 56fb0e1dd764f960c7c60a4a235e77e406394540
Parents: 3948f78
Author: Nick Wellnhofer <wellnhofer@aevum.de>
Authored: Mon Sep 2 21:15:19 2013 +0200
Committer: Nick Wellnhofer <wellnhofer@aevum.de>
Committed: Mon Sep 2 21:15:19 2013 +0200

----------------------------------------------------------------------
 clownfish/runtime/core/Clownfish/Err.c             |  2 +-
 clownfish/runtime/core/Clownfish/String.c          | 10 +++++-----
 clownfish/runtime/core/Clownfish/String.cfh        |  6 +++---
 clownfish/runtime/core/Clownfish/Test/TestString.c |  6 +++---
 core/Lucy/Index/BackgroundMerger.c                 |  2 +-
 core/Lucy/Index/Indexer.c                          |  2 +-
 6 files changed, 14 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy/blob/56fb0e1d/clownfish/runtime/core/Clownfish/Err.c
----------------------------------------------------------------------
diff --git a/clownfish/runtime/core/Clownfish/Err.c b/clownfish/runtime/core/Clownfish/Err.c
index 6d58301..92050cc 100644
--- a/clownfish/runtime/core/Clownfish/Err.c
+++ b/clownfish/runtime/core/Clownfish/Err.c
@@ -58,7 +58,7 @@ Err_To_String_IMP(Err *self) {
 
 void
 Err_Cat_Mess_IMP(Err *self, const String *mess) {
-    String *new_mess = Str_Immutable_Cat(self->mess, mess);
+    String *new_mess = Str_Cat(self->mess, mess);
     DECREF(self->mess);
     self->mess = new_mess;
 }

http://git-wip-us.apache.org/repos/asf/lucy/blob/56fb0e1d/clownfish/runtime/core/Clownfish/String.c
----------------------------------------------------------------------
diff --git a/clownfish/runtime/core/Clownfish/String.c b/clownfish/runtime/core/Clownfish/String.c
index 499c79e..07da5d8 100644
--- a/clownfish/runtime/core/Clownfish/String.c
+++ b/clownfish/runtime/core/Clownfish/String.c
@@ -321,20 +321,20 @@ Str_Mimic_IMP(String *self, Obj *other) {
 }
 
 String*
-Str_Immutable_Cat_IMP(String *self, const String *other) {
-    return Str_Immutable_Cat_Trusted_UTF8(self, other->ptr, other->size);
+Str_Cat_IMP(String *self, const String *other) {
+    return Str_Cat_Trusted_UTF8(self, other->ptr, other->size);
 }
 
 String*
-Str_Immutable_Cat_UTF8_IMP(String *self, const char* ptr, size_t size) {
+Str_Cat_UTF8_IMP(String *self, const char* ptr, size_t size) {
     if (!StrHelp_utf8_valid(ptr, size)) {
         DIE_INVALID_UTF8(ptr, size);
     }
-    return Str_Immutable_Cat_Trusted_UTF8(self, ptr, size);
+    return Str_Cat_Trusted_UTF8(self, ptr, size);
 }
 
 String*
-Str_Immutable_Cat_Trusted_UTF8_IMP(String *self, const char* ptr, size_t size) {
+Str_Cat_Trusted_UTF8_IMP(String *self, const char* ptr, size_t size) {
     size_t  result_size = self->size + size;
     char   *result_ptr  = (char*)MALLOCATE(result_size + 1);
     memcpy(result_ptr, self->ptr, self->size);

http://git-wip-us.apache.org/repos/asf/lucy/blob/56fb0e1d/clownfish/runtime/core/Clownfish/String.cfh
----------------------------------------------------------------------
diff --git a/clownfish/runtime/core/Clownfish/String.cfh b/clownfish/runtime/core/Clownfish/String.cfh
index edc52e3..f56b26c 100644
--- a/clownfish/runtime/core/Clownfish/String.cfh
+++ b/clownfish/runtime/core/Clownfish/String.cfh
@@ -106,18 +106,18 @@ class Clownfish::String cnick Str
     /** Return the concatenation of the String and <code>other</code>.
      */
     incremented String*
-    Immutable_Cat(String *self, const String *other);
+    Cat(String *self, const String *other);
 
     /** Return the concatenation of the String and the passed-in raw UTF-8.
      */
     incremented String*
-    Immutable_Cat_UTF8(String *self, const char *ptr, size_t size);
+    Cat_UTF8(String *self, const char *ptr, size_t size);
 
     /** Return the concatenation of the String and the passed-in raw UTF-8.
      * Don't check for UTF-8 validity.
      */
     incremented String*
-    Immutable_Cat_Trusted_UTF8(String *self, const char *ptr, size_t size);
+    Cat_Trusted_UTF8(String *self, const char *ptr, size_t size);
 
     /** Replace all instances of one character for the other.  For now, both
      * the source and replacement code points must be ASCII.

http://git-wip-us.apache.org/repos/asf/lucy/blob/56fb0e1d/clownfish/runtime/core/Clownfish/Test/TestString.c
----------------------------------------------------------------------
diff --git a/clownfish/runtime/core/Clownfish/Test/TestString.c b/clownfish/runtime/core/Clownfish/Test/TestString.c
index cfc2968..5f8337c 100644
--- a/clownfish/runtime/core/Clownfish/Test/TestString.c
+++ b/clownfish/runtime/core/Clownfish/Test/TestString.c
@@ -53,19 +53,19 @@ test_Cat(TestBatchRunner *runner) {
     String *got;
 
     source = S_get_str("");
-    got = Str_Immutable_Cat(source, wanted);
+    got = Str_Cat(source, wanted);
     TEST_TRUE(runner, Str_Equals(wanted, (Obj*)got), "Cat");
     DECREF(got);
     DECREF(source);
 
     source = S_get_str("a");
-    got = Str_Immutable_Cat_UTF8(source, smiley, smiley_len);
+    got = Str_Cat_UTF8(source, smiley, smiley_len);
     TEST_TRUE(runner, Str_Equals(wanted, (Obj*)got), "Cat_UTF8");
     DECREF(got);
     DECREF(source);
 
     source = S_get_str("a");
-    got = Str_Immutable_Cat_Trusted_UTF8(source, smiley, smiley_len);
+    got = Str_Cat_Trusted_UTF8(source, smiley, smiley_len);
     TEST_TRUE(runner, Str_Equals(wanted, (Obj*)got), "Cat_Trusted_UTF8");
     DECREF(got);
     DECREF(source);

http://git-wip-us.apache.org/repos/asf/lucy/blob/56fb0e1d/core/Lucy/Index/BackgroundMerger.c
----------------------------------------------------------------------
diff --git a/core/Lucy/Index/BackgroundMerger.c b/core/Lucy/Index/BackgroundMerger.c
index 85ca89c..45bd39d 100644
--- a/core/Lucy/Index/BackgroundMerger.c
+++ b/core/Lucy/Index/BackgroundMerger.c
@@ -413,7 +413,7 @@ BGMerger_Prepare_Commit_IMP(BackgroundMerger *self) {
         // Write temporary snapshot file.
         DECREF(ivars->snapfile);
         String *snapfile = IxManager_Make_Snapshot_Filename(ivars->manager);
-        ivars->snapfile = Str_Immutable_Cat_Trusted_UTF8(snapfile, ".temp", 5);
+        ivars->snapfile = Str_Cat_Trusted_UTF8(snapfile, ".temp", 5);
         DECREF(snapfile);
         Folder_Delete(folder, ivars->snapfile);
         Snapshot_Write_File(snapshot, folder, ivars->snapfile);

http://git-wip-us.apache.org/repos/asf/lucy/blob/56fb0e1d/core/Lucy/Index/Indexer.c
----------------------------------------------------------------------
diff --git a/core/Lucy/Index/Indexer.c b/core/Lucy/Index/Indexer.c
index a564049..815e7b4 100644
--- a/core/Lucy/Index/Indexer.c
+++ b/core/Lucy/Index/Indexer.c
@@ -508,7 +508,7 @@ Indexer_Prepare_Commit_IMP(Indexer *self) {
         // Derive snapshot and schema file names.
         DECREF(ivars->snapfile);
         String *snapfile = IxManager_Make_Snapshot_Filename(ivars->manager);
-        ivars->snapfile = Str_Immutable_Cat_Trusted_UTF8(snapfile, ".temp", 5);
+        ivars->snapfile = Str_Cat_Trusted_UTF8(snapfile, ".temp", 5);
         DECREF(snapfile);
         uint64_t schema_gen = IxFileNames_extract_gen(ivars->snapfile);
         char base36[StrHelp_MAX_BASE36_BYTES];


Mime
View raw message