/************************************************************** * * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. * *************************************************************/ #ifndef SYSTEM_STL_VECTOR #define SYSTEM_STL_VECTOR #ifdef HAVE_STL_INCLUDE_PATH // TODO: use computed include file name #include_next #elif defined(_MSC_VER) #include <../../VC/include/vector> #else // fall back to boost/tr1 #include #endif #ifndef NO_STLPORT4_EMULATION namespace std { typedef vector bit_vector; } // workaround some STL implementations having problems with their vector::count() specialization inline int std_bitset_count( std::bit_vector::const_iterator it, std::bit_vector::const_iterator itEnd, bool bValue) { #if 0 && defined(_LIBCPP___BIT_REFERENCE) // TODO: reenable for libc++ >= r156543/r156546/etc. int nCount = std::count( it, itEnd, bValue); #else int nCount = 0; for(; it != itEnd; ++it) if( *it == bValue) ++nCount; #endif return nCount; } #endif // NO_STLPORT4_EMULATION #endif