bb18255caa3a — Gerald Klix (delle) 8 years ago
SUM: `pop` now accepts a step number.
1 files changed, 6 insertions(+), 1 deletions(-)

M gf/go.py
M gf/go.py +6 -1
@@ 224,9 224,14 @@ def push(writer, steps):
 def push(writer):
     push(writer, 1)
 
+@method(IndentingWriter, int)
+def pop(writer, steps):
+    for count in range(steps):
+        writer.indent = writer.indents.pop()
+
 @method(IndentingWriter)
 def pop(writer):
-    writer.indent = writer.indents.pop()
+    pop(writer, 1)
        
 
 class Object(AbstractObject):