mirror of
https://github.com/CoolProp/CoolProp.git
synced 2026-04-23 03:00:17 -04:00
Merge branch 'master' into tabular
Signed-off-by: Ian Bell <ian.h.bell@gmail.com>
This commit is contained in:
@@ -21,8 +21,8 @@ namespace CoolProp {
|
||||
|
||||
AbstractState * AbstractState::factory(const std::string &backend, const std::vector<std::string> &fluid_names)
|
||||
{
|
||||
static std::string HEOS_string = "HEOS";
|
||||
if (!backend.compare("HEOS"))
|
||||
static const std::string HEOS_string = "HEOS";
|
||||
if (!backend.compare(HEOS_string))
|
||||
{
|
||||
if (fluid_names.size() == 1){
|
||||
return new HelmholtzEOSBackend(fluid_names[0]);
|
||||
@@ -75,7 +75,7 @@ AbstractState * AbstractState::factory(const std::string &backend, const std::ve
|
||||
else
|
||||
{
|
||||
// Split string at the '::' into two std::string, call again
|
||||
return factory(std::string(fluid_names[0].begin(), fluid_names[0].begin() + idel), std::string(fluid_names[0].begin()+idel+2, fluid_names[0].end()));
|
||||
return factory(std::string(fluid_names[0].begin(), fluid_names[0].begin() + idel), std::string(fluid_names[0].begin()+(idel+2), fluid_names[0].end()));
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user