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

[svn:parrot] r35116 - trunk/languages/befunge

From:
jquelin
Date:
January 7, 2009 04:18
Subject:
[svn:parrot] r35116 - trunk/languages/befunge
Message ID:
20090107121840.C2D5DCB9F9@x12.develooper.com
Author: jquelin
Date: Wed Jan  7 04:18:40 2009
New Revision: 35116

Modified:
   trunk/languages/befunge/debug.pir

Log:
simplifying coords & current char output


Modified: trunk/languages/befunge/debug.pir
==============================================================================
--- trunk/languages/befunge/debug.pir	(original)
+++ trunk/languages/befunge/debug.pir	Wed Jan  7 04:18:40 2009
@@ -32,34 +32,26 @@
 
 
 .sub "_debug__print_status_coordinates"
-    .local pmc status
-    .local int x
-    .local int y
-
-    status = get_global "status"
-    x = status["x"]
-    y = status["y"]
+    $P0 = get_global "status"
+    $I0 = $P0["x"]
+    $I1 = $P0["y"]
 
     print "("
-    print x
+    print $I0
     print ","
-    print y
+    print $I1
     print ")"
 .end
 
 .sub "_debug__print_status_current_char"
-    .local pmc    status
-    .local string char 
-    .local int    val
-
-    status = get_global "status"
-    char = status["char"]
-    val  = status["val"]
+    $P0 = get_global "status"
+    $S0 = $P0["char"]
+    $I0 = $P0["val"]
 
     print "'"
-    print char
+    print $S0
     print "' (ord="
-    print val
+    print $I0
     print ")"
 .end
 



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