boost_has_stlp_use_facet.ipp 784 B

12345678910111213141516171819202122232425262728293031
  1. // (C) Copyright John Maddock 2001.
  2. // Use, modification and distribution are subject to the
  3. // Boost Software License, Version 1.0. (See accompanying file
  4. // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  5. // See http://www.boost.org/libs/config for most recent version.
  6. // MACRO: BOOST_HAS_STLP_USE_FACET
  7. // TITLE: STLport version of use_facet
  8. // DESCRIPTION: The standard library lacks a conforming std::use_facet,
  9. // but has a workaound class-version that does the job.
  10. // This is primarily for the STLport std lib.
  11. #include <locale>
  12. namespace boost_has_stlp_use_facet{
  13. int test()
  14. {
  15. std::locale l;
  16. const std::ctype<char>& ct = *std::_Use_facet<std::ctype<char> >(l);
  17. return 0;
  18. }
  19. }