javascript中“ throw new Error”和“ throw someObject”之间的区别在于throw new Error以以下格式包装传递给它的错误-
{ name: 'Error', message: 'Whatever you pass in the constructor' }
throw someObject将按原样抛出对象,并且将不允许从try块执行任何进一步的代码,即与throw new Error相同。