michael@0: // Copyright 2009 the Sputnik authors. All rights reserved. michael@0: // This code is governed by the BSD license found in the LICENSE file. michael@0: michael@0: /** michael@0: * In the "if" statement empty statement is allowed and is evaluated to "undefined" michael@0: * michael@0: * @path ch12/12.5/S12.5_A7.js michael@0: * @description Checking by using eval "eval("if(1);"))" michael@0: */ michael@0: michael@0: ////////////////////////////////////////////////////////////////////////////// michael@0: //CHECK#1 michael@0: try { michael@0: var __evaluated = eval("if(1);"); michael@0: if (__evaluated !== undefined) { michael@0: $ERROR('#1: __evaluated === undefined. Actual: __evaluated ==='+ __evaluated ); michael@0: } michael@0: michael@0: } catch (e) { michael@0: $ERROR('#1.1: "__evaluated = eval("if(1);")" does not lead to throwing exception'); michael@0: michael@0: } michael@0: // michael@0: ////////////////////////////////////////////////////////////////////////////// michael@0: