events: add check for listeners length

Ability to return just the length of listeners for a given type, using
_listenerLength(). This will be a lot cheaper than creating a copy of
the listeners array just to check it's length.
events: ensure usingDomain is always boolean

Small addition to ensure that exports.usingDomains is always a bool.
events: type check setMaxListeners, cleanup errors

setMaxListeners will now make sure a positive number is passed. Also
throwing more definitive Error types.
events: simplify removeAllListeners logic

Unnecessary checks were being performed on if the event existed before
being removed.

_events starts out as null, so reset to null when emptied.

Checking typeof is a lot cheaper than isArray().
events: type check listeners

Make sure the argument passed is a string. Also use typeof == function
check instead of isArray().
events: don't optimize for single fn case

Logic can be greatly simplified by always assuming an array. This will
allow for other optimizations in a near commit.
events: removeListener add checks and cleanup

Remove unecessary splice for single listener events. Add type check for
type.
events: add and cleanup checks for addListener

* Added check to ensure type is a string.
* else if'd the check for newListener if _events hadn't existed before.
* Simplified check for if event had been warned for memory leak.
events: clean up emit

* Export error emission to another function
* WIP