js/src/tests/test262/ch12/12.8/S12.8_A4_T1.js

Wed, 31 Dec 2014 13:27:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 13:27:57 +0100
branch
TOR_BUG_3246
changeset 6
8bccb770b82d
permissions
-rw-r--r--

Ignore runtime configuration files generated during quality assurance.

     1 // Copyright 2009 the Sputnik authors.  All rights reserved.
     2 // This code is governed by the BSD license found in the LICENSE file.
     4 /**
     5  * When "break Identifier" is evaluated, (break, empty, Identifier) is returned
     6  *
     7  * @path ch12/12.8/S12.8_A4_T1.js
     8  * @description Using "break Identifier" within labaeled loop
     9  */
    11 LABEL_OUT : var x=0, y=0;
    12 (function(){
    13 LABEL_DO_LOOP : do {
    14     LABEL_IN : x++;
    15     if(x===10)return;
    16     break LABEL_DO_LOOP;
    17     LABEL_IN_2 : y++;
    19     function IN_DO_FUNC(){}
    20 } while(0);
    22 LABEL_ANOTHER_LOOP : do {
    23     ;
    24 } while(0);
    26 function OUT_FUNC(){}
    27 })();
    28 //////////////////////////////////////////////////////////////////////////////
    29 //CHECK#1
    30 if ((x!==1)&&(y!==0)) {
    31 	$ERROR('#1: x === 1 and y === 0. Actual:  x === '+x+' and y ==='+ y  );
    32 }
    33 //
    34 //////////////////////////////////////////////////////////////////////////////

mercurial