From: Andreas Gal Date: Tue, 3 May 2011 02:07:16 +0000 (-0700) Subject: no need to freeze constructors and protos X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=2040b871da7cc30cd23a27a0033a5171d164f8b6;p=pdf.js.git no need to freeze constructors and protos --- diff --git a/pdf.js b/pdf.js index 62317e6..e78b323 100644 --- a/pdf.js +++ b/pdf.js @@ -53,12 +53,10 @@ var Obj = (function() { } } - Object.freeze(constructor.trueObj = new constructor(constructor.Bool, true)); - Object.freeze(constructor.falseObj = new constructor(constructor.Bool, false)); - Object.freeze(constructor.nullObj = new constructor(constructor.Null)); - Object.freeze(constructor.errorObj = new constructor(constructor.Error)); - Object.freeze(constructor.prototype); - Object.freeze(constructor); + constructor.trueObj = new constructor(constructor.Bool, true); + constructor.falseObj = new constructor(constructor.Bool, false); + constructor.nullObj = new constructor(constructor.Null); + constructor.errorObj = new constructor(constructor.Error); return constructor; })(); @@ -369,8 +367,6 @@ var Lexer = (function() { } }; - Object.freeze(constructor.prototype); - Object.freeze(constructor); return constructor; })(); @@ -475,9 +471,6 @@ var Parser = (function() { } }; - Object.freeze(constructor.prototype); - Object.freeze(constructor); - return constructor; })();