joyent/node — pull request #7991 by sam-github (2014-07-23 21:32:04+00:00)
Title: process: throw TypeError if kill pid not a number

Fix joyent/node#7962

Note that this PR *disallows* string forms of process ids, so will break code like:

```
// kill.js
process.kill(process.argv[2])
```

called as `node kill.js 6543`.

I could allow string forms of numbers, but disallow strings that are NOT numbers, I could also allow both null and undefined to convert to 0, meaning self, but that seems weird. Note that `+null` is `0` in js, and `+undefined` is `NaN`, though how much sense that makes, I'm not sure.

Node, in general, does precious little argument checking, its hard to know what would be expected (other than calling APIs in contradiction of their docs is not going to work well).