fix class cast exception message thinko

This commit is contained in:
Joel Dice 2008-01-15 16:33:20 -07:00
parent 37b33457c1
commit d1b4dfccd0

View File

@ -1498,9 +1498,10 @@ void FORCE_ALIGN
checkCast(MyThread* t, object class_, object o) checkCast(MyThread* t, object class_, object o)
{ {
if (UNLIKELY(o and not isAssignableFrom(t, class_, objectClass(t, o)))) { if (UNLIKELY(o and not isAssignableFrom(t, class_, objectClass(t, o)))) {
object message = makeString(t, "%s as %s", object message = makeString
className(t, objectClass(t, o)), (t, "%s as %s",
className(t, class_)); &byteArrayBody(t, className(t, objectClass(t, o)), 0),
&byteArrayBody(t, className(t, class_), 0));
t->exception = makeClassCastException(t, message); t->exception = makeClassCastException(t, message);
unwind(t); unwind(t);
} }