Lines Matching refs:rewrites
318 ANTLRHashMap *rewrites = [self getProgram:programName];
319 op.instructionIndex = [rewrites count];
320 [rewrites addObject:op];
354 ANTLRHashMap *rewrites = (ANTLRHashMap *)[lastRewriteTokenIndexes getName:programName];
355 op.instructionIndex = [rewrites count];
356 [rewrites addObject:op];
461 ANTLRHashMap *rewrites = (ANTLRHashMap *)[programs getName:programName];
468 if ( rewrites == nil || [rewrites count] == 0 ) {
474 ANTLRHashMap *indexToOp = [self reduceToSingleOperationPerIndex:rewrites];
556 - (ANTLRHashMap *)reduceToSingleOperationPerIndex:(ANTLRHashMap *)rewrites
558 //System.out.println("rewrites="+rewrites);
559 if (debug > 1) NSLog(@"rewrites=%@\n", [rewrites getName:DEFAULT_PROGRAM_NAME]);
561 for (int i = 0; i < [rewrites count]; i++) {
562 ANTLRRewriteOperation *op = (ANTLRRewriteOperation *)[rewrites objectAtIndex:i];
567 ANTLRReplaceOp *rop = (ANTLRReplaceOp *)[rewrites objectAtIndex:i];
569 //List inserts = getKindOfOps(rewrites, ANTLRInsertBeforeOp.class, i);
570 …ANTLRHashMap *inserts = [self getKindOfOps:rewrites KindOfClass:[ANTLRInsertBeforeOp class] Index:…
575 [rewrites insertObject:nil atIndex:iop.instructionIndex];
579 …ANTLRHashMap *prevReplaces = [self getKindOfOps:rewrites KindOfClass:[ANTLRReplaceOp class] Index:…
584 [rewrites setObject:nil atIndex:prevRop.instructionIndex];
598 for (int i = 0; i < [rewrites count]; i++) {
599 ANTLRRewriteOperation *op = (ANTLRRewriteOperation *)[rewrites objectAtIndex:i];
604 ANTLRInsertBeforeOp *iop = (ANTLRInsertBeforeOp *)[rewrites objectAtIndex:i];
606 …ANTLRHashMap *prevInserts = (ANTLRHashMap *)[self getKindOfOps:rewrites KindOfClass:[ANTLRInsertBe…
614 [rewrites setObject:nil atIndex:prevIop.instructionIndex];
618 …ANTLRHashMap *prevReplaces = (ANTLRHashMap *)[self getKindOfOps:rewrites KindOfClass:[ANTLRReplace…
623 [rewrites setObject:nil atIndex:i]; // delete current insert
631 // System.out.println("rewrites after="+rewrites);
633 for (int i = 0; i < [rewrites count]; i++) {
634 ANTLRRewriteOperation *op = (ANTLRRewriteOperation *)[rewrites objectAtIndex:i];
659 - (ANTLRHashMap *)getKindOfOps:(ANTLRHashMap *)rewrites KindOfClass:(Class)kind
661 return [self getKindOfOps:rewrites KindOfClass:kind Index:[rewrites count]];
665 - (ANTLRHashMap *)getKindOfOps:(ANTLRHashMap *)rewrites KindOfClass:(Class)kind Index:(NSInteger)be…
668 for (int i = 0; i < before && i < [rewrites count]; i++) {
669 ANTLRRewriteOperation *op = (ANTLRRewriteOperation *)[rewrites objectAtIndex:i];