Array.st
changeset 7859 837f47feba96
parent 7600 5a3fee21c032
child 8368 2109093f80ff
--- a/Array.st	Thu Jan 29 14:18:50 2004 +0100
+++ b/Array.st	Thu Jan 29 14:21:27 2004 +0100
@@ -448,59 +448,59 @@
     REGISTER int spc;
 
     if (__qClass(self) == Array) {
-	sz = __qSize(self) + sizeof(OBJ);
-	__PROTECT2__(something, self);
-	__qAlignedNew(nObj, sz);        /* OBJECT ALLOCATION */
-	__UNPROTECT2__(self, something);
+        sz = __qSize(self) + sizeof(OBJ);
+        __PROTECT2__(something, self);
+        __qAlignedNew(nObj, sz);        /* OBJECT ALLOCATION */
+        __UNPROTECT2__(self, something);
 
-	if (nObj) {
-	    __InstPtr(nObj)->o_class = Array;
-	    __STORE(nObj, Array);
+        if (nObj) {
+            __InstPtr(nObj)->o_class = Array;
+            __qSTORE(nObj, Array);
 
-	    nIndex = __BYTES2OBJS__(sz - OHDR_SIZE - sizeof(OBJ));
-	    /* 
-	     * sorry: 
-	     *   cannot use bcopy, since we must take care of stores ... 
-	     *   could check for: notRemembered + inOld + notLifoRem
-	     *                  + not incrGCRunning
-	     * but: copyWith is not heavily used by real programmers ...
-	     */
-	    spc = __qSpace(nObj);
-	    srcP = __arrayVal(self);
-	    dstP = __arrayVal(nObj);
+            nIndex = __BYTES2OBJS__(sz - OHDR_SIZE - sizeof(OBJ));
+            /* 
+             * sorry: 
+             *   cannot use bcopy, since we must take care of stores ... 
+             *   could check for: notRemembered + inOld + notLifoRem
+             *                  + not incrGCRunning
+             * but: copyWith is not heavily used by real programmers ...
+             */
+            spc = __qSpace(nObj);
+            srcP = __arrayVal(self);
+            dstP = __arrayVal(nObj);
 
 #ifdef UNROLL_LOOPS
-	    while (nIndex >= 4) {
-		OBJ element;
+            while (nIndex >= 4) {
+                OBJ element;
 
-		element = srcP[0];
-		dstP[0] = element;
-		__STORE_SPC(nObj, element, spc);
-		element = srcP[1];
-		dstP[1] = element;
-		__STORE_SPC(nObj, element, spc);
-		element = srcP[2];
-		dstP[2] = element;
-		__STORE_SPC(nObj, element, spc);
-		element = srcP[3];
-		dstP[3] = element;
-		__STORE_SPC(nObj, element, spc);
-		srcP += 4;
-		dstP += 4;
-		nIndex -= 4;
-	    }
+                element = srcP[0];
+                dstP[0] = element;
+                __STORE_SPC(nObj, element, spc);
+                element = srcP[1];
+                dstP[1] = element;
+                __STORE_SPC(nObj, element, spc);
+                element = srcP[2];
+                dstP[2] = element;
+                __STORE_SPC(nObj, element, spc);
+                element = srcP[3];
+                dstP[3] = element;
+                __STORE_SPC(nObj, element, spc);
+                srcP += 4;
+                dstP += 4;
+                nIndex -= 4;
+            }
 #endif
-	    while (nIndex--) {
-		OBJ element;
+            while (nIndex--) {
+                OBJ element;
 
-		element = *srcP++;
-		*dstP++ = element;
-		__STORE_SPC(nObj, element, spc);
-	    }
-	    *dstP = something;
-	    __STORE_SPC(nObj, something, spc);
-	    RETURN ( nObj );
-	}
+                element = *srcP++;
+                *dstP++ = element;
+                __STORE_SPC(nObj, element, spc);
+            }
+            *dstP = something;
+            __STORE_SPC(nObj, something, spc);
+            RETURN ( nObj );
+        }
     }
 %}.
     ^ super copyWith:something
@@ -2429,5 +2429,5 @@
 !Array class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic/Array.st,v 1.131 2003-09-03 16:00:04 stefan Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/Array.st,v 1.132 2004-01-29 13:20:52 stefan Exp $'
 ! !