#Why am I getting this error?

7 messages · Page 1 of 1 (latest)

vivid ivy
#

error: ‘constexpr’ needed for in-class initialization of static data member ‘const double Grid_3d::Table::_epsilon0’ of non-integral type [-fpermissive]
285 | static const double _epsilon0 = 8.85418781762e-12; // [epsilon0] = As/(Vm)

meager lightBOT
#

When your question is answered use !solved to mark the question as resolved.

Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question run !howto ask.

terse sparrow
#

As I understand it, for const static members, you must only declare the variable in the class definition, and then actually define it out of the class (usually in a cpp file)

#

Haven't done this is a while, so I'm fuzzy on the details

tropic agate
tropic agate
meager lightBOT
#

This question thread is being automatically closed. If your question is not answered feel free to bump the post or re-ask. Take a look at !howto ask for tips on improving your question.