]> gitweb.hamatoma.de Git - crepublib/commitdiff
Warnings
authorkawi <winfriedkappeler@atron.de>
Wed, 14 Jan 2015 07:02:34 +0000 (08:02 +0100)
committerkawi <winfriedkappeler@atron.de>
Wed, 14 Jan 2015 07:02:34 +0000 (08:02 +0100)
base/ReSeqArray.hpp
base/ReStringList.cpp
cunit/cuReSeqArray.cpp

index 92aec3b30fc640b5c832f31d1c98dbb46a0fc78f..3f06bb2782549a0bc46c1bc8c38e3ec618b6d34d 100644 (file)
@@ -76,6 +76,7 @@ protected:
                return m_content.buffer();
        }
        friend class ReHashList;
+       friend class ReStringList;
        /** @brief Returns the info of an entry of the list.
         * @param index         The index of the wanted entry.
         * @return The pointer of the entry.
index 08e0cafd9e9f4827b1aef070ad2bdc2aea761da5..52dc481ae9b3208590dded9a2e053bd1420f0d03 100644 (file)
@@ -145,7 +145,8 @@ size_t ReStringList::sizeOf(Index index) const{
        size_t rc = 0;
        if (index < count()){
                Sequence* seq = getInfo(index);
-               rc = seq->m_length;
+        //@ToDo
+               rc = getLength(seq);
        }
        return rc;
 }
@@ -161,7 +162,7 @@ size_t ReStringList::strLengthOf(Index index) const{
        size_t rc = 0;
        if (index < count()){
                Sequence* seq = getInfo(index);
-               rc = seq->m_length - 1;
+                rc = rc = getLength(seq) - 1;
        }
        return rc;
 }
@@ -174,7 +175,7 @@ size_t ReStringList::sumOfSizes() const{
 
        for (int ii = count() - 1; ii >= 0; ii--){
                Sequence* seq = getInfo(ii);
-               rc += seq->m_length;
+               rc += rc = getLength(seq);
        }
        return rc;
 }
@@ -187,7 +188,7 @@ size_t ReStringList::sumOfStrLengths() const{
 
        for (int ii = count() - 1; ii >= 0; ii--){
                Sequence* seq = getInfo(ii);
-               rc += seq->m_length - 1;
+               rc += rc = getLength(seq);
        }
        return rc;
 }
index 16a08e8b9b7079b6484de6aab7d3be2566e8dfe2..bdfca227e7ac38fcdbab087bf845ad67b0c3da27 100644 (file)
@@ -36,30 +36,29 @@ private:
                ReSeqArray::Index index;
 
                checkF(list.binarySearch("cee", -1, index, NULL));
-               checkEqu(5ll, index);
+               checkEqu(ReSeqArray::Index(5), index);
 
                checkF(list.binarySearch("ab", 2, index, NULL));
-               checkEqu(0ll, index);
+               checkEqu(ReSeqArray::Index(0), index);
                checkF(list.binarySearch("ab", -1, index, NULL));
-               checkEqu(0ll, index);
+               checkEqu(ReSeqArray::Index(0), index);
                checkF(list.binarySearch("abcd", -1, index, NULL));
-               checkEqu(2ll, index);
+               checkEqu(ReSeqArray::Index(2), index);
                checkF(list.binarySearch("bbd", -1, index, NULL));
-               checkEqu(3ll, index);
+               checkEqu(ReSeqArray::Index(3), index);
                checkF(list.binarySearch("bbd", -1, index, NULL));
-               checkEqu(3ll, index);
+               checkEqu(ReSeqArray::Index(3), index);
                checkF(list.binarySearch("bc", -1, index, NULL));
-               checkEqu(3ll, index);
+               checkEqu(ReSeqArray::Index(3), index);
                checkF(list.binarySearch("bcd0", -1, index, NULL));
-               checkEqu(4ll, index);
+               checkEqu(ReSeqArray::Index(4), index);
                checkF(list.binarySearch("cdex", -1, index, NULL));
-               checkEqu(5ll, index);
+               checkEqu(ReSeqArray::Index(5), index);
                checkF(list.binarySearch("cee", -1, index, NULL));
-               checkEqu(5ll, index);
+               checkEqu(ReSeqArray::Index(5), index);
        }
        void testBinSearch2(){
                ReSeqArray list;
-               ReSeqArray::Tag tag;
                ReSeqArray::Index index;
                ReByteBuffer value;
                list.setSorted(true);