1/* 2 * test5200 - 5200 series of the regress.cal test suite 3 * 4 * Copyright (C) 1999 Ernest Bowen and Landon Curt Noll 5 * 6 * Primary author: Ernest Bowen 7 * 8 * Calc is open software; you can redistribute it and/or modify it under 9 * the terms of the version 2.1 of the GNU Lesser General Public License 10 * as published by the Free Software Foundation. 11 * 12 * Calc is distributed in the hope that it will be useful, but WITHOUT 13 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 14 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General 15 * Public License for more details. 16 * 17 * A copy of version 2.1 of the GNU Lesser General Public License is 18 * distributed with calc under the filename COPYING-LGPL. You should have 19 * received a copy with calc; if not, write to Free Software Foundation, Inc. 20 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 21 * 22 * Under source code control: 1997/02/07 02:48:10 23 * File existed as early as: 1997 24 * 25 * Share and enjoy! :-) http://www.isthe.com/chongo/tech/comp/calc/ 26 */ 27 28 29defaultverbose = 1; /* default verbose value */ 30 31/* 32 * test the fix of a global/static bug 33 * 34 * Given the following: 35 * 36 * global a = 10; 37 * static a = 20; 38 * define f(x) = a + x; 39 * define g(x) {global a = 30; return a + x;} 40 * define h(x) = a + x; 41 * 42 * Older versions of 43 */ 44global a5200 = 10; 45static a5200 = 20; 46define f5200(x) = a5200 + x; 47define g5200(x) {global a5200 = 30; return a5200 + x;} 48define h5200(x) = a5200 + x; 49