You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucy.apache.org by ma...@apache.org on 2012/07/22 17:35:41 UTC

[lucy-commits] svn commit: r1364331 - in /lucy/trunk: c/src/ core/Clownfish/ core/Lucy/Object/ core/Lucy/Store/ core/Lucy/Util/ core/Lucy/Util/Json/ example-lang/src/ perl/buildlib/Lucy/Build/Binding/ perl/lib/ perl/lib/Clownfish/ perl/lib/Lucy/Object/ perl/t/ perl/t...

Author: marvin
Date: Sun Jul 22 15:35:40 2012
New Revision: 1364331

URL: http://svn.apache.org/viewvc?rev=1364331&view=rev
Log:
LUCY-242 Move VArray under Clownfish.

Added:
    lucy/trunk/core/Clownfish/VArray.c
      - copied, changed from r1364278, lucy/trunk/core/Lucy/Object/VArray.c
    lucy/trunk/core/Clownfish/VArray.cfh
      - copied, changed from r1364277, lucy/trunk/core/Lucy/Object/VArray.cfh
    lucy/trunk/perl/lib/Clownfish/VArray.pm
      - copied, changed from r1364277, lucy/trunk/perl/lib/Lucy/Object/VArray.pm
Removed:
    lucy/trunk/core/Lucy/Object/VArray.c
    lucy/trunk/core/Lucy/Object/VArray.cfh
    lucy/trunk/perl/lib/Lucy/Object/VArray.pm
Modified:
    lucy/trunk/c/src/CFBind.h
    lucy/trunk/core/Clownfish/Hash.c
    lucy/trunk/core/Clownfish/VTable.c
    lucy/trunk/core/Lucy/Store/FSDirHandle.c
    lucy/trunk/core/Lucy/Util/Json/JsonParser.y
    lucy/trunk/core/Lucy/Util/ToolSet.h
    lucy/trunk/example-lang/src/CFBind.h
    lucy/trunk/perl/buildlib/Lucy/Build/Binding/Object.pm
    lucy/trunk/perl/lib/Lucy.pm
    lucy/trunk/perl/t/028-sortexrun.t
    lucy/trunk/perl/t/213-segment_merging.t
    lucy/trunk/perl/t/221-sort_writer.t
    lucy/trunk/perl/t/505-hit_queue.t
    lucy/trunk/perl/t/518-or_scorer.t
    lucy/trunk/perl/t/520-match_doc.t
    lucy/trunk/perl/t/binding/016-varray.t
    lucy/trunk/perl/xs/XSBind.h
    lucy/trunk/ruby/src/CFBind.h

Modified: lucy/trunk/c/src/CFBind.h
URL: http://svn.apache.org/viewvc/lucy/trunk/c/src/CFBind.h?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/c/src/CFBind.h (original)
+++ lucy/trunk/c/src/CFBind.h Sun Jul 22 15:35:40 2012
@@ -31,7 +31,7 @@ extern "C" {
 #include "Lucy/Object/Err.h"
 #include "Clownfish/Hash.h"
 #include "Clownfish/Num.h"
-#include "Lucy/Object/VArray.h"
+#include "Clownfish/VArray.h"
 #include "Clownfish/VTable.h"
 
 /* Strip the prefix from some common symbols where we know there's no

Modified: lucy/trunk/core/Clownfish/Hash.c
URL: http://svn.apache.org/viewvc/lucy/trunk/core/Clownfish/Hash.c?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/core/Clownfish/Hash.c (original)
+++ lucy/trunk/core/Clownfish/Hash.c Sun Jul 22 15:35:40 2012
@@ -27,7 +27,7 @@
 #include "Clownfish/Hash.h"
 #include "Clownfish/CharBuf.h"
 #include "Lucy/Object/Err.h"
-#include "Lucy/Object/VArray.h"
+#include "Clownfish/VArray.h"
 #include "Lucy/Store/InStream.h"
 #include "Lucy/Store/OutStream.h"
 #include "Lucy/Util/Freezer.h"

Copied: lucy/trunk/core/Clownfish/VArray.c (from r1364278, lucy/trunk/core/Lucy/Object/VArray.c)
URL: http://svn.apache.org/viewvc/lucy/trunk/core/Clownfish/VArray.c?p2=lucy/trunk/core/Clownfish/VArray.c&p1=lucy/trunk/core/Lucy/Object/VArray.c&r1=1364278&r2=1364331&rev=1364331&view=diff
==============================================================================
--- lucy/trunk/core/Lucy/Object/VArray.c (original)
+++ lucy/trunk/core/Clownfish/VArray.c Sun Jul 22 15:35:40 2012
@@ -22,7 +22,7 @@
 #define CHY_USE_SHORT_NAMES
 
 #include "Clownfish/VTable.h"
-#include "Lucy/Object/VArray.h"
+#include "Clownfish/VArray.h"
 #include "Lucy/Object/Err.h"
 #include "Lucy/Util/Memory.h"
 #include "Lucy/Util/Freezer.h"

Copied: lucy/trunk/core/Clownfish/VArray.cfh (from r1364277, lucy/trunk/core/Lucy/Object/VArray.cfh)
URL: http://svn.apache.org/viewvc/lucy/trunk/core/Clownfish/VArray.cfh?p2=lucy/trunk/core/Clownfish/VArray.cfh&p1=lucy/trunk/core/Lucy/Object/VArray.cfh&r1=1364277&r2=1364331&rev=1364331&view=diff
==============================================================================
--- lucy/trunk/core/Lucy/Object/VArray.cfh (original)
+++ lucy/trunk/core/Clownfish/VArray.cfh Sun Jul 22 15:35:40 2012
@@ -29,7 +29,7 @@ __END_C__
 
 /** Variable-sized array.
  */
-class Lucy::Object::VArray cnick VA inherits Lucy::Object::Obj {
+class Clownfish::VArray cnick VA inherits Lucy::Object::Obj {
 
     Obj      **elems;
     uint32_t   size;

Modified: lucy/trunk/core/Clownfish/VTable.c
URL: http://svn.apache.org/viewvc/lucy/trunk/core/Clownfish/VTable.c?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/core/Clownfish/VTable.c (original)
+++ lucy/trunk/core/Clownfish/VTable.c Sun Jul 22 15:35:40 2012
@@ -31,7 +31,7 @@
 #include "Clownfish/LockFreeRegistry.h"
 #include "Clownfish/Method.h"
 #include "Clownfish/Num.h"
-#include "Lucy/Object/VArray.h"
+#include "Clownfish/VArray.h"
 #include "Lucy/Util/Atomic.h"
 #include "Lucy/Util/Memory.h"
 

Modified: lucy/trunk/core/Lucy/Store/FSDirHandle.c
URL: http://svn.apache.org/viewvc/lucy/trunk/core/Lucy/Store/FSDirHandle.c?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/core/Lucy/Store/FSDirHandle.c (original)
+++ lucy/trunk/core/Lucy/Store/FSDirHandle.c Sun Jul 22 15:35:40 2012
@@ -23,7 +23,7 @@
 
 #include "Lucy/Util/ToolSet.h"
 #include "Lucy/Object/Err.h"
-#include "Lucy/Object/VArray.h"
+#include "Clownfish/VArray.h"
 #include "Lucy/Store/FSDirHandle.h"
 
 #ifdef CHY_HAS_SYS_TYPES_H

Modified: lucy/trunk/core/Lucy/Util/Json/JsonParser.y
URL: http://svn.apache.org/viewvc/lucy/trunk/core/Lucy/Util/Json/JsonParser.y?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/core/Lucy/Util/Json/JsonParser.y (original)
+++ lucy/trunk/core/Lucy/Util/Json/JsonParser.y Sun Jul 22 15:35:40 2012
@@ -25,7 +25,7 @@
 #include <string.h>
 #include <assert.h>
 #include "Clownfish/Hash.h"
-#include "Lucy/Object/VArray.h"
+#include "Clownfish/VArray.h"
 #include "Clownfish/CharBuf.h"
 #include "Lucy/Object/Err.h"
 #include "Lucy/Util/Json.h"

Modified: lucy/trunk/core/Lucy/Util/ToolSet.h
URL: http://svn.apache.org/viewvc/lucy/trunk/core/Lucy/Util/ToolSet.h?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/core/Lucy/Util/ToolSet.h (original)
+++ lucy/trunk/core/Lucy/Util/ToolSet.h Sun Jul 22 15:35:40 2012
@@ -44,7 +44,7 @@ extern "C" {
 #include "Clownfish/Hash.h"
 #include "Lucy/Object/I32Array.h"
 #include "Clownfish/Num.h"
-#include "Lucy/Object/VArray.h"
+#include "Clownfish/VArray.h"
 #include "Clownfish/VTable.h"
 #include "Lucy/Util/NumberUtils.h"
 #include "Lucy/Util/Memory.h"

Modified: lucy/trunk/example-lang/src/CFBind.h
URL: http://svn.apache.org/viewvc/lucy/trunk/example-lang/src/CFBind.h?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/example-lang/src/CFBind.h (original)
+++ lucy/trunk/example-lang/src/CFBind.h Sun Jul 22 15:35:40 2012
@@ -31,7 +31,7 @@ extern "C" {
 #include "Lucy/Object/Err.h"
 #include "Clownfish/Hash.h"
 #include "Clownfish/Num.h"
-#include "Lucy/Object/VArray.h"
+#include "Clownfish/VArray.h"
 #include "Clownfish/VTable.h"
 
 /* Strip the prefix from some common symbols where we know there's no

Modified: lucy/trunk/perl/buildlib/Lucy/Build/Binding/Object.pm
URL: http://svn.apache.org/viewvc/lucy/trunk/perl/buildlib/Lucy/Build/Binding/Object.pm?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/perl/buildlib/Lucy/Build/Binding/Object.pm (original)
+++ lucy/trunk/perl/buildlib/Lucy/Build/Binding/Object.pm Sun Jul 22 15:35:40 2012
@@ -740,7 +740,7 @@ sub bind_varray {
     );
 
     my $xs_code = <<'END_XS_CODE';
-MODULE = Lucy   PACKAGE = Lucy::Object::VArray
+MODULE = Lucy   PACKAGE = Clownfish::VArray
 
 SV*
 shallow_copy(self)
@@ -809,7 +809,7 @@ END_XS_CODE
 
     my $binding = Clownfish::CFC::Binding::Perl::Class->new(
         parcel     => "Lucy",
-        class_name => "Lucy::Object::VArray",
+        class_name => "Clownfish::VArray",
     );
     $binding->exclude_method($_) for @hand_rolled;
     $binding->append_xs($xs_code);

Copied: lucy/trunk/perl/lib/Clownfish/VArray.pm (from r1364277, lucy/trunk/perl/lib/Lucy/Object/VArray.pm)
URL: http://svn.apache.org/viewvc/lucy/trunk/perl/lib/Clownfish/VArray.pm?p2=lucy/trunk/perl/lib/Clownfish/VArray.pm&p1=lucy/trunk/perl/lib/Lucy/Object/VArray.pm&r1=1364277&r2=1364331&rev=1364331&view=diff
==============================================================================
--- lucy/trunk/perl/lib/Lucy/Object/VArray.pm (original)
+++ lucy/trunk/perl/lib/Clownfish/VArray.pm Sun Jul 22 15:35:40 2012
@@ -13,7 +13,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-package Lucy::Object::VArray;
+package Clownfish::VArray;
 use Lucy;
 our $VERSION = '0.003000';
 $VERSION = eval $VERSION;

Modified: lucy/trunk/perl/lib/Lucy.pm
URL: http://svn.apache.org/viewvc/lucy/trunk/perl/lib/Lucy.pm?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/perl/lib/Lucy.pm (original)
+++ lucy/trunk/perl/lib/Lucy.pm Sun Jul 22 15:35:40 2012
@@ -157,7 +157,7 @@ sub error {$Lucy::Object::Err::error}
         no strict 'refs';
         my $stash = \%{"$package\::"};
         my $methods
-            = Lucy::Object::VArray->new( capacity => scalar keys %$stash );
+            = Clownfish::VArray->new( capacity => scalar keys %$stash );
         while ( my ( $symbol, $glob ) = each %$stash ) {
             next if ref $glob;
             next unless *$glob{CODE};
@@ -389,7 +389,7 @@ sub error {$Lucy::Object::Err::error}
 }
 
 {
-    package Lucy::Object::VArray;
+    package Clownfish::VArray;
     our $VERSION = '0.003000';
     $VERSION = eval $VERSION;
     no warnings 'redefine';

Modified: lucy/trunk/perl/t/028-sortexrun.t
URL: http://svn.apache.org/viewvc/lucy/trunk/perl/t/028-sortexrun.t?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/perl/t/028-sortexrun.t (original)
+++ lucy/trunk/perl/t/028-sortexrun.t Sun Jul 22 15:35:40 2012
@@ -22,7 +22,7 @@ use Test::More skip_all => 'Disabled unt
 use Lucy::Test;
 use Lucy qw( to_perl );
 
-my $letters = Lucy::Object::VArray->new( capacity => 26 );
+my $letters = Clownfish::VArray->new( capacity => 26 );
 $letters->push( Lucy::Object::ByteBuf->new($_) ) for 'a' .. 'z';
 my $run = Lucy::Test::Util::BBSortEx->new( external => $letters );
 $run->set_mem_thresh(5);

Modified: lucy/trunk/perl/t/213-segment_merging.t
URL: http://svn.apache.org/viewvc/lucy/trunk/perl/t/213-segment_merging.t?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/perl/t/213-segment_merging.t (original)
+++ lucy/trunk/perl/t/213-segment_merging.t Sun Jul 22 15:35:40 2012
@@ -23,7 +23,7 @@ package NonMergingIndexManager;
 use base qw( Lucy::Index::IndexManager );
 
 sub recycle {
-    return Lucy::Object::VArray->new( capacity => 0 );
+    return Clownfish::VArray->new( capacity => 0 );
 }
 
 # BiggerSchema is like TestSchema, but it has an extra field named "aux".

Modified: lucy/trunk/perl/t/221-sort_writer.t
URL: http://svn.apache.org/viewvc/lucy/trunk/perl/t/221-sort_writer.t?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/perl/t/221-sort_writer.t (original)
+++ lucy/trunk/perl/t/221-sort_writer.t Sun Jul 22 15:35:40 2012
@@ -21,7 +21,7 @@ package NonMergingIndexManager;
 use base qw( Lucy::Index::IndexManager );
 
 sub recycle {
-    return Lucy::Object::VArray->new( capacity => 0 );
+    return Clownfish::VArray->new( capacity => 0 );
 }
 
 package SortSchema;

Modified: lucy/trunk/perl/t/505-hit_queue.t
URL: http://svn.apache.org/viewvc/lucy/trunk/perl/t/505-hit_queue.t?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/perl/t/505-hit_queue.t (original)
+++ lucy/trunk/perl/t/505-hit_queue.t Sun Jul 22 15:35:40 2012
@@ -169,7 +169,7 @@ $hit_q = Lucy::Search::HitQueue->new(
 
 for my $doc_id ( shuffle( 1 .. 100 ) ) {
     my $fields = $docs[ $doc_id - 1 ];
-    my $values = Lucy::Object::VArray->new( capacity => 1 );
+    my $values = Clownfish::VArray->new( capacity => 1 );
     $values->push( Clownfish::CharBuf->new( $fields->{number} ) );
     my $match_doc = Lucy::Search::MatchDoc->new(
         doc_id => $doc_id,

Modified: lucy/trunk/perl/t/518-or_scorer.t
URL: http://svn.apache.org/viewvc/lucy/trunk/perl/t/518-or_scorer.t?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/perl/t/518-or_scorer.t (original)
+++ lucy/trunk/perl/t/518-or_scorer.t Sun Jul 22 15:35:40 2012
@@ -38,7 +38,7 @@ sub check_matcher {
     my @intervals = @_;
     my @doc_id_arrays = map { modulo_set( $_, 100 ) } @intervals;
     my $child_matchers
-        = Lucy::Object::VArray->new( capacity => scalar @intervals );
+        = Clownfish::VArray->new( capacity => scalar @intervals );
     for my $doc_id_array (@doc_id_arrays) {
         if (@$doc_id_array) {
             my $mock = LucyX::Search::MockMatcher->new(

Modified: lucy/trunk/perl/t/520-match_doc.t
URL: http://svn.apache.org/viewvc/lucy/trunk/perl/t/520-match_doc.t?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/perl/t/520-match_doc.t (original)
+++ lucy/trunk/perl/t/520-match_doc.t Sun Jul 22 15:35:40 2012
@@ -36,7 +36,7 @@ is( $match_doc_copy->get_score, $match_d
 is( $match_doc_copy->get_values, $match_doc->get_values,
     "empty values still empty after serialization" );
 
-my $values = Lucy::Object::VArray->new( capacity => 4 );
+my $values = Clownfish::VArray->new( capacity => 4 );
 $values->store( 0, Clownfish::CharBuf->new("foo") );
 $values->store( 3, Clownfish::CharBuf->new("bar") );
 $match_doc = Lucy::Search::MatchDoc->new(

Modified: lucy/trunk/perl/t/binding/016-varray.t
URL: http://svn.apache.org/viewvc/lucy/trunk/perl/t/binding/016-varray.t?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/perl/t/binding/016-varray.t (original)
+++ lucy/trunk/perl/t/binding/016-varray.t Sun Jul 22 15:35:40 2012
@@ -22,7 +22,7 @@ use Lucy::Test;
 
 my ( $varray, $twin );
 
-$varray = Lucy::Object::VArray->new( capacity => 5 );
+$varray = Clownfish::VArray->new( capacity => 5 );
 $varray->push( Clownfish::CharBuf->new($_) ) for 1 .. 5;
 $varray->delete(3);
 my $frozen = nfreeze($varray);
@@ -37,7 +37,7 @@ $outstream->close;
 my $instream = Lucy::Store::InStream->open( file => $ram_file )
     or die Lucy->error;
 my $vtable
-    = Clownfish::VTable->singleton( class_name => 'Lucy::Object::VArray', );
+    = Clownfish::VTable->singleton( class_name => 'Clownfish::VArray', );
 my $deserialized = $vtable->make_obj->deserialize($instream);
 is_deeply( $varray->to_perl, $deserialized->to_perl,
     "serialize/deserialize" );

Modified: lucy/trunk/perl/xs/XSBind.h
URL: http://svn.apache.org/viewvc/lucy/trunk/perl/xs/XSBind.h?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/perl/xs/XSBind.h (original)
+++ lucy/trunk/perl/xs/XSBind.h Sun Jul 22 15:35:40 2012
@@ -31,7 +31,7 @@ extern "C" {
 #include "Lucy/Object/Err.h"
 #include "Clownfish/Hash.h"
 #include "Clownfish/Num.h"
-#include "Lucy/Object/VArray.h"
+#include "Clownfish/VArray.h"
 #include "Clownfish/VTable.h"
 
 #include "EXTERN.h"

Modified: lucy/trunk/ruby/src/CFBind.h
URL: http://svn.apache.org/viewvc/lucy/trunk/ruby/src/CFBind.h?rev=1364331&r1=1364330&r2=1364331&view=diff
==============================================================================
--- lucy/trunk/ruby/src/CFBind.h (original)
+++ lucy/trunk/ruby/src/CFBind.h Sun Jul 22 15:35:40 2012
@@ -31,7 +31,7 @@ extern "C" {
 #include "Lucy/Object/Err.h"
 #include "Clownfish/Hash.h"
 #include "Clownfish/Num.h"
-#include "Lucy/Object/VArray.h"
+#include "Clownfish/VArray.h"
 #include "Clownfish/VTable.h"
 
 /* Strip the prefix from some common symbols where we know there's no