2012-07-02から1日間の記事一覧
https://github.com/myatsumoto/wabi とりあえず作った。速度や細かい処理に関しては後々修正する
var HogeError = function(){ Error.apply(this, arguments); }; HogeError.prototype = new Error; try { throw new HogeError(); } catch(e) { if (e instanceof HogeError) { console.log("success"); } else { console.log("failure"); } }