dimanche 8 mars 2015

Array fixed value with a constant

i try to use constant to fix an size array



class Model {
public:
const int MAX_TISSUE = 16;
array<CompartmentTissue, MAX_TISSUE> tissue;
}


i get the error invalid use of non-static data member 'BuhlmannModel::MAX_TISSUE'


i check oracle web site and it's seem possible to use this syntax http://ift.tt/WcdrPy


compiler info



CLDFLAGS='-mthumb -mcpu=cortex-m4 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -Og'
CONLYFLAGS='-std=gnu11'

Aucun commentaire:

Enregistrer un commentaire