[Nice-commit] Nice/src/bossa/syntax scope.nice,NONE,1.1 Node.java,1.61,1.62 dispatch.java.bootstrap,
Brought to you by:
bonniot
From: Arjan B. <ar...@us...> - 2004-12-19 16:49:37
|
Update of /cvsroot/nice/Nice/src/bossa/syntax In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28179/F:/nice/src/bossa/syntax Modified Files: Node.java dispatch.java.bootstrap tools.nice Added Files: scope.nice Removed Files: GlobalVarScope.java Log Message: Converted GlobalVarScope. Index: tools.nice =================================================================== RCS file: /cvsroot/nice/Nice/src/bossa/syntax/tools.nice,v retrieving revision 1.79 retrieving revision 1.80 diff -C2 -d -r1.79 -r1.80 *** tools.nice 19 Dec 2004 13:35:48 -0000 1.79 --- tools.nice 19 Dec 2004 16:49:14 -0000 1.80 *************** *** 287,291 **** ?Iterator<MethodDeclaration> listSpecializedMethods(MethodDeclaration) = native Iterator MethodDeclaration.listSpecializedMethods(); Monotype[] Monotype_toArray(?List<Monotype>) = native Monotype[] Monotype.toArray(List); ! // Retypings needed since java types are not strict. --- 287,291 ---- ?Iterator<MethodDeclaration> listSpecializedMethods(MethodDeclaration) = native Iterator MethodDeclaration.listSpecializedMethods(); Monotype[] Monotype_toArray(?List<Monotype>) = native Monotype[] Monotype.toArray(List); ! List<VarSymbol> lookup(VarScope, LocatedString) = native List VarScope.lookup(LocatedString); // Retypings needed since java types are not strict. Index: Node.java =================================================================== RCS file: /cvsroot/nice/Nice/src/bossa/syntax/Node.java,v retrieving revision 1.61 retrieving revision 1.62 diff -C2 -d -r1.61 -r1.62 *** Node.java 21 Nov 2004 23:24:37 -0000 1.61 --- Node.java 19 Dec 2004 16:49:14 -0000 1.62 *************** *** 128,133 **** */ ! private static GlobalVarScope globalScope; ! public static final GlobalVarScope getGlobalScope() { return globalScope; --- 128,133 ---- */ ! private static VarScope globalScope; ! public static final VarScope getGlobalScope() { return globalScope; *************** *** 147,151 **** { JavaClasses.compilation = module.compilation(); ! globalScope = new GlobalVarScope(); globalTypeScope = new GlobalTypeScope(); } --- 147,151 ---- { JavaClasses.compilation = module.compilation(); ! globalScope = dispatch.createGlobalVarScope(); globalTypeScope = new GlobalTypeScope(); } Index: dispatch.java.bootstrap =================================================================== RCS file: /cvsroot/nice/Nice/src/bossa/syntax/dispatch.java.bootstrap,v retrieving revision 1.38 retrieving revision 1.39 diff -C2 -d -r1.38 -r1.39 *** dispatch.java.bootstrap 19 Dec 2004 03:40:59 -0000 1.38 --- dispatch.java.bootstrap 19 Dec 2004 16:49:14 -0000 1.39 *************** *** 13,16 **** --- 13,19 ---- public class dispatch { + static VarScope createGlobalVarScope() + { return null; } + static String getAlikeID() { return null; } --- GlobalVarScope.java DELETED --- --- NEW FILE: scope.nice --- /**************************************************************************/ /* N I C E */ /* A high-level object-oriented research language */ /* (c) Daniel Bonniot 2004 */ /* */ /* This program is free software; you can redistribute it and/or modify */ /* it under the terms of the GNU General Public License as published by */ /* the Free Software Foundation; either version 2 of the License, or */ /* (at your option) any later version. */ /* */ /**************************************************************************/ package bossa.syntax; /** The global scope of symbols. */ public class GlobalVarScope extends VarScope { lookup(i) { // If there is any method by that name waiting, load it. JavaClasses.nameRequired(i.toString()); return super; } } VarScope createGlobalVarScope() { return new GlobalVarScope(null); } |