projects
/
org.ibex.js.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
26ade6b
)
correct JSArray keys enumeration to return integers, not the values
author
crawshaw
<crawshaw@ibex.org>
Thu, 6 Jan 2005 19:55:58 +0000
(19:55 +0000)
committer
crawshaw
<crawshaw@ibex.org>
Thu, 6 Jan 2005 19:55:58 +0000
(19:55 +0000)
darcs-hash:
20050106195558
-2eb37-
badf4bd9862d6d0ff199abb01804c18aa4033ff5
.gz
src/org/ibex/js/JSArray.java
patch
|
blob
|
history
diff --git
a/src/org/ibex/js/JSArray.java
b/src/org/ibex/js/JSArray.java
index
40974e3
..
cb06d0d
100644
(file)
--- a/
src/org/ibex/js/JSArray.java
+++ b/
src/org/ibex/js/JSArray.java
@@
-20,9
+20,9
@@
class JSArray extends Basket.Array implements JS, Basket.CompareFunc {
public JS unclone() { return this; }
public JS.Enumeration keys() throws JSExn {
return new Enumeration(null) {
- private int pos = 0;
- public boolean _hasNext() { return pos < size(); }
- public JS _next() { return (JS)JSArray.this.get(pos++); }
+ private int n = 0;
+ public boolean _hasNext() { return n < size(); }
+ public JS _next() { return Script.N(n++); }
};
}
public JS get(JS key) throws JSExn {