Clarify by using this->

Clarify usage of member variables in FlowMainEbos.hpp by prefixing with
this->.

Also rebased PR on the current master, and updated
flow_ebos_oilwater_brine.cpp according to the PR.
This commit is contained in:
Håkon Hægland 2020-08-24 08:35:04 +02:00
parent f9d47b7c68
commit c6752c1e0e
2 changed files with 11 additions and 10 deletions

View File

@ -85,8 +85,9 @@ int flowEbosOilWaterBrineMain(int argc, char** argv, bool outputCout, bool outpu
Dune::MPIHelper::instance(argc, argv);
#endif
Opm::FlowMainEbos<TTAG(EclFlowOilWaterBrineProblem)> mainfunc;
return mainfunc.execute(argc, argv, outputCout, outputFiles);
Opm::FlowMainEbos<TTAG(EclFlowOilWaterBrineProblem)>
mainfunc {argc, argv, outputCout, outputFiles};
return mainfunc.execute();
}
}

View File

@ -354,7 +354,7 @@ namespace Opm
try {
// deal with some administrative boilerplate
int status = setupParameters_(argc_, argv_);
int status = setupParameters_(this->argc_, this->argv_);
if (status)
return status;
@ -374,7 +374,7 @@ namespace Opm
std::ostringstream message;
message << "Program threw an exception: " << e.what();
if (output_cout_) {
if (this->output_cout_) {
// in some cases exceptions are thrown before the logging system is set
// up.
if (OpmLog::hasBackend("STREAMLOG")) {
@ -425,7 +425,7 @@ namespace Opm
// force closing of all log files.
OpmLog::removeAllBackends();
if (mpi_rank_ != 0 || mpi_size_ < 2 || !output_files_) {
if (mpi_rank_ != 0 || mpi_size_ < 2 || !this->output_files_) {
return;
}
@ -504,7 +504,7 @@ namespace Opm
// OpmLog singleton.
void runDiagnostics()
{
if (!output_cout_) {
if (!this->output_cout_) {
return;
}
@ -545,7 +545,7 @@ namespace Opm
// Output summary after simulation has completed
void runSimulatorAfterSim_(SimulatorReport &report)
{
if (output_cout_) {
if (this->output_cout_) {
std::ostringstream ss;
ss << "\n\n================ End of simulation ===============\n\n";
ss << "Number of MPI processes: " << std::setw(6) << mpi_size_ << "\n";
@ -582,7 +582,7 @@ namespace Opm
const auto& initConfig = eclState().getInitConfig();
simtimer_->init(timeMap, (size_t)initConfig.getRestartStep());
if (output_cout_) {
if (this->output_cout_) {
std::ostringstream oss;
// This allows a user to catch typos and misunderstandings in the
@ -595,7 +595,7 @@ namespace Opm
}
if (!ioConfig.initOnly()) {
if (output_cout_) {
if (this->output_cout_) {
std::string msg;
msg = "\n\n================ Starting main simulation loop ===============\n";
OpmLog::info(msg);
@ -604,7 +604,7 @@ namespace Opm
return (this->*initOrRunFunc)();
}
else {
if (output_cout_) {
if (this->output_cout_) {
std::cout << "\n\n================ Simulation turned off ===============\n" << std::flush;
}
return EXIT_SUCCESS;