Exemplo n.º 1
0
 public override void ExitPEffect(pddlParser.PEffectContext ctx)
 {
     /*
      * self.negativescopes.pop()
      */
     this.negativescopes.Pop();
 }
Exemplo n.º 2
0
        public override void EnterPEffect(pddlParser.PEffectContext ctx)
        {
            /*
             * negscope = False
             * for c in ctx.getChildren():
             *  if c.getText() == 'not':
             *      negscope = True
             *      break
             * self.negativescopes.append(negscope)
             */
            var negscope = false;

            for (int i = 0; i < ctx.ChildCount; i++)
            {
                var c = ctx.GetChild(i);
                if (c.GetText() == "not")
                {
                    negscope = true;
                    break;
                }
            }
            this.negativescopes.Push(negscope);
        }