<commit_before># We check two things: where the include file is for hash_map, and
# what namespace hash_map lives in within that include file.  We
# include AC_TRY_COMPILE for all the combinations we've seen in the
# wild.  We define one of HAVE_HASH_MAP or HAVE_EXT_HASH_MAP depending
# on location, and HASH_NAMESPACE to be the namespace hash_map is
# defined in.
#
# Ideally we'd use AC_CACHE_CHECK, but that only lets us store one value
# at a time, and we need to store two (filename and namespace).
# prints messages itself, so we have to do the message-printing ourselves
# via AC_MSG_CHECKING + AC_MSG_RESULT.  (TODO(csilvers): can we cache?)

AC_DEFUN([AC_CXX_STL_HASH],
  [AC_MSG_CHECKING(the location of hash_map)
  AC_LANG_SAVE
   AC_LANG_CPLUSPLUS
   ac_cv_cxx_hash_map_header=""
   ac_cv_cxx_hash_map_class=""
   for location in [tr1/unordered_map ext/hash_map hash_map]; do
     for namespace in [std::tr1 __gnu_cxx "" std stdext]; do
       for name in [unordered_map hash_map]; do

         if test -z "$ac_cv_cxx_hash_map_header"; then

           AC_TRY_COMPILE([#include <$location>],
                          [${namespace}::$name<int, int> t],
                          [ac_cv_cxx_hash_map_header="<$location>";
                           ac_cv_cxx_hash_namespace="$namespace";
                           ac_cv_cxx_hash_map_class="$name";])
         fi
       done
     done<commit_msg>Detect and avoid broken unordered_map on OSX 10.5 / GCC 4.0.1.<commit_after># We check two things: where the include file is for hash_map, and
# what namespace hash_map lives in within that include file.  We
# include AC_TRY_COMPILE for all the combinations we've seen in the
# wild.  We define one of HAVE_HASH_MAP or HAVE_EXT_HASH_MAP depending
# on location, and HASH_NAMESPACE to be the namespace hash_map is
# defined in.
#
# Ideally we'd use AC_CACHE_CHECK, but that only lets us store one value
# at a time, and we need to store two (filename and namespace).
# prints messages itself, so we have to do the message-printing ourselves
# via AC_MSG_CHECKING + AC_MSG_RESULT.  (TODO(csilvers): can we cache?)

AC_DEFUN([AC_CXX_STL_HASH],
  [AC_MSG_CHECKING(the location of hash_map)
  AC_LANG_SAVE
   AC_LANG_CPLUSPLUS
   ac_cv_cxx_hash_map_header=""
   ac_cv_cxx_hash_map_class=""
   for location in [tr1/unordered_map ext/hash_map hash_map]; do
     for namespace in [std::tr1 __gnu_cxx "" std stdext]; do
       for name in [unordered_map hash_map]; do

         if test -z "$ac_cv_cxx_hash_map_header"; then

           # On OSX 1.5 / GCC 4.0.1 (the standard compiler on that platform),
           # calling find() on a const unordered_map does not compile.  So, we
           # include a call to find() in our test to detect this broken
           # implementation and avoid using it.  Note that ext/hash_map works
           # fine on this platform, so we'll end up using that.
           AC_TRY_COMPILE([#include <$location>],
                          [const ${namespace}::$name<int, int> t;
                           t.find(1);],
                          [ac_cv_cxx_hash_map_header="<$location>";
                           ac_cv_cxx_hash_namespace="$namespace";
                           ac_cv_cxx_hash_map_class="$name";])
         fi
       done
     done
{'fraction_non_alphanumeric': 0.07711063700091436, 'fraction_numerical': 0.0048765620237732395, 'mean_word_length': 2.8341121495327104, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2587754', 'n_tokens_mistral': 1056, 'n_tokens_neox': 1042, 'n_words': 347}