[Extensions] Pretty print for JS exceptions in the native code

Instead of just printing a warning, give the developer the line
number and possible a clue about what is going on.
Merge pull request #776 from tmpsantos/try_catch

[Extensions] Pretty print for JS exceptions in the native code