ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/OpenMD/branches/development/src/utils/Predicate.hpp
(Generate patch)

Comparing:
trunk/src/utils/Predicate.hpp (file contents), Revision 516 by chuckv, Fri Apr 22 21:57:16 2005 UTC vs.
branches/development/src/utils/Predicate.hpp (file contents), Revision 1794 by gezelter, Thu Sep 6 19:44:06 2012 UTC

# Line 10 | Line 10
10   #define UTILS_PREDICATE_HPP
11   #include <locale>
12  
13 namespace oopse {
13  
14 +
15 + #if defined(__SUNPRO_CC)
16 + #  define USE_FACET(Type, loc) std::use_facet(loc, static_cast<Type*>(0))
17 + #else
18 + #  define USE_FACET(Type, loc) std::use_facet< Type >(loc)
19 + #endif
20 +
21 + namespace OpenMD {
22 +
23   template<typename Derived>
24   struct PredFacade{};
25  
# Line 22 | Line 30 | struct CharClassification: public PredFacade<CharClass
30  
31      template<typename CharT>
32      bool operator()( CharT c ) const {
33 <        return std::use_facet< std::ctype<CharT> >(loc_).is( type_, c );
33 >        return USE_FACET(std::ctype<CharT>, loc_).is( type_, c );
34      }
35  
36      private:
# Line 92 | Line 100 | struct PredNotFunctor : public PredFacade< PredNotFunc
100      PredT pred_;
101   };
102        
103 < inline CharClassification isSpace(const std::locale& loc=std::locale()){
103 >  inline CharClassification isSpace(const std::locale& loc=std::locale()){
104      return CharClassification(std::ctype_base::space, loc);
105   }
106  

Comparing:
trunk/src/utils/Predicate.hpp (property svn:keywords), Revision 516 by chuckv, Fri Apr 22 21:57:16 2005 UTC vs.
branches/development/src/utils/Predicate.hpp (property svn:keywords), Revision 1794 by gezelter, Thu Sep 6 19:44:06 2012 UTC

# Line 0 | Line 1
1 + Author Id Revision Date

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines