(Integer I, int kind)
| 703 | } |
| 704 | |
| 705 | static int intUnaryOperation(Integer I, int kind) |
| 706 | { |
| 707 | int operand = I.intValue(); |
| 708 | |
| 709 | switch(kind) |
| 710 | { |
| 711 | case PLUS: |
| 712 | return operand; |
| 713 | case MINUS: |
| 714 | return -operand; |
| 715 | case TILDE: |
| 716 | return ~operand; |
| 717 | case INCR: |
| 718 | return operand + 1; |
| 719 | case DECR: |
| 720 | return operand - 1; |
| 721 | default: |
| 722 | throw new InterpreterError("bad integer unaryOperation"); |
| 723 | } |
| 724 | } |
| 725 | |
| 726 | static long longUnaryOperation(Long L, int kind) |
| 727 | { |
no test coverage detected