diff options
author | Rich Hickey <richhickey@gmail.com> | 2006-08-05 16:44:23 +0000 |
---|---|---|
committer | Rich Hickey <richhickey@gmail.com> | 2006-08-05 16:44:23 +0000 |
commit | 279dd21d4b919496c8fb54c3135f2b82cc36f5c2 (patch) | |
tree | 0216faea0823626bc0b59346b542b68f0392feb3 /src/cli/runtime/AnArray.cs | |
parent | da11eb9d0dd587e532470965b3c655b741d1fa5c (diff) |
added cons to IPersistentCollection
Diffstat (limited to 'src/cli/runtime/AnArray.cs')
-rw-r--r-- | src/cli/runtime/AnArray.cs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/cli/runtime/AnArray.cs b/src/cli/runtime/AnArray.cs index b586d6f5..b02f7c65 100644 --- a/src/cli/runtime/AnArray.cs +++ b/src/cli/runtime/AnArray.cs @@ -15,6 +15,13 @@ namespace clojure.lang {
public abstract class AnArray : Obj, IArray {
+public virtual IPersistentCollection cons(Object o) {
+ PersistentArrayList ret = new PersistentArrayList(this, this.count() + 10);
+ ret = (PersistentArrayList)ret.cons(o);
+ ret._meta = _meta;
+ return ret;
+}
+
public override Obj withMeta(IPersistentMap meta)
{
if(_meta == meta)
|