22 template<
long a,
long b,
bool bo>
27 template<
long a,
long b>
28 struct GcdHelper<a,b,true>
33 static void conceptCheck()
43 const static long gcd = GcdHelper<b,a%b,true>::gcd;
46 template<
long a,
long b>
47 struct GcdHelper<a,b,false>
52 const static long gcd = GcdHelper<b,a,true>::gcd;
55 struct GcdHelper<a,0,true>
57 const static long gcd=a;
65 template<
long a,
long b>
70 const static long value = GcdHelper<a,b,(a>b)>::gcd;
Dune namespace.
Definition: alignment.hh:13
Fallback implementation of the C++0x static_assert feature.
#define dune_static_assert(COND, MSG)
Helper template so that compilation fails if condition is not true.
Definition: static_assert.hh:79
static const long value
The greatest common divisior of a and b.
Definition: gcd.hh:70
Calculator of the greatest common divisor.
Definition: gcd.hh:66