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 2011/12/21 05:16:18 UTC
[lucy-commits] svn commit: r1221606 - in /incubator/lucy/trunk/clownfish:
perl/buildlib/Clownfish/CFC/ perl/lib/Clownfish/
perl/lib/Clownfish/CFC/Binding/Core/ perl/t/ src/
Author: marvin
Date: Wed Dec 21 04:16:18 2011
New Revision: 1221606
URL: http://svn.apache.org/viewvc?rev=1221606&view=rev
Log:
Whitespace (run lucytidy.pl).
Modified:
incubator/lucy/trunk/clownfish/perl/buildlib/Clownfish/CFC/Build.pm
incubator/lucy/trunk/clownfish/perl/lib/Clownfish/CFC.pm
incubator/lucy/trunk/clownfish/perl/lib/Clownfish/CFC/Binding/Core/File.pm
incubator/lucy/trunk/clownfish/perl/t/100-type.t
incubator/lucy/trunk/clownfish/perl/t/200-function.t
incubator/lucy/trunk/clownfish/perl/t/201-method.t
incubator/lucy/trunk/clownfish/perl/t/300-variable.t
incubator/lucy/trunk/clownfish/perl/t/500-hierarchy.t
incubator/lucy/trunk/clownfish/src/CFCCBlock.h
incubator/lucy/trunk/clownfish/src/CFCClass.h
incubator/lucy/trunk/clownfish/src/CFCDumpable.h
incubator/lucy/trunk/clownfish/src/CFCFile.h
incubator/lucy/trunk/clownfish/src/CFCFunction.h
incubator/lucy/trunk/clownfish/src/CFCHierarchy.h
incubator/lucy/trunk/clownfish/src/CFCMethod.h
incubator/lucy/trunk/clownfish/src/CFCParamList.h
incubator/lucy/trunk/clownfish/src/CFCParcel.h
incubator/lucy/trunk/clownfish/src/CFCParser.h
incubator/lucy/trunk/clownfish/src/CFCType.h
incubator/lucy/trunk/clownfish/src/CFCUtil.c
incubator/lucy/trunk/clownfish/src/CFCUtil.h
incubator/lucy/trunk/clownfish/src/CFCVariable.h
Modified: incubator/lucy/trunk/clownfish/perl/buildlib/Clownfish/CFC/Build.pm
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/perl/buildlib/Clownfish/CFC/Build.pm?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/perl/buildlib/Clownfish/CFC/Build.pm (original)
+++ incubator/lucy/trunk/clownfish/perl/buildlib/Clownfish/CFC/Build.pm Wed Dec 21 04:16:18 2011
@@ -30,7 +30,7 @@ my $LEMON_EXE_PATH = catfile( $LEMON_DIR
my $CFC_SOURCE_DIR = catdir( updir(), 'src' );
sub extra_ccflags {
- my $self = shift;
+ my $self = shift;
my $extra_ccflags = "-DCFCPERL ";
$extra_ccflags .= "$ENV{CFLAGS} " if defined $ENV{CFLAGS};
Modified: incubator/lucy/trunk/clownfish/perl/lib/Clownfish/CFC.pm
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/perl/lib/Clownfish/CFC.pm?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/perl/lib/Clownfish/CFC.pm (original)
+++ incubator/lucy/trunk/clownfish/perl/lib/Clownfish/CFC.pm Wed Dec 21 04:16:18 2011
@@ -137,13 +137,16 @@ BEGIN { XSLoader::load( 'Clownfish::CFC'
my $parcel = $args{parcel};
if ( defined $parcel ) {
if ( !a_isa_b( $parcel, "Clownfish::CFC::Parcel" ) ) {
- $parcel = Clownfish::CFC::Parcel->singleton( name => $parcel );
+ $parcel
+ = Clownfish::CFC::Parcel->singleton( name => $parcel );
}
}
return _fetch_singleton( $parcel, $args{class_name} );
}
- sub new { confess("The constructor for Clownfish::CFC::Class is create()") }
+ sub new {
+ confess("The constructor for Clownfish::CFC::Class is create()");
+ }
sub create {
my ( $either, %args ) = @_;
@@ -308,11 +311,11 @@ BEGIN { XSLoader::load( 'Clownfish::CFC'
return _singleton( @args{qw( name cnick )} );
}
- # $parcel = Clownfish::CFC::Parcel->aquire($parcel_name_or_parcel_object);
- #
- # Aquire a parcel one way or another. If the supplied argument is a
- # Parcel, return it. If it's not defined, return the default Parcel. If
- # it's a name, invoke singleton().
+ # $parcel = Clownfish::CFC::Parcel->aquire($parcel_name_or_parcel_object);
+ #
+ # Aquire a parcel one way or another. If the supplied argument is a
+ # Parcel, return it. If it's not defined, return the default Parcel. If
+ # it's a name, invoke singleton().
sub acquire {
my ( undef, $thing ) = @_;
if ( !defined $thing ) {
@@ -648,7 +651,6 @@ BEGIN { XSLoader::load( 'Clownfish::CFC'
use Clownfish::CFC::Binding::Perl::TypeMap;
}
-
1;
=head1 NAME
Modified: incubator/lucy/trunk/clownfish/perl/lib/Clownfish/CFC/Binding/Core/File.pm
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/perl/lib/Clownfish/CFC/Binding/Core/File.pm?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/perl/lib/Clownfish/CFC/Binding/Core/File.pm (original)
+++ incubator/lucy/trunk/clownfish/perl/lib/Clownfish/CFC/Binding/Core/File.pm Wed Dec 21 04:16:18 2011
@@ -18,4 +18,3 @@ use Clownfish::CFC;
1;
-
Modified: incubator/lucy/trunk/clownfish/perl/t/100-type.t
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/perl/t/100-type.t?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/perl/t/100-type.t (original)
+++ incubator/lucy/trunk/clownfish/perl/t/100-type.t Wed Dec 21 04:16:18 2011
@@ -21,7 +21,8 @@ use Clownfish::CFC::Parcel;
my $neato_parcel = Clownfish::CFC::Parcel->singleton( name => 'Neato' );
-my $type = Clownfish::CFC::Type->new( parcel => 'Neato', specifier => 'mytype_t' );
+my $type
+ = Clownfish::CFC::Type->new( parcel => 'Neato', specifier => 'mytype_t' );
is( ${ $type->get_parcel },
$$neato_parcel, "constructor changes parcel name to Parcel singleton" );
Modified: incubator/lucy/trunk/clownfish/perl/t/200-function.t
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/perl/t/200-function.t?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/perl/t/200-function.t (original)
+++ incubator/lucy/trunk/clownfish/perl/t/200-function.t Wed Dec 21 04:16:18 2011
@@ -38,7 +38,9 @@ my %args = (
my $func = Clownfish::CFC::Function->new(%args);
isa_ok( $func, "Clownfish::CFC::Function" );
-eval { my $death = Clownfish::CFC::Function->new( %args, extra_arg => undef ) };
+eval {
+ my $death = Clownfish::CFC::Function->new( %args, extra_arg => undef );
+};
like( $@, qr/extra_arg/, "Extra arg kills constructor" );
eval { Clownfish::CFC::Function->new( %args, micro_sym => 'Uh_Oh' ); };
Modified: incubator/lucy/trunk/clownfish/perl/t/201-method.t
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/perl/t/201-method.t?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/perl/t/201-method.t (original)
+++ incubator/lucy/trunk/clownfish/perl/t/201-method.t Wed Dec 21 04:16:18 2011
@@ -48,7 +48,8 @@ like( $@, qr/macro_sym/, "Invalid macro_
my $dupe = Clownfish::CFC::Method->new(%args);
ok( $method->compatible($dupe), "compatible()" );
-my $macro_sym_differs = Clownfish::CFC::Method->new( %args, macro_sym => 'Eat' );
+my $macro_sym_differs
+ = Clownfish::CFC::Method->new( %args, macro_sym => 'Eat' );
ok( !$method->compatible($macro_sym_differs),
"different macro_sym spoils compatible()"
);
@@ -114,7 +115,8 @@ for my $meth_meth (qw( short_method_sym
$parser->set_class_name("Neato::Obj");
$parser->set_class_cnick("Obj");
-isa_ok( $parser->parse($_), "Clownfish::CFC::Method", "method declaration: $_" )
+isa_ok( $parser->parse($_), "Clownfish::CFC::Method",
+ "method declaration: $_" )
for (
'public int Do_Foo(Obj *self);',
'parcel Obj* Gimme_An_Obj(Obj *self);',
Modified: incubator/lucy/trunk/clownfish/perl/t/300-variable.t
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/perl/t/300-variable.t?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/perl/t/300-variable.t (original)
+++ incubator/lucy/trunk/clownfish/perl/t/300-variable.t Wed Dec 21 04:16:18 2011
@@ -39,7 +39,9 @@ like( $@, qr/extra_arg/, "Extra arg kill
eval { my $death = Clownfish::CFC::Variable->new( micro_sym => 'foo' ) };
like( $@, qr/type/, "type is required" );
-eval { my $death = Clownfish::CFC::Variable->new( type => new_type('int32_t') ) };
+eval {
+ my $death = Clownfish::CFC::Variable->new( type => new_type('int32_t') );
+};
like( $@, qr/micro_sym/, "micro_sym is required" );
my $var = Clownfish::CFC::Variable->new(
Modified: incubator/lucy/trunk/clownfish/perl/t/500-hierarchy.t
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/perl/t/500-hierarchy.t?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/perl/t/500-hierarchy.t (original)
+++ incubator/lucy/trunk/clownfish/perl/t/500-hierarchy.t Wed Dec 21 04:16:18 2011
@@ -32,7 +32,9 @@ my %args = (
# Clean up.
rmtree( $args{dest} );
-eval { my $death = Clownfish::CFC::Hierarchy->new( %args, extra_arg => undef ) };
+eval {
+ my $death = Clownfish::CFC::Hierarchy->new( %args, extra_arg => undef );
+};
like( $@, qr/extra_arg/, "Extra arg kills constructor" );
my $hierarchy = Clownfish::CFC::Hierarchy->new(%args);
Modified: incubator/lucy/trunk/clownfish/src/CFCCBlock.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCCBlock.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCCBlock.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCCBlock.h Wed Dec 21 04:16:18 2011
@@ -21,7 +21,7 @@
*
* class Crustacean::Lobster {
* ...
- *
+ *
* inert inline void
* say_hello(Lobster *self);
* }
@@ -45,7 +45,7 @@ extern "C" {
typedef struct CFCCBlock CFCCBlock;
-/** CBlock Constructor.
+/** CBlock Constructor.
*
* @param contents The contents of the CBlock, not including delimiters.
*/
Modified: incubator/lucy/trunk/clownfish/src/CFCClass.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCClass.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCClass.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCClass.h Wed Dec 21 04:16:18 2011
@@ -37,10 +37,10 @@ struct CFCVariable;
/** Create and register a quasi-singleton. May only be called once for each
* unique parcel/class_name combination.
*
- * @param parcel See Clownfish::CFC::Symbol.
- * @param exposure See Clownfish::CFC::Symbol.
- * @param class_name See Clownfish::CFC::Symbol.
- * @param cnick See Clownfish::CFC::Symbol.
+ * @param parcel See Clownfish::CFC::Symbol.
+ * @param exposure See Clownfish::CFC::Symbol.
+ * @param class_name See Clownfish::CFC::Symbol.
+ * @param cnick See Clownfish::CFC::Symbol.
* @param micro_sym Defaults to "class".
* @param docucomment An optional Clownfish::CFC::DocuComment attached to this class.
* @param source_class - The name of the class that owns the file in which
Modified: incubator/lucy/trunk/clownfish/src/CFCDumpable.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCDumpable.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCDumpable.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCDumpable.h Wed Dec 21 04:16:18 2011
@@ -20,13 +20,13 @@
* declare either Dump or Load(), Clownfish::CFC::Dumpable will attempt to
* auto-generate those methods if methods inherited from the parent class do
* not suffice.
- *
+ *
* class Foo::Bar inherits Foo : dumpable {
* Thing *thing;
- *
+ *
* public inert incremented Bar*
* new();
- *
+ *
* void
* Destroy(Bar *self);
* }
@@ -42,7 +42,7 @@ extern "C" {
typedef struct CFCDumpable CFCDumpable;
struct CFCClass;
-/** Constructor.
+/** Constructor.
*/
CFCDumpable*
CFCDumpable_new(void);
Modified: incubator/lucy/trunk/clownfish/src/CFCFile.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCFile.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCFile.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCFile.h Wed Dec 21 04:16:18 2011
@@ -17,7 +17,7 @@
/** Clownfish::CFC::File - Structured representation of the contents of a Clownfish
* source file.
- *
+ *
* An abstraction representing a file which contains Clownfish code.
*/
#ifndef H_CFCFILE
Modified: incubator/lucy/trunk/clownfish/src/CFCFunction.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCFunction.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCFunction.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCFunction.h Wed Dec 21 04:16:18 2011
@@ -47,7 +47,7 @@ struct CFCFunction {
* @param exposure The function's exposure (see L<Clownfish::CFC::Symbol>).
* @param class_name The full name of the class in whose namespace the
* function resides.
- * @param class_cnick The C nickname for the class.
+ * @param class_cnick The C nickname for the class.
* @param micro_sym The lower case name of the function, without any
* namespacing prefixes.
* @param return_type A Clownfish::CFC::Type representing the function's
Modified: incubator/lucy/trunk/clownfish/src/CFCHierarchy.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCHierarchy.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCHierarchy.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCHierarchy.h Wed Dec 21 04:16:18 2011
@@ -55,7 +55,7 @@ void
CFCHierarchy_build(CFCHierarchy *self);
/** Visit all File objects in the hierarchy. If a parent node is modified, mark
- * all of its children as modified.
+ * all of its children as modified.
*
* If the supplied argument is true, mark all Files as modified.
*/
Modified: incubator/lucy/trunk/clownfish/src/CFCMethod.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCMethod.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCMethod.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCMethod.h Wed Dec 21 04:16:18 2011
@@ -97,7 +97,7 @@ CFCMethod_override(CFCMethod *self, CFCM
* Method objects are shared between parent and child classes; if a shared
* Method object were to become final, it would interfere with its own
* inheritance. So, we make a copy, slightly modified to indicate that it is
- * "final".
+ * "final".
*/
CFCMethod*
CFCMethod_finalize(CFCMethod *self);
Modified: incubator/lucy/trunk/clownfish/src/CFCParamList.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCParamList.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCParamList.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCParamList.h Wed Dec 21 04:16:18 2011
@@ -40,7 +40,7 @@ void
CFCParamList_destroy(CFCParamList *self);
/** Add a parameter to the ParamList.
- *
+ *
* @param variable A Clownfish::CFC::Variable.
* @param value The parameter's default value, which should be NULL
* if there is no default and thus the parameter is required.
@@ -77,7 +77,7 @@ const char*
CFCParamList_to_c(CFCParamList *self);
/** Return the variable's names, joined by commas. For example:
- *
+ *
* self, foo, bar
*/
const char*
Modified: incubator/lucy/trunk/clownfish/src/CFCParcel.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCParcel.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCParcel.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCParcel.h Wed Dec 21 04:16:18 2011
@@ -21,9 +21,9 @@
*
* Clownfish supports two-tier manual namespacing, using a prefix, an optional
* class nickname, and the local symbol:
- *
+ *
* prefix_ClassNick_local_symbol
- *
+ *
* Clownfish::CFC::Parcel supports the first tier, specifying initial prefixes.
* These prefixes come in three capitalization variants: prefix_, Prefix_, and
* PREFIX_.
Modified: incubator/lucy/trunk/clownfish/src/CFCParser.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCParser.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCParser.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCParser.h Wed Dec 21 04:16:18 2011
@@ -18,7 +18,7 @@
*
* Clownfish::CFC::Parser is a combined lexer/parser which parses Clownfish header
* files. It is not at all strict, as it relies heavily on the C parser to
- * pick up errors such as misspelled type names.
+ * pick up errors such as misspelled type names.
*/
#ifndef H_CFCPARSER
Modified: incubator/lucy/trunk/clownfish/src/CFCType.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCType.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCType.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCType.h Wed Dec 21 04:16:18 2011
@@ -42,12 +42,12 @@ struct CFCParcel;
#define CFCTYPE_COMPOSITE 0x00001000
/** Generic constructor.
- *
+ *
* @param flags Flags which apply to the Type. Supplying incompatible flags
* will trigger an error.
* @param parcel A Clownfish::CFC::Parcel.
* @param specifier The C name for the type, not including any indirection or
- * array subscripts.
+ * array subscripts.
* @param indirection integer indicating level of indirection. Example: the C
* type "float**" has a specifier of "float" and indirection 2.
* @param c_string The C representation of the type.
@@ -79,7 +79,7 @@ CFCType_init(CFCType *self, int flags, s
* size_t
*
* Many others are not supported: "signed" or "unsigned" anything, "long
- * long", "ptrdiff_t", "off_t", etc.
+ * long", "ptrdiff_t", "off_t", etc.
*
* The following Charmonizer typedefs are supported:
*
@@ -125,7 +125,7 @@ CFCType_new_object(int flags, struct CFC
* @param child The Clownfish::CFC::Type which the composite is comprised of.
* @param indirection integer indicating level of indirection. Example: the C type
* "float**" has indirection 2.
- * @param array A string describing an array postfix.
+ * @param array A string describing an array postfix.
*/
CFCType*
CFCType_new_composite(int flags, CFCType *child, int indirection,
Modified: incubator/lucy/trunk/clownfish/src/CFCUtil.c
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCUtil.c?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCUtil.c (original)
+++ incubator/lucy/trunk/clownfish/src/CFCUtil.c Wed Dec 21 04:16:18 2011
@@ -444,7 +444,7 @@ CFCUtil_warn(const char* format, ...) {
SvREFCNT_dec(mess);
}
-#else
+#else
void
CFCUtil_die(const char* format, ...) {
Modified: incubator/lucy/trunk/clownfish/src/CFCUtil.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCUtil.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCUtil.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCUtil.h Wed Dec 21 04:16:18 2011
@@ -98,7 +98,7 @@ CFCUtil_wrapped_free(void *ptr);
CFCUtil_wrapped_free(_ptr)
/** Given two filepaths, return true if the second exists and has a
- * modification time which more recent than that of the first.
+ * modification time which more recent than that of the first.
*/
int
CFCUtil_current(const char *orig, const char *dest);
Modified: incubator/lucy/trunk/clownfish/src/CFCVariable.h
URL: http://svn.apache.org/viewvc/incubator/lucy/trunk/clownfish/src/CFCVariable.h?rev=1221606&r1=1221605&r2=1221606&view=diff
==============================================================================
--- incubator/lucy/trunk/clownfish/src/CFCVariable.h (original)
+++ incubator/lucy/trunk/clownfish/src/CFCVariable.h Wed Dec 21 04:16:18 2011
@@ -36,7 +36,7 @@ typedef struct CFCVariable CFCVariable;
struct CFCParcel;
struct CFCType;
-/**
+/**
* @param type A Clownfish::CFC::Type.
* @param micro_sym The variable's name, without any namespacing prefixes.
* @param exposure See Clownfish::CFC::Symbol.