JSDOC/TokenReader.vala
authorAlan Knowles <alan@roojs.com>
Tue, 15 Sep 2015 09:15:28 +0000 (17:15 +0800)
committerAlan Knowles <alan@roojs.com>
Tue, 15 Sep 2015 09:15:28 +0000 (17:15 +0800)
JSDOC/TokenReader.vala

index b49ffcc..15d6319 100644 (file)
@@ -41,6 +41,14 @@ namespace JSDOC {
         public void push (Token t) {
             this.tokens.add(t);
         }
+        public Token? pop ()
+        {
+            if (this.size > 0) {
+                return this.tokens.remove_at(this.size-1);
+            }
+            return null;
+        }
+        
         public Token get(int i) {
             return this.tokens.get(i);
         }