develooper Front page | perl.cvs.parrot | Postings from January 2009

[svn:parrot] r35091 - in trunk: languages/befunge languages/ecmascript/src/parser languages/perl6/src/builtins src

From:
infinoid
Date:
January 6, 2009 21:35
Subject:
[svn:parrot] r35091 - in trunk: languages/befunge languages/ecmascript/src/parser languages/perl6/src/builtins src
Message ID:
20090107053524.17715CB9F9@x12.develooper.com
Author: infinoid
Date: Tue Jan  6 21:35:23 2009
New Revision: 35091

Modified:
   trunk/languages/befunge/befunge.pir
   trunk/languages/befunge/debug.pir
   trunk/languages/befunge/load.pir
   trunk/languages/befunge/maths.pir
   trunk/languages/ecmascript/src/parser/actions.pm
   trunk/languages/perl6/src/builtins/any-str.pir
   trunk/src/packfile.c

Log:
[cage] Fix up some codetest failures.

Modified: trunk/languages/befunge/befunge.pir
==============================================================================
--- trunk/languages/befunge/befunge.pir	(original)
+++ trunk/languages/befunge/befunge.pir	Tue Jan  6 21:35:23 2009
@@ -32,17 +32,17 @@
     y = 0       # y coord of the pc
     dir  = 1    # direction of the pc
     flag = 0    # 1=string-mode, 2=bridge, 3=end
-    
+
     .local pmc stack
     stack = new 'ResizablePMCArray'
-    
+
     .local num seed
     seed = time
     seed = mod seed, .RANDMAX
 
     .local string user_input
     user_input = ""
-    
+
         # I5 is debug
         #set S10, P5[I0] ??
         # P1 = the playfield
@@ -154,11 +154,11 @@
 #
 .sub "_parse_argv"
     .param pmc argv
-    
+
     .local int    i, debug
     .local string arg, char, file
     .local pmc    playfield
-    
+
     i     = 0
     debug = 0
   _PARSE_ARGS__ARGV_NEXT:
@@ -177,8 +177,14 @@
   _PARSE_ARGV__DONE:
     file      = argv[i]
     playfield = load(file)
-    
+
     .return(playfield, debug)
 .end
 
 
+########################################################################
+# Local Variables:
+#   mode: pir
+#   fill-column: 100
+# End:
+# vim: expandtab shiftwidth=4 ft=pir:

Modified: trunk/languages/befunge/debug.pir
==============================================================================
--- trunk/languages/befunge/debug.pir	(original)
+++ trunk/languages/befunge/debug.pir	Tue Jan  6 21:35:23 2009
@@ -18,7 +18,7 @@
 #
 .sub "debug_initialize"
     .local pmc step, breakpoints
-    
+
     step = new 'Integer'
     step = 1
     breakpoints = new 'Hash'
@@ -26,7 +26,7 @@
     set_global "step", step
     set_global "breakpoints", breakpoints
     #repeat S10, "0", 128  # No char to break on.
-    
+
     .return()
 .end
 
@@ -232,3 +232,10 @@
         ret
 
 =cut
+
+########################################################################
+# Local Variables:
+#   mode: pir
+#   fill-column: 100
+# End:
+# vim: expandtab shiftwidth=4 ft=pir:

Modified: trunk/languages/befunge/load.pir
==============================================================================
--- trunk/languages/befunge/load.pir	(original)
+++ trunk/languages/befunge/load.pir	Tue Jan  6 21:35:23 2009
@@ -36,14 +36,14 @@
     # end of file, but not enough lines
   LOAD__EOF:
     missing = 24 - noline
-        
+
   LOAD__FILL_EMPTY_LINE:
     line     = _load__fit_str_to_80('')
     playline = _load__str_to_array(line)
     push playfield, playline
     dec missing
     if missing > 0 goto LOAD__FILL_EMPTY_LINE
-    
+
     # file loaded, return the playfield
   LOAD__COMPLETE:
     close fh
@@ -71,10 +71,10 @@
     concat str, ' '
     goto _LOAD__FIT_STR_TO_80__PADDING
   _LOAD__FIT_STR_TO_80__PADDED:
-  
+
     # truncate to 80 chars
     substr str, 80, -1, ''
-  
+
     .return(str)
 .end
 
@@ -87,11 +87,11 @@
 #
 .sub "_load__str_to_array"
     .param string str
-    
+
     .local int i, len, val
     .local string char
     .local pmc array
-   
+
     i     = 0
     len   = length str
     dec len
@@ -103,11 +103,15 @@
     push array, val
     inc i
     goto _LOAD__STR_TO_ARRAY__NEXT_CHAR
-    
+
   _LOAD__STR_TO_ARRAY__DONE:
     .return(array)
 .end
 
 
-
-
+########################################################################
+# Local Variables:
+#   mode: pir
+#   fill-column: 100
+# End:
+# vim: expandtab shiftwidth=4 ft=pir:

Modified: trunk/languages/befunge/maths.pir
==============================================================================
--- trunk/languages/befunge/maths.pir	(original)
+++ trunk/languages/befunge/maths.pir	Tue Jan  6 21:35:23 2009
@@ -131,3 +131,10 @@
         branch MOVE_PC
 
 =cut
+
+########################################################################
+# Local Variables:
+#   mode: pir
+#   fill-column: 100
+# End:
+# vim: expandtab shiftwidth=4 ft=pir:

Modified: trunk/languages/ecmascript/src/parser/actions.pm
==============================================================================
--- trunk/languages/ecmascript/src/parser/actions.pm	(original)
+++ trunk/languages/ecmascript/src/parser/actions.pm	Tue Jan  6 21:35:23 2009
@@ -680,7 +680,7 @@
 
 method object_literal($/) {
     my $past := PAST::Stmts.new( :node($/) );
-    
+
     my $type := PAST::Var.new( :name('JSObject'), :scope('package'), :node($/) );
     my $obj := PAST::Op.new( :pasttype('callmethod'), :name("new"), :node($/), $type);
 

Modified: trunk/languages/perl6/src/builtins/any-str.pir
==============================================================================
--- trunk/languages/perl6/src/builtins/any-str.pir	(original)
+++ trunk/languages/perl6/src/builtins/any-str.pir	Tue Jan  6 21:35:23 2009
@@ -1183,7 +1183,7 @@
     .param string packval
     .local pmc retv
     .local int len
-    
+
     retv = new 'List'
 
     len = length template
@@ -1225,7 +1225,7 @@
     pos += 1
     if pos == len goto done
     goto next_directive
-    
+
   space:
     pos += 1
     if pos == len goto done

Modified: trunk/src/packfile.c
==============================================================================
--- trunk/src/packfile.c	(original)
+++ trunk/src/packfile.c	Tue Jan  6 21:35:23 2009
@@ -4121,11 +4121,13 @@
 
     /* Allocate extra space for the group in the groups array. */
     if (self->groups)
-        self->groups = (PackFile_Annotations_Group **)mem_sys_realloc(self->groups, (1 + self->num_groups) *
-                sizeof(PackFile_Annotations_Group *));
+        self->groups =
+            (PackFile_Annotations_Group **)mem_sys_realloc(self->groups,
+                (1 + self->num_groups) *
+                    sizeof (PackFile_Annotations_Group *));
     else
         self->groups = mem_allocate_n_typed(self->num_groups + 1, PackFile_Annotations_Group *);
-    
+
     /* Store details. */
     self->groups[self->num_groups] = mem_allocate_typed(PackFile_Annotations_Group);
     self->groups[self->num_groups]->bytecode_offset = offset;
@@ -4172,8 +4174,10 @@
     if (key_id == -1) {
         /* We do nee have it. Add key entry. */
         if (self->keys)
-            self->keys = (PackFile_Annotations_Key **)mem_sys_realloc(self->keys, (1 + self->num_keys) *
-                    sizeof(PackFile_Annotations_Key *));
+            self->keys =
+                (PackFile_Annotations_Key **)mem_sys_realloc(self->keys,
+                    (1 + self->num_keys) *
+                        sizeof (PackFile_Annotations_Key *));
         else
             self->keys = mem_allocate_n_typed(self->num_keys + 1, PackFile_Annotations_Key *);
         key_id = self->num_keys;
@@ -4194,10 +4198,14 @@
 
     /* Add annotations entry. */
     if (self->entries)
-            self->entries = (PackFile_Annotations_Entry **)mem_sys_realloc(self->entries, (1 + self->num_entries) *
-                    sizeof(PackFile_Annotations_Entry *));
+            self->entries =
+                (PackFile_Annotations_Entry **)mem_sys_realloc(self->entries,
+                    (1 + self->num_entries) *
+                        sizeof (PackFile_Annotations_Entry *));
         else
-            self->entries = mem_allocate_n_typed(self->num_entries + 1, PackFile_Annotations_Entry *);
+            self->entries =
+                mem_allocate_n_typed(self->num_entries + 1,
+                    PackFile_Annotations_Entry *);
     self->entries[self->num_entries] = mem_allocate_typed(PackFile_Annotations_Entry);
     self->entries[self->num_entries]->bytecode_offset = offset;
     self->entries[self->num_entries]->key = key_id;
@@ -4287,7 +4295,7 @@
             break;
         else
             start_entry = self->groups[i]->entries_offset;
-    
+
     if (key_id == -1) {
         /* Look through entries, storing what we find by key and tracking those
          * that we have values for. */



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About