From 11f2cd451508d0fc2a238871379ece8302b657ca Mon Sep 17 00:00:00 2001 From: Jann Horn Date: Mon, 20 Jun 2011 18:38:07 +0200 Subject: [PATCH] test for #1416: don't omit one 'new' when compiling 'new new' --- test/function_invocation.coffee | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/function_invocation.coffee b/test/function_invocation.coffee index d4ff8e1f..fbf2ff7c 100644 --- a/test/function_invocation.coffee +++ b/test/function_invocation.coffee @@ -491,3 +491,7 @@ test "#1420: things like `(fn() ->)`; there are no words for this one", fn = -> (f) -> f() nonce = {} eq nonce, (fn() -> nonce) + +test "#1416: don't omit one 'new' when compiling 'new new'", -> + obj = new new Function "this.foo = 3" + eq obj.foo, 3