JS backend: fixed wrong result when compare null and undefined using Kotlin.equals.
JS backend: fixed trait inheritance implementation in ES3.
Now each traits in same hierarchy represent separate object, instead a single object.
JS backend: added wraping to object the local vars which captured in closure.
Moved local functions and function literals to class/namespace definition.

(cherry picked from commit 36c954b)