STK++ 0.9.13
STK::hidden::ProductSizeRowsBySizeCols< Size1, Size2 > Struct Template Reference

Convenient structure for computing the product of two template integer parameters without overflow. More...

#include <STK_MetaTemplate.h>

Public Types

enum  { prod_ = ProductSizesHelper< Size1 >= SqrtUnknownSize , Size2 = SqrtUnknownSize , Size1 , prod_ = ProductSizesHelper< Size1 >= SqrtUnknownSize }
 

Detailed Description

template<int Size1, int Size2>
struct STK::hidden::ProductSizeRowsBySizeCols< Size1, Size2 >

Convenient structure for computing the product of two template integer parameters without overflow.

Compute the product Size1*Size2 trick as some compilers (g++ 4 and 5 at least) complain about overflow otherwise.

Definition at line 158 of file STK_MetaTemplate.h.

Member Enumeration Documentation

◆ anonymous enum

template<int Size1, int Size2>
anonymous enum
Enumerator
prod_ 
Size2 
Size1 
prod_ 

Definition at line 158 of file STK_MetaTemplate.h.

158 { enum { prod_ = ProductSizesHelper< Size1 >= SqrtUnknownSize
160 , Size1
161 , Size2>::prod_};};
const int SqrtUnknownSize
Same as floor(sqrt(INT_MAX+1))

The documentation for this struct was generated from the following file: