raven-compiler/src/main/java/org/raven/compiler/Method.java
/**
     * Assumes value is on stack
     *
     * @param type
     */
Assumes value is on stack
@param type
Assumes value is on stack @param type
private void coerce(final Type type) {
        Primitive p = Primitive.getPrimitiveType(type.getDescriptor());
        if (p == null) {
            visitLdcInsn(type);
        } else {
            p.putPrimitiveType(this);
        }
        visitMethodInsn(INVOKEVIRTUAL, Constants.TOBJ_NAME, "coerce", getDesc(TObject.class, "coerce", Class.class), false);
        if (p != null) {
            p.unwrap(this);
        } else {
            visitTypeInsn(CHECKCAST, type.getInternalName());
        }
    }
private void coerce ( final Type type ) { Primitive p = Primitive . getPrimitiveType ( type . getDescriptor ( ) ) ; if ( p == null ) { visitLdcInsn ( type ) ; } else { p . putPrimitiveType ( this ) ; } visitMethodInsn ( INVOKEVIRTUAL , Constants . TOBJ_NAME , "coerce" , getDesc ( TObject . class , "coerce" , Class . class ) , false ) ; if ( p != null ) { p . unwrap ( this ) ; } else { visitTypeInsn ( CHECKCAST , type . getInternalName ( ) ) ; } }
Assumes value is on stack
 @param type
Assumes value is on stack @param type