(ObjExpr objx, GeneratorAdapter gen, Type exprType, Label defaultLabel)
| 9495 | } |
| 9496 | |
| 9497 | private void emitExprForInts(ObjExpr objx, GeneratorAdapter gen, Type exprType, Label defaultLabel){ |
| 9498 | if (exprType == null) |
| 9499 | { |
| 9500 | if(RT.booleanCast(RT.WARN_ON_REFLECTION.deref())) |
| 9501 | { |
| 9502 | RT.errPrintWriter() |
| 9503 | .format("Performance warning, %s:%d:%d - case has int tests, but tested expression is not primitive.\n", |
| 9504 | SOURCE_PATH.deref(), line, column); |
| 9505 | } |
| 9506 | expr.emit(C.EXPRESSION, objx, gen); |
| 9507 | gen.instanceOf(NUMBER_TYPE); |
| 9508 | gen.ifZCmp(GeneratorAdapter.EQ, defaultLabel); |
| 9509 | expr.emit(C.EXPRESSION, objx, gen); |
| 9510 | gen.checkCast(NUMBER_TYPE); |
| 9511 | gen.invokeVirtual(NUMBER_TYPE, intValueMethod); |
| 9512 | emitShiftMask(gen); |
| 9513 | } |
| 9514 | else if (exprType == Type.LONG_TYPE |
| 9515 | || exprType == Type.INT_TYPE |
| 9516 | || exprType == Type.SHORT_TYPE |
| 9517 | || exprType == Type.BYTE_TYPE) |
| 9518 | { |
| 9519 | expr.emitUnboxed(C.EXPRESSION, objx, gen); |
| 9520 | gen.cast(exprType, Type.INT_TYPE); |
| 9521 | emitShiftMask(gen); |
| 9522 | } |
| 9523 | else |
| 9524 | { |
| 9525 | gen.goTo(defaultLabel); |
| 9526 | } |
| 9527 | } |
| 9528 | |
| 9529 | private void emitThenForInts(ObjExpr objx, GeneratorAdapter gen, Type exprType, Expr test, Expr then, Label defaultLabel, boolean emitUnboxed){ |
| 9530 | if (exprType == null) |
no test coverage detected