Status: New Owner: ---- Labels: Type-Defect Priority-Low
New issue 1106 by mikesamuel: Misparsed constructor operators http://code.google.com/p/google-caja/issues/detail?id=1106 When the first operand to a function call is an argumentless constructor: (new Function)() we misparse it to be equivalent to new Function() These are not equivalent since typeof ((new Function)()) === 'undefined' typeof ((new Function())) === 'function' This is not a serious problem since our renderer outputs code with the interpretation our parser chooses, and the first idiom is unlikely to be used in practice. But we are producing incorrect (if not unsafe) code for the following: function C() { return function () { return 8; }; } (new C)() === 8 (new C()) !== 8 -- You received this message because you are listed in the owner or CC fields of this issue, or because you starred this issue. You may adjust your issue notification preferences at: http://code.google.com/hosting/settings
