Created common functions for typeof

As I mentioned in #251 I'd been thinking about some refactoring of the type functions, and a little code golf.
This PR moves most of the type checking to separate functions, and pulls out the "[object Object]" and "[object Array]" constants.

Code size savings (not sure why the compression isn't as good):

File | Before | After | Savings
----- | ----------- | -------- | -------
mithril.js | 33028 |  32811 | 217
mithril.min.js | 14515 | 14230 | 285
mithril.min.js + xz | 5712 | 5708 | 4
mithril.min.js + gzip | 5813  | 5821 | -8
mithril.min.js + zip | 5939 | 5947|-8
mithril.min.js + bzip | 5716 | 5730 |-14

I don't think that will work. If you look at line ~90, you don't know ahead of time what type you want. You could maybe do:
```javascript
function type(obj) {return {}.toString.call(obj)}
var is = function(s, obj) { return type(obj) == s }
var isObj = is.bind(null, sObj)
var isArr = is.bind(null, sArr)
var isFn = is.bind(null, "[object Function]")
```
but that's 17 characters longer

also, `type(function(){}) != "function"`