PHPCfg\Parser::parseExpr_PostDec PHP Method

parseExpr_PostDec() protected method

protected parseExpr_PostDec ( PhpParser\Node\Expr\PostDec $expr )
$expr PhpParser\Node\Expr\PostDec
    protected function parseExpr_PostDec(Expr\PostDec $expr)
    {
        $var = $this->parseExprNode($expr->var);
        $read = $this->readVariable($var);
        $write = $this->writeVariable($var);
        $this->block->children[] = $op = new Op\Expr\BinaryOp\Minus($read, new Operand\Literal(1), $this->mapAttributes($expr));
        $this->block->children[] = new Op\Expr\Assign($write, $op->result, $this->mapAttributes($expr));
        return $read;
    }
Parser