Class CAstRewriter<C extends CAstRewriter.RewriteContext<K>,​K extends CAstRewriter.CopyKey<K>>

  • Type Parameters:
    C - type of the RewriteContext used when traversing the original CAst during the rewrite operation
    K - a key used to ease cloning of partial ASTs. When rewriting an AST, sub-classes maintain a mapping from (original node, key) pairs (where key is of type K) to new nodes; see #copyNodes(CAstNode, RewriteContext, Map)
    Direct Known Subclasses:
    AstLoopUnwinder, CAstBasicRewriter

    public abstract class CAstRewriter<C extends CAstRewriter.RewriteContext<K>,​K extends CAstRewriter.CopyKey<K>>
    extends Object
    Abstract superclass for types performing a rewrite operation on a CAst. The CAst is not mutated; instead, a new CAst is created which delegates to the original CAst where no transformation was performed.