} elsif (my $meth = $self->can("_handle_op_special_${op_name}")) {
return $self->$meth($dq);
}
- #die "Couldn't render operator ".$op->{$self->_operator_type};
- $self->_handle_op_type_binop($op_name, $dq);
+ if (my $argc = @{$dq->{args}}) {
+ if ($argc == 1) {
+ return $self->_handle_op_type_unop($op_name, $dq);
+ } elsif ($argc == 2) {
+ return $self->_handle_op_type_binop($op_name, $dq);
+ }
+ }
+ die "Unsure how to handle ${op_name}";
}
sub _handle_op_type_binop {