For primitive types, the coercive casts never fail. Let's be lenient and let

a TypedArray of int work if people fill it with strings like "4" or "9".


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4854 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
Ray Greenwell
2007-10-24 21:51:32 +00:00
parent 13fe8fc930
commit 480abdee8a
@@ -105,12 +105,12 @@ public class ArrayStreamer extends Streamer
out.writeInt(arr.length);
if (_elementType == int) {
for (ii = 0; ii < arr.length; ii++) {
out.writeInt(arr[ii] as int);
out.writeInt(int(arr[ii]));
}
} else if (_elementType == Boolean) {
for (ii = 0; ii < arr.length; ii++) {
out.writeBoolean(arr[ii] as Boolean);
out.writeBoolean(Boolean(arr[ii]));
}
} else if (_isFinal) {