more efficient validation of bounds argument

The bounds need to be validated, but a simple typeof check won’t
reliably distinguish between numerical and associative arrays. Instead,
we’ll first check to see whether it’s an object AND has all the desired
properties. If not, we’ll see whether it’s a numerical array, first by
running Array.isArray if it is supported, or by casting to string if it
isn’t. If it’s a numerical array, we’ll try to extract the bounds from
the rect (but again, this is still just a placeholder for now). If it’s
neither of the above, then the bounds are wacky and the check returns
false.