Hi Jim, I think bug is here ... Just only have found this place during debug, And need run away for few hours.
static pANTLR3_COMMON_TOKEN newPoolToken(pANTLR3_TOKEN_FACTORY factory) { pANTLR3_COMMON_TOKEN token; /* See if we need a new token pool before allocating a new * one */ if (factory->nextToken >= ANTLR3_FACTORY_POOL_SIZE) <<<<<<<<<<<<<< 1 !! If we have FEW pools then this is wrong. { /* We ran out of tokens in the current pool, so we need a new pool */ newPool(factory); } /* Assuming everything went well (we are trying for performance here so doing minimal * error checking. Then we can work out what the pointer is to the next token. */ token = factory->pools[factory->thisPool] + factory->nextToken; ^^^^^^^^^^^^^^^^^^^^^^ // RZ: nextToken was 1024, we have allocate above new pool // and we should use its ZERO item factory->nextToken++; // and we get 1025 ... It seems to me ... We must nextToken counter drop to zero when we allocate next pool. And may be correct other places ... -- Best regards, Ruslan Zasukhin VP Engineering and New Technology Paradigma Software, Inc Valentina - Joining Worlds of Information http://www.paradigmasoft.com [I feel the need: the need for speed] List: http://www.antlr.org/mailman/listinfo/antlr-interest Unsubscribe: http://www.antlr.org/mailman/options/antlr-interest/your-email-address -- You received this message because you are subscribed to the Google Groups "il-antlr-interest" group. To post to this group, send email to il-antlr-inter...@googlegroups.com. To unsubscribe from this group, send email to il-antlr-interest+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/il-antlr-interest?hl=en.