ciao.
Ho una mappa statica in un template come variabile pubblica.
codice:
template <typename B>
class complex_nillable_type: public B
{
static complex_nillable_type::m_pMap = NULL;
public:
complex_nillable_type ()
: nil_ (false),
ref_ (xml_schema::idref (""), 0, this)
{
}
ho 200 tipi che fanno riferimento a quel template , e vorrei condividere per tutti i tipi una mappa statica , in modo da leggerla dall ' esterno.
il problema è che mi da questi errori:
c:\IFCXML\ifc\ifc\nillable-type.hxx(20): error C2864: 'm_pMap' : only const static integral data members can be initialized inside a class or struct
c:\IFCXML\ifc\ifc\IFC2X3.hxx(4202) : see reference to class template instantiation 'complex_nillable_type[B]' being compiled
with
[
B=ifc::IfcFlowControllerTypeBase
]
per ognuno dei tipi.