X-Git-Url: http://git.roojs.org/?a=blobdiff_plain;f=JSDOC%2FCompressWhite.vala;h=9171f984bd4610eee1374ad68227e2145194b94c;hb=27b8511a36d2c667f4053792b332e334e00caa9e;hp=fe1479f0e7286c9c017f8f30a1b80a55ffbc4119;hpb=c51b68933e0b4113494a395a8d09acd88f055936;p=gnome.introspection-doc-generator diff --git a/JSDOC/CompressWhite.vala b/JSDOC/CompressWhite.vala index fe1479f..9171f98 100644 --- a/JSDOC/CompressWhite.vala +++ b/JSDOC/CompressWhite.vala @@ -17,6 +17,8 @@ namespace JSDOC { //keepWhite = keepWhite || false; ts.rewind(); + this.dumpAllFlat(); GLib.Process.exit(1); + //var str = File.read(fn); var rep_var = 1; @@ -76,14 +78,16 @@ namespace JSDOC if (ts.lookTok(1).data == "=" && ts.lookTok(2).name == "FUNCTION") { // freeze time.. //println("got = function() "); - tok = ts.next(); - tok = ts.next(); + tok = ts.nextTok(); + tok = ts.nextTok(); + //tok = ts.next(); - - var cu = ts.cursor; + var cu = ts.cursor; + print("NEXT = should be brac: %s\n", ts.lookTok(1).asString()); + + print("cursor = %d", ts.cursor); if (ts.lookTok(1).data != "(" || ts.balance("(").size < 1 ){ - print("balance ( issue on line %d\n", ts.toArray().get(cu).line); ts.dump(cu-40, cu+2); print(">>>>>>>>>>>>>>>>>HERE>>>>>>>>>>>>"); @@ -91,10 +95,13 @@ namespace JSDOC throw new CompressWhiteError.BRACE( "could not find end lbrace!!!" ); } - tok = ts.lookTok(0); - + print("cursor = %d", ts.cursor); + print("CUR = should be ): %s\n", ts.lookTok(0).asString()); + + tok = ts.nextTok(); + print("CUR = should be {: %s\n", ts.lookTok(0).asString()); cu = ts.cursor; // set the cursor to here.. so the next bit of the code will check inside the method. - + print("cursor = %d", ts.cursor); //print("AFTER BALANCE ("); //ts.dump(cu, ts.cursor); //ts.cursor--; // cursor at the (