- return Forest.create(loc, (T)tag, args2, true, false, p);
+ return Forest.create(loc, (T)tag, args2, true);
+ }
+ }
+
+
+
+ static class RegionRewritingSequence extends RewritingSequence {
+ private Functor<Input.Region, Object> tagf;
+ public RegionRewritingSequence(Functor<Input.Region,Object> tagfunctor, Element[] e, boolean[] drops) {
+ super(null, e, drops);
+ this.tagf = tagfunctor;
+ }
+ public <T> Forest<T> postReduce(Input.Region loc, Forest<T>[] args, Position p) {
+ this.tag = tagf.invoke(loc);
+ Forest<T> ret = super.postReduce(loc, args, p);
+ this.tag = null;
+ return ret;