]> granicus.if.org Git - re2c/commitdiff
- Change comment when num tables > 8
authorhelly <helly@642ea486-5414-0410-9d7f-a0204ed87703>
Mon, 1 May 2006 18:01:57 +0000 (18:01 +0000)
committerhelly <helly@642ea486-5414-0410-9d7f-a0204ed87703>
Mon, 1 May 2006 18:01:57 +0000 (18:01 +0000)
code.cc
test/bug1479044.b.c

diff --git a/code.cc b/code.cc
index 2ca271a38825e7a0abd1c7fc2dc64c1c69a76951..931a44900aa109f61be1004d6e819ea965cb168e 100644 (file)
--- a/code.cc
+++ b/code.cc
@@ -221,7 +221,7 @@ void BitMap::gen(std::ostream &o, uint ind, uint lb, uint ub)
 
                uint *bm = new uint[n];
                
-               for (uint i = 0, t = 0; b; i += n)
+               for (uint i = 0, t = 1; b; i += n, t += 8)
                {
                        memset(bm, 0, n * sizeof(uint));
 
@@ -235,7 +235,7 @@ void BitMap::gen(std::ostream &o, uint ind, uint lb, uint ub)
 
                        if (c > 8)
                        {
-                               o << "\n" << indent(ind+1) << "/* table " << ++t << ": " << i << " */";
+                               o << "\n" << indent(ind+1) << "/* table " << t << " .. " << std::min(c, t+7) << ": " << i << " */";
                        }
 
                        for (uint j = 0; j < n; ++j)
index bf825fe88ca2e193c87077eca6ca3a28b9158d08..ebb2f5870fa2b4283b1e31b02d697fd710c7afed 100755 (executable)
@@ -15,7 +15,7 @@ char *scan281(char *p)
 start:
 {
        static unsigned char yybm[] = {
-               /* table 1: 0 */
+               /* table 1 .. 8: 0 */
                170, 170, 170, 170, 170, 170, 170, 170, 
                170, 170,   0, 170, 170, 170, 170, 170, 
                170, 170, 170, 170, 170, 170, 170, 170, 
@@ -48,7 +48,7 @@ start:
                170, 170, 170, 170, 170, 170, 170, 170, 
                170, 170, 170, 170, 170, 170, 170, 170, 
                170, 170, 170, 170, 170, 170, 170, 170, 
-               /* table 2: 256 */
+               /* table 9 .. 10: 256 */
                128, 128, 128, 128, 128, 128, 128, 128, 
                128, 128,   0, 128, 128, 128, 128, 128, 
                128, 128, 128, 128, 128, 128, 128, 128,