cvsuser     04/12/29 14:47:56

  Modified:    classes  fixedstringarray.pmc
  Log:
   Convert PerlString -> String
  
   Various documentation tweaks
  
  Revision  Changes    Path
  1.5       +15 -9     parrot/classes/fixedstringarray.pmc
  
  Index: fixedstringarray.pmc
  ===================================================================
  RCS file: /cvs/public/parrot/classes/fixedstringarray.pmc,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- fixedstringarray.pmc      12 Dec 2004 23:03:45 -0000      1.4
  +++ fixedstringarray.pmc      29 Dec 2004 22:47:56 -0000      1.5
  @@ -1,6 +1,6 @@
   /*
   Copyright: 2001-2003 The Perl Foundation.  All Rights Reserved.
  -$Id: fixedstringarray.pmc,v 1.4 2004/12/12 23:03:45 chromatic Exp $
  +$Id: fixedstringarray.pmc,v 1.5 2004/12/29 22:47:56 scog Exp $
   
   =head1 NAME
   
  @@ -8,8 +8,8 @@
   
   =head1 DESCRIPTION
   
  -This class, FixedStringArray, implements an array of fixed size, which 
stored STRING*
  -TODO: it uses PerlString's internally to perform conversion, but it should 
use String PMCs
  +This class, FixedStringArray, implements an array of fixed size, which 
  +stores Parrot strings.
   
   =head2 Functions
   
  @@ -129,8 +129,10 @@
   
   =item C<INTVAL get_bool()>
   
  -Returns whether the array has any elements (meaning been initialized, for a
  -fixed sized array).
  +Returns 1 if the array has any elements; otherwise, returns 0. 
  +Since this is a fixed size array, C<get_bool> will always 
  +return true once the array has been initialized and had its 
  +size set by C<set_integer_native>.
   
   =cut
   
  @@ -144,6 +146,8 @@
   
   =item C<INTVAL elements()>
   
  +Returns the number of elements in the array.
  +
   =cut
   
   */
  @@ -279,7 +283,7 @@
           PMC *ret;
           STRING *val;
   
  -        ret = pmc_new(INTERP, enum_class_PerlString);
  +        ret = pmc_new(INTERP, enum_class_String);
           val = DYNSELF.get_string_keyed_int(key);
           VTABLE_set_string_native(INTERP, ret, val);
           return ret;
  @@ -304,7 +308,9 @@
   
   =item C<void set_integer_native(INTVAL size)>
   
  -Resizes the array to C<size> elements.
  +Sets the size of the array to C<size> elements. Once the array 
  +has been given an initial size, attempts to resize it will 
  +cause an exception to be thrown.
   
   =cut
   
  @@ -332,7 +338,7 @@
           PMC *ret;
           STRING *val;
   
  -        ret = pmc_new(INTERP, enum_class_PerlString);
  +        ret = pmc_new(INTERP, enum_class_String);
           VTABLE_set_integer_native(INTERP, ret, value);
           val = VTABLE_get_string(INTERP, ret);
           DYNSELF.set_string_keyed_int(key, val);
  @@ -369,7 +375,7 @@
           PMC *ret;
           STRING *val;
   
  -        ret = pmc_new(INTERP, enum_class_PerlString);
  +        ret = pmc_new(INTERP, enum_class_String);
           VTABLE_set_number_native(INTERP, ret, value);
           val = VTABLE_get_string(INTERP, ret);
           DYNSELF.set_string_keyed_int(key, val);
  
  
  

Reply via email to