| Conditions | 5 | 
| Paths | 3 | 
| Total Lines | 12 | 
| Code Lines | 6 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Tests | 5 | 
| CRAP Score | 5 | 
| Changes | 0 | ||
| 1 | <?php | ||
| 5 | function decodeOpN($op) | ||
| 6 | { | ||
| 7 | 1636 |     if ($op === Opcodes::OP_0) { | |
| 8 | 172 | return 0; | |
| 9 | } | ||
| 10 | |||
| 11 | 1514 |     if (!($op === Opcodes::OP_1NEGATE || $op >= Opcodes::OP_1 && $op <= Opcodes::OP_16)) { | |
| 12 | 90 |         throw new \RuntimeException("Invalid opcode"); | |
| 13 | } | ||
| 14 | |||
| 15 | 1476 | return (int) $op - (Opcodes::OP_1 - 1); | |
| 16 | } | ||
| 17 | |||
| 30 |