JDK-8030182_2.js revision 1875:ea1d4ecf5862
11638Srgrimes/* 21638Srgrimes * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved. 31638Srgrimes * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 41638Srgrimes * 51638Srgrimes * This code is free software; you can redistribute it and/or modify it 61638Srgrimes * under the terms of the GNU General Public License version 2 only, as 71638Srgrimes * published by the Free Software Foundation. 81638Srgrimes * 91638Srgrimes * This code is distributed in the hope that it will be useful, but WITHOUT 101638Srgrimes * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 111638Srgrimes * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 121638Srgrimes * version 2 for more details (a copy is included in the LICENSE file that 131638Srgrimes * accompanied this code). 141638Srgrimes * 151638Srgrimes * You should have received a copy of the GNU General Public License version 161638Srgrimes * 2 along with this work; if not, write to the Free Software Foundation, 171638Srgrimes * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 181638Srgrimes * 191638Srgrimes * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 201638Srgrimes * or visit www.oracle.com if you need additional information or have any 211638Srgrimes * questions. 221638Srgrimes */ 231638Srgrimes 241638Srgrimes/** 251638Srgrimes * JDK-8030182: scopeCall with -1 as line number 261638Srgrimes * 271638Srgrimes * @test 281638Srgrimes * @run 291638Srgrimes */ 301638Srgrimes 311638Srgrimesvar str = ""; 321638Srgrimes 3350476Speter// large code to force splitting 341638Srgrimesfor (i = 0; i < 2000; ++i) 351638Srgrimes str +="o = new Object()\n"; 361638Srgrimes 371638Srgrimesstr +="g()"; 381638Srgrimes 391638Srgrimes// check that "$split" or some such internal method 401638Srgrimes// does not appear in script stack trace!! 411638Srgrimestry { 421638Srgrimes eval(str); 431638Srgrimes} catch (e) { 441638Srgrimes print(e.stack.replace(/\\/g, '/')); 451638Srgrimes} 461638Srgrimes 471638Srgrimes