X-Git-Url: http://git.nguyen.vg/gitweb/?a=blobdiff_plain;f=libcds%2Fsrc%2Fstatic_sequence%2Fwt_node_leaf.cpp;h=6c036fd212b045c78a52dcf6616b8df69bc4a7c3;hb=95f2dabec7cabe4002865e5f9d12651e6e32229a;hp=43ca7ca0d78e926aa5ef18932bb139adc8d33b38;hpb=816fe5fd2e5c2ef306227c6870a45b026b923f2e;p=SXSI%2FXMLTree.git diff --git a/libcds/src/static_sequence/wt_node_leaf.cpp b/libcds/src/static_sequence/wt_node_leaf.cpp index 43ca7ca..6c036fd 100644 --- a/libcds/src/static_sequence/wt_node_leaf.cpp +++ b/libcds/src/static_sequence/wt_node_leaf.cpp @@ -36,17 +36,9 @@ uint wt_node_leaf::rank(uint symbol, uint pos, uint l, wt_coder * c) { return pos; } -uint wt_node_leaf::rankLessThan(uint &symbol, uint pos, uint l, wt_coder * c) { -// std::cout <<"this-symbol: " << (uchar)this->symbol << ", symbol = " << (uchar)symbol << ", pos = " << pos << std::endl; - if(symbol > this->symbol) return -1; - symbol = this->symbol; - pos++; - return pos; -} - uint wt_node_leaf::rankLessThan(uint &symbol, uint pos) { // std::cout <<"this-symbol: " << (uchar)this->symbol << ", symbol = " << (uchar)symbol << ", pos = " << pos << std::endl; - if (pos == (uint)-1) + if (pos == (uint)-1 || symbol < this->symbol) return -1; symbol = this->symbol; pos++;