[7297] Fixed profession spells sorting in trainer spell list at client.
[getmangos.git] / dep / ACE_wrappers / ace / OS_NS_math.inl
blobedfeb41869d3ceb4bec34d18a0c803c4d0149a67
1 // -*- C++ -*-
2 //
3 // $Id: OS_NS_math.inl 80826 2008-03-04 14:51:23Z wotte $
5 ACE_BEGIN_VERSIONED_NAMESPACE_DECL
7 namespace ACE_OS {
9   ACE_INLINE double
10   floor (double x)
11   {
12     // This method computes the largest integral value not greater than x.
13     if(x > 0)
14       return static_cast<long> (x);
15     else if (static_cast<long> (x) == x)
16       return x;
17     else
18       return static_cast<long>(x) - 1;
19   }
21   ACE_INLINE double
22   ceil (double x)
23   {
24     // This method computes the smallest integral value not less than x.
25     if (x < 0)
26       return static_cast<long> (x);
27     else if (static_cast<long> (x) == x)
28       return x;
29     else
30       return static_cast<long> (x) + 1;
31   }
33   ACE_INLINE double
34   log2 (double x)
35   {
36     return ace_log2_helper (x);
37   }
39 } // ACE_OS namespace
41 ACE_END_VERSIONED_NAMESPACE_DECL