nice-commit Mailing List for The Nice Programming Language (Page 14)
Brought to you by:
bonniot
You can subscribe to this list here.
2003 |
Jan
|
Feb
(60) |
Mar
(125) |
Apr
(183) |
May
(140) |
Jun
(227) |
Jul
(141) |
Aug
(181) |
Sep
(75) |
Oct
(89) |
Nov
(187) |
Dec
(162) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(69) |
Feb
(197) |
Mar
(98) |
Apr
(26) |
May
(10) |
Jun
(85) |
Jul
(88) |
Aug
(79) |
Sep
(80) |
Oct
(81) |
Nov
(53) |
Dec
(109) |
2005 |
Jan
(68) |
Feb
(77) |
Mar
(232) |
Apr
(79) |
May
(37) |
Jun
(37) |
Jul
(3) |
Aug
(18) |
Sep
|
Oct
|
Nov
|
Dec
|
2006 |
Jan
(10) |
Feb
|
Mar
(4) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
(1) |
Dec
(9) |
2007 |
Jan
(2) |
Feb
(8) |
Mar
(2) |
Apr
(5) |
May
|
Jun
|
Jul
|
Aug
(4) |
Sep
|
Oct
|
Nov
(17) |
Dec
(6) |
2008 |
Jan
|
Feb
(3) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2011 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Arjan B. <ar...@us...> - 2005-03-12 15:06:53
|
Update of /cvsroot/nice/Nice/testsuite/compiler/methods In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11641/F:/nice/testsuite/compiler/methods Modified Files: boolean.testsuite optionalParameters.testsuite Log Message: Added some missing failure positions. Index: optionalParameters.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/methods/optionalParameters.testsuite,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** optionalParameters.testsuite 23 Jun 2004 19:38:09 -0000 1.9 --- optionalParameters.testsuite 12 Mar 2005 15:06:10 -0000 1.10 *************** *** 6,14 **** /// FAIL /// Toplevel ! int test(int x = x) = x; /// FAIL /// Toplevel ! int test(int x = y, int y = x) = y; /// PASS --- 6,14 ---- /// FAIL /// Toplevel ! int test(int x = /* /// FAIL HERE */ x) = x; /// FAIL /// Toplevel ! int test(int x = /* /// FAIL HERE */ y, int y = x) = y; /// PASS Index: boolean.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/methods/boolean.testsuite,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** boolean.testsuite 1 Mar 2005 18:56:21 -0000 1.3 --- boolean.testsuite 12 Mar 2005 15:06:10 -0000 1.4 *************** *** 28,32 **** /// FAIL /// Toplevel ! boolean or(a, b); // Ambiguity for the case (@true, @true) or(true, boolean b) = true; --- 28,32 ---- /// FAIL /// Toplevel ! boolean /* /// FAIL HERE */ or(boolean a, boolean b); // Ambiguity for the case (@true, @true) or(true, boolean b) = true; *************** *** 36,40 **** /// FAIL /// Toplevel ! boolean nor(boolean, boolean); nor(true, true) = false; nor(true, false) = false; --- 36,40 ---- /// FAIL /// Toplevel ! boolean /* /// FAIL HERE */ nor(boolean, boolean); nor(true, true) = false; nor(true, false) = false; |
From: Arjan B. <ar...@us...> - 2005-03-12 15:06:52
|
Update of /cvsroot/nice/Nice/testsuite/compiler/functions In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11641/F:/nice/testsuite/compiler/functions Modified Files: local.testsuite Log Message: Added some missing failure positions. Index: local.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/functions/local.testsuite,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** local.testsuite 22 May 2003 12:34:48 -0000 1.3 --- local.testsuite 12 Mar 2005 15:06:10 -0000 1.4 *************** *** 20,22 **** /// FAIL ! String f(int i) { if (false) throw new Error(); } --- 20,22 ---- /// FAIL ! String /* /// FAIL HERE */ f(int i) { if (false) throw new Error(); } |
From: Arjan B. <ar...@us...> - 2005-03-12 15:06:52
|
Update of /cvsroot/nice/Nice/testsuite/compiler/enums In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11641/F:/nice/testsuite/compiler/enums Modified Files: enum.testsuite Log Message: Added some missing failure positions. Index: enum.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/enums/enum.testsuite,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** enum.testsuite 5 Jul 2004 08:22:25 -0000 1.9 --- enum.testsuite 12 Mar 2005 15:06:08 -0000 1.10 *************** *** 22,28 **** /// Toplevel enum Color {red, blue, green} ! void foo(Color); ! foo(red) = {}; ! foo(blue) = {}; /// PASS --- 22,28 ---- /// Toplevel enum Color {red, blue, green} ! void /* /// FAIL HERE */ foo(Color); ! foo(red) {} ! foo(blue) {} /// PASS *************** *** 37,41 **** /// FAIL /// Toplevel ! enum Single { thing } /// PASS --- 37,41 ---- /// FAIL /// Toplevel ! enum Single { thing /* /// FAIL HERE */ } /// PASS |
From: Arjan B. <ar...@us...> - 2005-03-12 15:06:52
|
Update of /cvsroot/nice/Nice/testsuite/compiler/classes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11641/F:/nice/testsuite/compiler/classes Modified Files: extends.testsuite initializer.testsuite Log Message: Added some missing failure positions. Index: initializer.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/classes/initializer.testsuite,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** initializer.testsuite 4 Mar 2005 02:25:02 -0000 1.18 --- initializer.testsuite 12 Mar 2005 15:06:06 -0000 1.19 *************** *** 19,23 **** { int i; ! { int j = i + true; } } --- 19,23 ---- { int i; ! { int j = i /* /// FAIL HERE */ + true; } } Index: extends.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/classes/extends.testsuite,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** extends.testsuite 19 Feb 2003 18:33:53 -0000 1.5 --- extends.testsuite 12 Mar 2005 15:06:06 -0000 1.6 *************** *** 32,40 **** /// FAIL /// Toplevel ! class A extends A {} /// FAIL /// Toplevel ! class A extends B {} class B extends A {} --- 32,40 ---- /// FAIL /// Toplevel ! class /* /// FAIL HERE */ A extends A {} /// FAIL /// Toplevel ! class /* /// FAIL HERE */ A extends B {} class B extends A {} |
From: Arjan B. <ar...@us...> - 2005-03-12 15:06:52
|
Update of /cvsroot/nice/Nice/testsuite/compiler/expressions/operators In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11641/F:/nice/testsuite/compiler/expressions/operators Modified Files: comparison.testsuite Log Message: Added some missing failure positions. Index: comparison.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/expressions/operators/comparison.testsuite,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** comparison.testsuite 8 Apr 2003 13:57:47 -0000 1.3 --- comparison.testsuite 12 Mar 2005 15:06:09 -0000 1.4 *************** *** 9,13 **** /// FAIL ! boolean b = 1 > 0 < 2; /// PASS bug --- 9,13 ---- /// FAIL ! boolean b = 1 > 0 /* /// FAIL HERE */ < 2; /// PASS bug |
From: Arjan B. <ar...@us...> - 2005-03-12 15:06:52
|
Update of /cvsroot/nice/Nice/testsuite/compiler/designByContract In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11641/F:/nice/testsuite/compiler/designByContract Modified Files: classFunctions.testsuite classMethods.testsuite functions.testsuite methods.testsuite Log Message: Added some missing failure positions. Index: methods.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/designByContract/methods.testsuite,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** methods.testsuite 22 Jul 2004 16:14:54 -0000 1.8 --- methods.testsuite 12 Mar 2005 15:06:07 -0000 1.9 *************** *** 21,25 **** /// Toplevel void f(int x) ! ensures result == result; f(x) {} --- 21,25 ---- /// Toplevel void f(int x) ! ensures /* /// FAIL HERE */ result == result; f(x) {} Index: classMethods.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/designByContract/classMethods.testsuite,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** classMethods.testsuite 27 Jul 2003 13:14:44 -0000 1.2 --- classMethods.testsuite 12 Mar 2005 15:06:07 -0000 1.3 *************** *** 26,30 **** class A { void f(int x) ! ensures result == result; f(x) {} --- 26,30 ---- class A { void f(int x) ! ensures /* /// FAIL HERE */ result == result; f(x) {} Index: functions.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/designByContract/functions.testsuite,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** functions.testsuite 27 Jul 2003 13:14:44 -0000 1.4 --- functions.testsuite 12 Mar 2005 15:06:07 -0000 1.5 *************** *** 19,23 **** /// Toplevel void f(int x) ! ensures result == result {} --- 19,23 ---- /// Toplevel void f(int x) ! ensures /* /// FAIL HERE */ result == result {} Index: classFunctions.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/designByContract/classFunctions.testsuite,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** classFunctions.testsuite 27 Jul 2003 13:14:44 -0000 1.2 --- classFunctions.testsuite 12 Mar 2005 15:06:07 -0000 1.3 *************** *** 24,28 **** class A { void f(int x) ! ensures result == result {} } --- 24,28 ---- class A { void f(int x) ! ensures /* /// FAIL HERE */ result == result {} } |
From: Arjan B. <ar...@us...> - 2005-03-12 15:06:29
|
Update of /cvsroot/nice/Nice/testsuite/compiler/syntax In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11641/F:/nice/testsuite/compiler/syntax Modified Files: localvariable.testsuite locations.testsuite loops.testsuite Log Message: Added some missing failure positions. Index: localvariable.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/syntax/localvariable.testsuite,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** localvariable.testsuite 14 Jun 2003 12:05:07 -0000 1.6 --- localvariable.testsuite 12 Mar 2005 15:06:16 -0000 1.7 *************** *** 35,43 **** let int i; i = 0; ! i = 1; /// FAIL let int i = 0; ! i = 1; /// PASS --- 35,43 ---- let int i; i = 0; ! /* /// FAIL HERE */ i = 1; /// FAIL let int i = 0; ! /* /// FAIL HERE */ i = 1; /// PASS *************** *** 63,67 **** /// FAIL let i = 0; ! i = 1; /// PASS --- 63,67 ---- /// FAIL let i = 0; ! /* /// FAIL HERE */ i = 1; /// PASS Index: loops.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/syntax/loops.testsuite,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** loops.testsuite 22 Feb 2005 10:26:32 -0000 1.5 --- loops.testsuite 12 Mar 2005 15:06:16 -0000 1.6 *************** *** 13,17 **** let int x; for (int i = 0; i < 5; i++) ! x = 7; /// PASS --- 13,17 ---- let int x; for (int i = 0; i < 5; i++) ! /* /// FAIL HERE */ x = 7; /// PASS *************** *** 25,29 **** let int x; for (int i = 0; i < 5; i++) ! x = 7; } --- 25,29 ---- let int x; for (int i = 0; i < 5; i++) ! /* /// FAIL HERE */ x = 7; } Index: locations.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/syntax/locations.testsuite,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** locations.testsuite 9 Oct 2002 15:31:07 -0000 1.4 --- locations.testsuite 12 Mar 2005 15:06:16 -0000 1.5 *************** *** 10,14 **** /// FAIL /// Toplevel ! <Any T> void ignore(T x) {} ! void f() = ignore([ "0" ].map(String s => println(s))); --- 10,14 ---- /// FAIL /// Toplevel ! <T> void ignore(T x) {} ! void f() = /* /// FAIL HERE */ ignore([ "0" ].map(String s => println(s))); |
From: Arjan B. <ar...@us...> - 2005-03-12 15:06:29
|
Update of /cvsroot/nice/Nice/testsuite/compiler/typing In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11641/F:/nice/testsuite/compiler/typing Modified Files: arrays.testsuite if.testsuite object.testsuite polymorphism.testsuite variances.testsuite Log Message: Added some missing failure positions. Index: variances.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/typing/variances.testsuite,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** variances.testsuite 25 Jun 2002 07:06:05 -0000 1.1 --- variances.testsuite 12 Mar 2005 15:06:17 -0000 1.2 *************** *** 15,22 **** /// FAIL BInv<long> b = new BInv(); ! AInv<int> a = b; /// FAIL BInv<int> b = new BInv(); ! AInv<long> a = b; --- 15,22 ---- /// FAIL BInv<long> b = new BInv(); ! AInv<int> /* /// FAIL HERE */ a = b; /// FAIL BInv<int> b = new BInv(); ! AInv<long> /* /// FAIL HERE */ a = b; *************** *** 29,33 **** /// FAIL BCov<long> b = new BCov(); ! ACov<int> a = b; --- 29,33 ---- /// FAIL BCov<long> b = new BCov(); ! ACov<int> /* /// FAIL HERE */ a = b; *************** *** 37,41 **** /// FAIL BContrav<int> b = new BContrav(); ! AContrav<long> a = b; /// PASS BContrav<long> b = new BContrav(); --- 37,41 ---- /// FAIL BContrav<int> b = new BContrav(); ! AContrav<long> /* /// FAIL HERE */ a = b; /// PASS BContrav<long> b = new BContrav(); Index: object.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/typing/object.testsuite,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** object.testsuite 12 Dec 2003 19:24:53 -0000 1.4 --- object.testsuite 12 Mar 2005 15:06:17 -0000 1.5 *************** *** 53,57 **** /// FAIL ! Object o = null; /// PASS --- 53,57 ---- /// FAIL ! Object /* /// FAIL HERE */ o = null; /// PASS Index: arrays.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/typing/arrays.testsuite,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** arrays.testsuite 13 Oct 2004 18:28:51 -0000 1.3 --- arrays.testsuite 12 Mar 2005 15:06:17 -0000 1.4 *************** *** 3,7 **** /// FAIL ! String[] s = new String[1]; /// PASS --- 3,7 ---- /// FAIL ! String[] /* /// FAIL HERE */ s = new String[1]; /// PASS *************** *** 13,17 **** /// Toplevel // The result is optional even if R is not. ! <R> R[] f(int size) = new R[size]; /// PASS --- 13,17 ---- /// Toplevel // The result is optional even if R is not. ! <R> R[] f(int size) = /* /// FAIL HERE */ new R[size]; /// PASS Index: polymorphism.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/typing/polymorphism.testsuite,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** polymorphism.testsuite 1 Mar 2005 18:56:23 -0000 1.6 --- polymorphism.testsuite 12 Mar 2005 15:06:17 -0000 1.7 *************** *** 14,18 **** /// COMMENT Currently we allow only <C T> if C is a type constructor. /// Toplevel ! <T, T U> void f(); /// PASS --- 14,18 ---- /// COMMENT Currently we allow only <C T> if C is a type constructor. /// Toplevel ! <T, /* /// FAIL HERE */ T U> void f(); /// PASS Index: if.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/typing/if.testsuite,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** if.testsuite 28 May 2003 09:04:59 -0000 1.2 --- if.testsuite 12 Mar 2005 15:06:17 -0000 1.3 *************** *** 3,5 **** /// FAIL ! let f = true ? "string" : 0; --- 3,5 ---- /// FAIL ! let f = /* /// FAIL HERE */ true ? "string" : 0; |
From: Daniel B. <bo...@us...> - 2005-03-12 10:41:49
|
Update of /cvsroot/nice/Nice/src/nice/tools/testsuite In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12332/src/nice/tools/testsuite Modified Files: FailTestCase.java Log Message: Report warnings for fail testcases that do not specify the error location. Index: FailTestCase.java =================================================================== RCS file: /cvsroot/nice/Nice/src/nice/tools/testsuite/FailTestCase.java,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** FailTestCase.java 19 Feb 2003 18:30:29 -0000 1.12 --- FailTestCase.java 12 Mar 2005 10:41:37 -0000 1.13 *************** *** 43,46 **** --- 43,51 ---- compilePackages(); } catch(TestSuiteException e) { + if (getFailPositions().isEmpty()) { + TestNice.getOutput().log("warning", "Failure position not checked"); + warning(); + return; + } checkFailPositions(); if (getFailPositions().isEmpty()) |
From: Daniel B. <bo...@us...> - 2005-03-12 10:13:07
|
Update of /cvsroot/nice/Nice/src/bossa/modules In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5585/src/bossa/modules Modified Files: Content.java Log Message: Correctly set the name of scopes that correspond to files. Index: Content.java =================================================================== RCS file: /cvsroot/nice/Nice/src/bossa/modules/Content.java,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** Content.java 11 Mar 2005 17:35:54 -0000 1.19 --- Content.java 12 Mar 2005 10:12:56 -0000 1.20 *************** *** 121,125 **** { nice.tools.visibility.Scope scope = ! new nice.tools.visibility.Scope(unit.name, pkg.packageScope); module = new bossa.syntax.Module(pkg, unit.name, scope); --- 121,125 ---- { nice.tools.visibility.Scope scope = ! new nice.tools.visibility.Scope(unit.getName(), pkg.packageScope); module = new bossa.syntax.Module(pkg, unit.name, scope); *************** *** 274,277 **** --- 274,286 ---- this.name = name; } + + public String getName() + { + if (file != null) + return file.toString(); + else + return name; + } + BufferedReader reader; String name; |
From: Daniel B. <bo...@us...> - 2005-03-12 09:59:15
|
Update of /cvsroot/nice/Nice/src/nice/tools/visibility In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2623/src/nice/tools/visibility Modified Files: impl.nice Added Files: nested.nice Log Message: Moved nested lookup to a separate file. Made public symbols of the current scope visible in nested mode (although they are shadowed by private ones, probably not what we want). --- NEW FILE: nested.nice --- /**************************************************************************/ /* N I C E */ /* A high-level object-oriented research language */ /* (c) Daniel Bonniot 2005 */ /* */ /* 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 nice.tools.visibility; /** Nested lookup mode. In this mode, symbols in the current scope shadow symbols with the same name in imported scopes. @author Daniel Bonniot (bo...@us...) */ <Sym> get(Scope this, root, key) = this.getScope(root).maybeGet(key) || empty; <Sym> get(Scope this, key) = this.maybeGet(key) || empty; private <Sym> ?List<Sym> maybeGet(?Scope<Sym> s, String key) = s == null ? null : (s.map[key] || s.publicMap[key] || s.opens[key] || s.parent.maybeGet(key)); <Sym> ?List<Sym> get(List<Scope<Sym>> scopes, String key) { ?List<Sym> res = null; for (Scope<Sym> scope : scopes) { let partial = scope.publicMap[key]; if (partial != null) { if (res == null) res = new LinkedList(); notNull(res).addAll(partial); } } return res; } private <Sym> ?Scope<Sym> getScope(Scope<Sym> this, String root) { if (this.name.equals(root)) return this; if (parent != null) { let res = notNull(parent).getScope(root); if (res != null) return res; } ?Scope<Sym> s = opens.search(Scope<Sym> s => s.name.equals(root)); return s; } Index: impl.nice =================================================================== RCS file: /cvsroot/nice/Nice/src/nice/tools/visibility/impl.nice,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** impl.nice 12 Mar 2005 02:41:45 -0000 1.4 --- impl.nice 12 Mar 2005 09:59:03 -0000 1.5 *************** *** 19,25 **** */ - private <Sym> ?List<Sym> maybeGet(?Scope<Sym> s, String key) = - s == null ? null : (s.map[key] || s.opens[key] || s.parent.maybeGet(key)); - add(Scope this, key, value, visibility) = map.add(key, value); add(Scope this, key, value, familial) --- 19,22 ---- *************** *** 50,89 **** addImplicitOpen(Scope this, Scope scope) = opens.add(scope); - - <Sym> get(Scope this, root, key) = this.getScope(root).maybeGet(key) || empty; - - <Sym> get(Scope this, key) = this.maybeGet(key) || empty; - - <Sym> ?List<Sym> get(List<Scope<Sym>> scopes, String key) - { - ?List<Sym> res = null; - - for (Scope<Sym> scope : scopes) - { - let partial = scope.publicMap[key]; - if (partial != null) - { - if (res == null) - res = new LinkedList(); - notNull(res).addAll(partial); - } - } - - return res; - } - - private <Sym> ?Scope<Sym> getScope(Scope<Sym> this, String root) - { - if (this.name.equals(root)) - return this; - - if (parent != null) - { - let res = notNull(parent).getScope(root); - if (res != null) - return res; - } - - ?Scope<Sym> s = opens.search(Scope<Sym> s => s.name.equals(root)); - return s; - } --- 47,48 ---- |
From: Daniel B. <bo...@us...> - 2005-03-12 02:42:26
|
Update of /cvsroot/nice/Nice/testsuite/compiler/methods In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5589/testsuite/compiler/methods Modified Files: string.testsuite globalconstant.testsuite Log Message: Implemented visibility for toplevel variables and values. Index: string.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/methods/string.testsuite,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** string.testsuite 17 Jan 2005 18:26:12 -0000 1.7 --- string.testsuite 12 Mar 2005 02:41:43 -0000 1.8 *************** *** 89,93 **** /// package a /// Toplevel ! let String test = "\b\t\n\f\r\"\'\\\035abc1\77xyz\44"; boolean foo(String x) = false; foo("\b\t\n\f\r\"\'\\\035abc1\77xyz\44") = true; --- 89,93 ---- /// package a /// Toplevel ! public let String test = "\b\t\n\f\r\"\'\\\035abc1\77xyz\44"; boolean foo(String x) = false; foo("\b\t\n\f\r\"\'\\\035abc1\77xyz\44") = true; Index: globalconstant.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/methods/globalconstant.testsuite,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** globalconstant.testsuite 1 Mar 2005 18:56:21 -0000 1.11 --- globalconstant.testsuite 12 Mar 2005 02:41:43 -0000 1.12 *************** *** 59,63 **** /// Toplevel class A {} ! let A xxx = new A(); let A yyy = new A(); boolean foo(A); --- 59,63 ---- /// Toplevel class A {} ! public let A xxx = new A(); let A yyy = new A(); boolean foo(A); *************** *** 81,87 **** /// Toplevel class Color {} ! let Color red = new Color(); ! let Color blue = new Color(); ! let Color green = new Color(); String name(Color); name(Color color) = "unknown color"; --- 81,87 ---- /// Toplevel class Color {} ! public let Color red = new Color(); ! public let Color blue = new Color(); ! public let Color green = new Color(); String name(Color); name(Color color) = "unknown color"; |
From: Daniel B. <bo...@us...> - 2005-03-12 02:42:26
|
Update of /cvsroot/nice/Nice/testsuite/compiler In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5589/testsuite/compiler Modified Files: globalVariables.testsuite Log Message: Implemented visibility for toplevel variables and values. Index: globalVariables.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/globalVariables.testsuite,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** globalVariables.testsuite 13 Oct 2004 18:28:48 -0000 1.17 --- globalVariables.testsuite 12 Mar 2005 02:41:44 -0000 1.18 *************** *** 61,71 **** /// PASS ! /// package a /// TOPLEVEL ! var int x = 0; int getAX() = x; /// package b import a /* Modifying a global var from a different package. */ ! x = 1; assert(getAX() == 1); --- 61,71 ---- /// PASS ! /// package a /// TOPLEVEL ! public var int x = 0; int getAX() = x; /// package b import a /* Modifying a global var from a different package. */ ! x = 1; assert(getAX() == 1); *************** *** 93,106 **** /// PASS ! /// package a /// TOPLEVEL ! let int x = 1; /// package b import a assert(x == 1); /// FAIL ! /// package a /// TOPLEVEL ! let int x = 0; /// package b import a x = 1; --- 93,106 ---- /// PASS ! /// package a /// TOPLEVEL ! public let int x = 1; /// package b import a assert(x == 1); /// FAIL ! /// package a /// TOPLEVEL ! public let int x = 0; /// package b import a x = 1; |
From: Daniel B. <bo...@us...> - 2005-03-12 02:42:26
|
Update of /cvsroot/nice/Nice/testsuite/compiler/packages In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5589/testsuite/compiler/packages Modified Files: nicei.testsuite Log Message: Implemented visibility for toplevel variables and values. Index: nicei.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/packages/nicei.testsuite,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** nicei.testsuite 18 Jan 2004 03:33:37 -0000 1.6 --- nicei.testsuite 12 Mar 2005 02:41:42 -0000 1.7 *************** *** 96,101 **** /// package a /// toplevel ! let String s = "abc\n"; ! let String t = """abc def"""; --- 96,101 ---- /// package a /// toplevel ! public let String s = "abc\n"; ! public let String t = """abc def"""; |
From: Daniel B. <bo...@us...> - 2005-03-12 02:42:26
|
Update of /cvsroot/nice/Nice/src/nice/tools/visibility In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5589/src/nice/tools/visibility Modified Files: impl.nice flat.nice Log Message: Implemented visibility for toplevel variables and values. Index: impl.nice =================================================================== RCS file: /cvsroot/nice/Nice/src/nice/tools/visibility/impl.nice,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** impl.nice 6 Mar 2005 15:57:10 -0000 1.3 --- impl.nice 12 Mar 2005 02:41:45 -0000 1.4 *************** *** 25,31 **** add(Scope this, key, value, familial) { - super; if (parent != null) ! notNull(parent).add(key, value, intimate); } add(Scope this, key, value, general) --- 25,32 ---- add(Scope this, key, value, familial) { if (parent != null) ! notNull(parent).add(key, value, familial); ! else ! super; } add(Scope this, key, value, general) *************** *** 35,44 **** notNull(parent).add(key, value, general); else ! { ! // General implies familial ! this.add(key, value, familial); ! ! publicMap.add(key, value); ! } } --- 36,40 ---- notNull(parent).add(key, value, general); else ! publicMap.add(key, value); } Index: flat.nice =================================================================== RCS file: /cvsroot/nice/Nice/src/nice/tools/visibility/flat.nice,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** flat.nice 11 Mar 2005 22:23:32 -0000 1.2 --- flat.nice 12 Mar 2005 02:41:45 -0000 1.3 *************** *** 33,36 **** --- 33,40 ---- res.addAll(temp); + temp = s.publicMap[key]; + if (temp != null) + res.addAll(temp); + for (o : s.opens) { |
From: Daniel B. <bo...@us...> - 2005-03-12 02:42:26
|
Update of /cvsroot/nice/Nice/testsuite/compiler/typing In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5589/testsuite/compiler/typing Modified Files: dti.testsuite Log Message: Implemented visibility for toplevel variables and values. Index: dti.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/typing/dti.testsuite,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** dti.testsuite 9 Mar 2005 21:50:19 -0000 1.10 --- dti.testsuite 12 Mar 2005 02:41:41 -0000 1.11 *************** *** 1,5 **** /// Global ?String maybeString() = null; ! let ()->?String maybeStringGenerator = (int x => ()=> x++ > 10 ? "abc" : null)(0); void maybeThrow() = throw new Exception(); boolean maybeTrue() = true; --- 1,5 ---- /// Global ?String maybeString() = null; ! public let ()->?String maybeStringGenerator = (int x => ()=> x++ > 10 ? "abc" : null)(0); void maybeThrow() = throw new Exception(); boolean maybeTrue() = true; |
From: Daniel B. <bo...@us...> - 2005-03-12 02:42:25
|
Update of /cvsroot/nice/Nice/testsuite/compiler/syntax In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5589/testsuite/compiler/syntax Modified Files: types.testsuite Log Message: Implemented visibility for toplevel variables and values. Index: types.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/syntax/types.testsuite,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** types.testsuite 6 Mar 2003 12:29:07 -0000 1.5 --- types.testsuite 12 Mar 2005 02:41:42 -0000 1.6 *************** *** 39,43 **** /// package a /// toplevel ! var int[?] a = null; /// package b import a a = null; --- 39,43 ---- /// package a /// toplevel ! public var int[?] a = null; /// package b import a a = null; *************** *** 46,50 **** /// package a /// toplevel ! var (int,int) tuple = (1,2); /// package b import a (int x, int y) = tuple; --- 46,50 ---- /// package a /// toplevel ! public var (int,int) tuple = (1,2); /// package b import a (int x, int y) = tuple; *************** *** 53,57 **** /// package a /// toplevel ! var (int,int)->int f = (int x, int y)=> x+y; /// package b import a f(0,1); --- 53,57 ---- /// package a /// toplevel ! public var (int,int)->int f = (int x, int y)=> x+y; /// package b import a f(0,1); *************** *** 60,64 **** /// package a /// toplevel ! var ((int,int))->int f = ((int,int) tuple)=> 0; /// package b import a f((65536,1)); --- 60,64 ---- /// package a /// toplevel ! public var ((int,int))->int f = ((int,int) tuple)=> 0; /// package b import a f((65536,1)); |
From: Daniel B. <bo...@us...> - 2005-03-12 02:41:57
|
Update of /cvsroot/nice/Nice/src/bossa/parser In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5589/src/bossa/parser Modified Files: Parser.jj Log Message: Implemented visibility for toplevel variables and values. Index: Parser.jj =================================================================== RCS file: /cvsroot/nice/Nice/src/bossa/parser/Parser.jj,v retrieving revision 1.317 retrieving revision 1.318 diff -C2 -d -r1.317 -r1.318 *** Parser.jj 11 Mar 2005 21:32:00 -0000 1.317 --- Parser.jj 12 Mar 2005 02:41:47 -0000 1.318 *************** *** 32,35 **** --- 32,36 ---- import bossa.util.*; import bossa.syntax.*; + import nice.tools.visibility.Visibility; import mlsub.typing.TypeSymbol; *************** *** 1519,1523 **** } ! Definition globalVariable(): { LocatedString name; --- 1520,1524 ---- } ! Definition globalVariable(Visibility vis): { LocatedString name; *************** *** 1536,1540 **** ) ";" ! { return bossa.syntax.dispatch.createGlobalVarDeclaration(name,t,value,constant); } } --- 1537,1541 ---- ) ";" ! { return bossa.syntax.dispatch.createGlobalVarDeclaration(name,t,value,constant, vis); } } *************** *** 1573,1577 **** Definition definition(List definitions, boolean storeDocString): ! { Definition res; } { ( --- 1574,1578 ---- Definition definition(List definitions, boolean storeDocString): ! { Definition res; boolean pub = false, priv = false; } { ( *************** *** 1582,1588 **** res=methodBodyDefinition(null) | ! [ "public" | "private" ] ( ! res=globalVariable() | res=enumDefinition(definitions) | "override" { Constraint cst; } cst = constraint() --- 1583,1590 ---- res=methodBodyDefinition(null) | ! [ "public" { pub = true; } | "private" { priv = true; } ] ! { Visibility vis = dispatch.visibility(pub, priv); } ( ! res=globalVariable(vis) | res=enumDefinition(definitions) | "override" { Constraint cst; } cst = constraint() |
From: Daniel B. <bo...@us...> - 2005-03-12 02:41:57
|
Update of /cvsroot/nice/Nice/src/bossa/syntax In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5589/src/bossa/syntax Modified Files: scope.nice globalvar.nice VarScope.java Added Files: visibility.nice Log Message: Implemented visibility for toplevel variables and values. --- NEW FILE: visibility.nice --- /**************************************************************************/ /* N I C E */ /* A high-level object-oriented research language */ /* (c) Daniel Bonniot 2005 */ /* */ /* 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; import nice.tools.visibility; /** Utilities to manipulate visibilities. @author Daniel Bonniot (bo...@us...) */ Visibility visibility(boolean pub, boolean priv) = pub ? general : priv ? intimate: familial; Index: globalvar.nice =================================================================== RCS file: /cvsroot/nice/Nice/src/bossa/syntax/globalvar.nice,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** globalvar.nice 6 Mar 2005 01:34:26 -0000 1.7 --- globalvar.nice 12 Mar 2005 02:41:47 -0000 1.8 *************** *** 24,30 **** --- 24,34 ---- Expression value; boolean constant; + Visibility visibility; resolve() { + left.typeScope = this.compilation.globalTypeScope; + left.resolve(); + value = analyse(value, notNull(scope), notNull(typeScope)); } *************** *** 44,50 **** } printInterface(s) { ! s.print((constant? "let ": "var ") +left +" = " +value.toString() +";\n"); } --- 48,59 ---- } + String modifier(Visibility); + modifier(intimate) = "private "; + modifier(familial) = ""; + modifier(general) = "public "; + printInterface(s) { ! s.print(this.modifier(visibility) + (constant? "let ": "var ") +left +" = " +value.toString() +";\n"); } *************** *** 62,66 **** { GlobalVarDeclaration definition; ! isAssignable() = ! definition.constant; --- 71,75 ---- { GlobalVarDeclaration definition; ! isAssignable() = ! definition.constant; *************** *** 92,102 **** } ! public GlobalVarDeclaration createGlobalVarDeclaration(LocatedString name, ! Monotype type, Expression value, boolean constant) { ! let res = new GlobalVarDeclaration(name, Node.global, left: cast(null), ! value: value, constant: constant); res.left = new GlobalVarSymbol(name, syntacticType: type, definition: res); ! res.addChild(res.left); return res; } --- 101,113 ---- } ! public GlobalVarDeclaration createGlobalVarDeclaration ! (LocatedString name, ! Monotype type, Expression value, boolean constant, Visibility vis) { ! let res = new GlobalVarDeclaration ! (name, Node.global, left: cast(null), value: value, constant: constant, ! visibility: vis); res.left = new GlobalVarSymbol(name, syntacticType: type, definition: res); ! res.module.scope.addSymbol(res.left, vis); return res; } Index: VarScope.java =================================================================== RCS file: /cvsroot/nice/Nice/src/bossa/syntax/VarScope.java,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** VarScope.java 6 Mar 2005 13:59:30 -0000 1.24 --- VarScope.java 12 Mar 2005 02:41:47 -0000 1.25 *************** *** 26,29 **** --- 26,34 ---- abstract void addSymbol(/*VarSymbol*/Symbol s); + void addSymbol(/*VarSymbol*/Symbol s, nice.tools.visibility.Visibility v) + { + this.addSymbol(s); + } + /** Adds a collection of VarSymbols Index: scope.nice =================================================================== RCS file: /cvsroot/nice/Nice/src/bossa/syntax/scope.nice,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** scope.nice 11 Mar 2005 17:35:52 -0000 1.6 --- scope.nice 12 Mar 2005 02:41:47 -0000 1.7 *************** *** 22,27 **** private Scope<VarSymbol> impl = new Scope(name: "", parent: null); ! addSymbol(VarSymbol sym) = ! impl.add(sym.getName().toString(), sym, visibility: general); removeSymbol(VarSymbol sym) = impl.remove(sym.getName().toString(), sym); --- 22,29 ---- private Scope<VarSymbol> impl = new Scope(name: "", parent: null); ! addSymbol(VarSymbol sym) = this.addSymbol(sym, general); ! ! addSymbol(VarSymbol sym, Visibility vis) = ! impl.add(sym.getName().toString(), sym, vis); removeSymbol(VarSymbol sym) = impl.remove(sym.getName().toString(), sym); |
From: Daniel B. <bo...@us...> - 2005-03-12 02:41:57
|
Update of /cvsroot/nice/Nice/src/nice/tools/compiler In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5589/src/nice/tools/compiler Modified Files: setBuildDate StatusCodeListener.nice Log Message: Implemented visibility for toplevel variables and values. Index: setBuildDate =================================================================== RCS file: /cvsroot/nice/Nice/src/nice/tools/compiler/setBuildDate,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** setBuildDate 31 Aug 2003 09:06:08 -0000 1.10 --- setBuildDate 12 Mar 2005 02:41:46 -0000 1.11 *************** *** 13,19 **** echo > dateBuild.nice echo "package nice.tools.compiler;" >> dateBuild.nice ! echo "let String versionNumber = \"$version\";" >> dateBuild.nice ! echo "let String buildDate = \"$date\";" >> dateBuild.nice ! echo "let String javaVersion = \"$javaVersion\";" >> dateBuild.nice --- 13,19 ---- echo > dateBuild.nice echo "package nice.tools.compiler;" >> dateBuild.nice ! echo "public let String versionNumber = \"$version\";" >> dateBuild.nice ! echo "public let String buildDate = \"$date\";" >> dateBuild.nice ! echo "public let String javaVersion = \"$javaVersion\";" >> dateBuild.nice Index: StatusCodeListener.nice =================================================================== RCS file: /cvsroot/nice/Nice/src/nice/tools/compiler/StatusCodeListener.nice,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** StatusCodeListener.nice 20 Feb 2004 02:51:58 -0000 1.1 --- StatusCodeListener.nice 12 Mar 2005 02:41:46 -0000 1.2 *************** *** 23,30 **** */ ! let int OK = 0; // Normal exit (compilation sucessful, version message) ! let int BUG = 1; // Abnormal termination (bug in the compiler) ! let int ERROR = 2; // Error reported (file missing, type error, ...) ! let int WARNING = 3; // Warning reported abstract class StatusCodeListener implements bossa.modules.CompilationListener --- 23,30 ---- */ ! public let int OK = 0; // Normal exit (compilation sucessful, version message) ! public let int BUG = 1; // Abnormal termination (bug in the compiler) ! public let int ERROR = 2; // Error reported (file missing, type error, ...) ! public let int WARNING = 3; // Warning reported abstract class StatusCodeListener implements bossa.modules.CompilationListener |
From: Daniel B. <bo...@us...> - 2005-03-12 02:41:51
|
Update of /cvsroot/nice/Nice/testsuite/compiler/visibility/expressions In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5589/testsuite/compiler/visibility/expressions Added Files: private.testsuite Log Message: Implemented visibility for toplevel variables and values. --- NEW FILE: private.testsuite --- /// FAIL bug /// package a /// Toplevel class A { private String hidden = "secret"; } /// package b import a println("Got it: " + thief(new A())); /// Toplevel String thief(A a) = /*///FAIL HERE*/ a.hidden; /// FAIL /// package a /// Toplevel private let String hidden = "secret"; /// package b import a String s = /*///FAIL HERE*/ hidden; |
From: Arjan B. <ar...@us...> - 2005-03-12 02:27:20
|
Update of /cvsroot/nice/Nice/src/bossa/syntax In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2102/F:/nice/src/bossa/syntax Modified Files: constant.nice Log Message: Fixed double negation of literals. Index: constant.nice =================================================================== RCS file: /cvsroot/nice/Nice/src/bossa/syntax/constant.nice,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** constant.nice 12 Mar 2005 01:15:51 -0000 1.15 --- constant.nice 12 Mar 2005 02:27:07 -0000 1.16 *************** *** 44,48 **** public ConstantExp makeNegative() { ! LocatedString newRepres = new LocatedString("-"+representation, this.location()); if (value instanceof Float || value instanceof Double) --- 44,52 ---- public ConstantExp makeNegative() { ! LocatedString newRepres; ! if (representation[0] == '-') ! newRepres = new LocatedString(representation.substring(1), this.location()); ! else ! newRepres = new LocatedString("-"+representation, this.location()); if (value instanceof Float || value instanceof Double) |
From: Arjan B. <ar...@us...> - 2005-03-12 02:27:20
|
Update of /cvsroot/nice/Nice/testsuite/compiler/syntax In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2102/F:/nice/testsuite/compiler/syntax Modified Files: expressions.testsuite Log Message: Fixed double negation of literals. Index: expressions.testsuite =================================================================== RCS file: /cvsroot/nice/Nice/testsuite/compiler/syntax/expressions.testsuite,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** expressions.testsuite 12 Mar 2005 00:19:16 -0000 1.10 --- expressions.testsuite 12 Mar 2005 02:27:08 -0000 1.11 *************** *** 32,35 **** --- 32,37 ---- assert 0xF000 == 0B1111_0000_0000_0000; + assert -(-5) == 5; + /// PASS let a = new A(_b: 0); |
From: Daniel B. <bo...@us...> - 2005-03-12 01:16:04
|
Update of /cvsroot/nice/Nice/src/bossa/syntax In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15544/src/bossa/syntax Modified Files: constant.nice Log Message: Removed debugging stack trace printing. Removed unused '#' hexadecimal format support. Index: constant.nice =================================================================== RCS file: /cvsroot/nice/Nice/src/bossa/syntax/constant.nice,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** constant.nice 12 Mar 2005 00:46:26 -0000 1.14 --- constant.nice 12 Mar 2005 01:15:51 -0000 1.15 *************** *** 158,162 **** } catch(NumberFormatException e) { - e.printStackTrace(); throw User.error(representation, rep + " is not a valid number"); } --- 158,161 ---- *************** *** 202,210 **** radix = 2; } - else if (rep.startsWith("#", index)) - { - index++; - radix = 16; - } else if (rep.startsWith("0", index) && rep.length() > 1 + index) { --- 201,204 ---- |
From: Arjan B. <ar...@us...> - 2005-03-12 00:46:42
|
Update of /cvsroot/nice/Nice/src/bossa/syntax In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8721/F:/nice/src/bossa/syntax Modified Files: constant.nice Log Message: Fix sign of hex literals. Index: constant.nice =================================================================== RCS file: /cvsroot/nice/Nice/src/bossa/syntax/constant.nice,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** constant.nice 12 Mar 2005 00:01:55 -0000 1.13 --- constant.nice 12 Mar 2005 00:46:26 -0000 1.14 *************** *** 132,136 **** { // handle 32 bit bin/hex literals which don't fit in a int if (value > 0) ! value = (1L << 32) - value; else value = (1L << 32) + value; --- 132,136 ---- { // handle 32 bit bin/hex literals which don't fit in a int if (value > 0) ! value = -((1L << 32) - value); else value = (1L << 32) + value; |