summaryrefslogtreecommitdiff
path: root/src/cli/runtime/ArraySeq.cs
diff options
context:
space:
mode:
authorRich Hickey <richhickey@gmail.com>2006-08-09 13:27:47 +0000
committerRich Hickey <richhickey@gmail.com>2006-08-09 13:27:47 +0000
commitac3c1ae28a18395a15b8a4f85ea2ad90a3e9e540 (patch)
tree60b94694426b2cff302f50b989f3dbfd0a989d01 /src/cli/runtime/ArraySeq.cs
parente5fafd352e9351e1f55b1fac0de911e1dc3b632a (diff)
removed chaining from ArraySeq.rest, changed meta handling in queue
Diffstat (limited to 'src/cli/runtime/ArraySeq.cs')
-rw-r--r--src/cli/runtime/ArraySeq.cs22
1 files changed, 13 insertions, 9 deletions
diff --git a/src/cli/runtime/ArraySeq.cs b/src/cli/runtime/ArraySeq.cs
index c2c56da7..144d872f 100644
--- a/src/cli/runtime/ArraySeq.cs
+++ b/src/cli/runtime/ArraySeq.cs
@@ -18,7 +18,7 @@ namespace clojure.lang
public class ArraySeq : ASeq, IndexedSeq{
readonly Object[] array;
readonly int i;
-ISeq _rest;
+//ISeq _rest;
static public ArraySeq create(params Object[] array){
if(array.Length == 0)
@@ -29,7 +29,7 @@ static public ArraySeq create(params Object[] array){
ArraySeq(Object[] array, int i){
this.array = array;
this.i = i;
- this._rest = this;
+// this._rest = this;
}
override public Object first() {
@@ -37,13 +37,17 @@ override public Object first() {
}
override public ISeq rest() {
- if(_rest == this)
- {
- if(i+1 < array.Length)
- _rest = new ArraySeq(array, i + 1);
- _rest = null;
- }
- return _rest;
+ if (i + 1 < array.Length)
+ return new ArraySeq(array, i + 1);
+ return null;
+
+// if(_rest == this)
+// {
+// if(i+1 < array.Length)
+// _rest = new ArraySeq(array, i + 1);
+// _rest = null;
+// }
+// return _rest;
}
public int index(){