7.5.82 s2i

Convert short to int

Format

s2i

Forms

s2i = 92 (0x5c)

Stack

…, value → …, result.word1, result.word2

Description

The value on top of the operand stack must be of type short. It is popped from the operand stack and sign-extended to an int result. The result is pushed onto the operand stack.

Notes

The s2i instruction performs a widening primitive conversion. Because all values of type short are exactly representable by type int, the conversion is exact.

If a virtual machine does not support the int data type, the s2i instruction will not be available.