mark initHydroCarbonState() as inline

this allows it to be used in multiple compile units without the linker
running amok.
This commit is contained in:
Andreas Lauser 2017-10-04 19:24:20 +02:00
parent 33305c4f1f
commit 2ab9b5de45

View File

@ -6,7 +6,7 @@
namespace Opm
{
void initHydroCarbonState(BlackoilState& state, const PhaseUsage& pu, const int num_cells, const bool has_disgas, const bool has_vapoil) {
inline void initHydroCarbonState(BlackoilState& state, const PhaseUsage& pu, const int num_cells, const bool has_disgas, const bool has_vapoil) {
enum { Oil = BlackoilPhases::Liquid, Gas = BlackoilPhases::Vapour, Water = BlackoilPhases::Aqua };
// hydrocarbonstate is only used when gas and oil is present
assert(pu.phase_used[Oil]);