JSDOC/TextStream.vala
[gnome.introspection-doc-generator] / JSDOC / TextStream.vala
index 9182c28..a68d2a7 100644 (file)
@@ -48,23 +48,25 @@ namespace JSDOC {
             return  false
         },
         
-    
-        public char next(int n = 1,  out bool eof)
+        /**
+         * @param n - number of characters to return..
+         */
+        public string next(int n = 1)
         {
-            eof = false;
+            
             if (n < 1) { //?? eof???
                 return '\0';
             }
                 
-            char pulled;
+            string pulled;
             var i = 0;
             while (i < n) {
                 if (this.cursor+i < this.length) {
                     pulled += this.text.get_char(this.cursor+i);
-                    i+=pulled.to_string.length();
+                    i += pulled.to_string.length();
                 } else {
-                    eof =true;
-                    return '\0';
+                     
+                    return "";
                     
                     
                 }