File ChangingGenerator.html    Author McKeeman    Copyright © 2007    index

Changing the Generator Object

Preliminary

First read about the generator.

In MATLAB in the mxcom directory, try

        >> help Generator.m
    
and
        >> xcom -emitTrace -genTrace x:=1
    

Making a Small Change

The Generator object contains tree walking methods. There are a few kinds of walkers, each accounting for some of the rules in X.cfg. In general, each walker switches on the rule name, and within the switch, calls another walker appropriate to each of the subnodes that actually have to be processed.

If a Cfg rule is changed, the corresponding change must be made to the walker.