src: fix Environment::GetCurrent() usage

Create a HandleScope before calling the Environment::GetCurrent() that
takes a v8::Isolate* as an argument because it creates a handle with
the call to v8::Isolate::CurrentContext().
src: remove global HandleScope

Make it more difficult to accidentally leak handles by removing the
top-level HandleScope.  Now if there's no valid HandleScope now, V8
will complain and, in debug builds, abort.
crypto: fix up implicit HandleScope abuse

Don't depend on any HandleScope objects that may or may not have been
created in src/stream_wrap.cc, create them explicitly.
src: fix Context::Scope usage

env->context() may or may not create a new Local.  It currently does
not but don't depend on that behavior, create a HandleScope first.
src: use Context::Scope objects in cares_wrap.cc

Enter the context explicitly, don't rely on the fact that there is a
Context::Scope a few stack frames below because it may be gone someday
tls_wrap: move members to initialization list

They didn't need to be defined in the body of the constructor.
async-wrap: make typenames consistent
base-object: add BaseObject

BaseObject is a class that just handles the Persistent handle attached
to the class instance.

This also removed WeakObject. Reordering the inheritance chain helps
prevent unneeded calls on instances that don't call MakeCallback.
src: add comments about implicit dependencies
smalloc: check if object has external memory

Add HasExternalData API to check if Object has externally allocated
memory, and accompanying tests.
doc: fix few smalloc entries for proper formatting
src: remove unused import in cares_wrap.cc
buffer: no warning when encoding isn't passed

Buffer#write() was showing the deprecation warning when only
buf.write('string') was passed. This is incorrect since the encoding is
always optional.

Argument order should follow:
  Buffer#write(string[, offset[, length]][, encoding])

(yeah, not confusing at all)
src: make buffer size errors more explicit

Fixes #6490
buffer: convert values to uint, not int

In many cases values expected to be unsigned were converted to a signed
integer.

Also include some small code cleanup.
debugger: pass on v8 debug switches

Before this commit, passing --debugger and other V8 debug switches to
node.js made node print a usage message and exit.

Rewrite the debug argument parser so it only consumes switches that we
understand and pass everything else as-is to V8.

A side effect of this change is that switches like --debugger_agent and
--debugger_port now work.  That kind of obsoletes our debugger switches
because they implement pretty much the same functionality but let's
leave them in for now for the sake of convenience and backwards
compatibility.

Fixes #6526.