From dfbc7759e177db280880656a42e57abc66f86de5 Mon Sep 17 00:00:00 2001 From: Weiqun Zhang Date: Mon, 8 Jan 2024 12:46:31 -0800 Subject: [PATCH] Fix warnings --- Source/Diagnostics/RecordingPlaneDiagnostics.H | 4 ++-- Source/Diagnostics/RecordingPlaneDiagnostics.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Source/Diagnostics/RecordingPlaneDiagnostics.H b/Source/Diagnostics/RecordingPlaneDiagnostics.H index 30600f647f9..1a0c7ccd07f 100644 --- a/Source/Diagnostics/RecordingPlaneDiagnostics.H +++ b/Source/Diagnostics/RecordingPlaneDiagnostics.H @@ -59,7 +59,7 @@ private: void Flush (int i_buffer, bool /*force_flush */) override; - void WriteRecordingPlaneHeader (const std::string& filename); + void WriteRecordingPlaneHeader (const std::string& filename) const; void PrepareFieldDataForOutput () override; @@ -76,7 +76,7 @@ private: amrex::Box m_buffer_box; int m_flush_counter = 0; - bool GetZSliceInDomain (int lev); + bool GetZSliceInDomain (int lev) const; bool m_last_timeslice_filled = false; }; diff --git a/Source/Diagnostics/RecordingPlaneDiagnostics.cpp b/Source/Diagnostics/RecordingPlaneDiagnostics.cpp index cdb5813ad10..2cce3c80052 100644 --- a/Source/Diagnostics/RecordingPlaneDiagnostics.cpp +++ b/Source/Diagnostics/RecordingPlaneDiagnostics.cpp @@ -210,7 +210,7 @@ RecordingPlaneDiagnostics::PrepareFieldDataForOutput () } bool -RecordingPlaneDiagnostics::GetZSliceInDomain (int lev) +RecordingPlaneDiagnostics::GetZSliceInDomain (int lev) const { auto & warpx = WarpX::GetInstance(); const amrex::RealBox& prob_domain = warpx.Geom(lev).ProbDomain(); @@ -422,7 +422,7 @@ RecordingPlaneDiagnostics::Flush (int i_buffer, bool /* force_flush */) } void -RecordingPlaneDiagnostics::WriteRecordingPlaneHeader (const std::string& filename) +RecordingPlaneDiagnostics::WriteRecordingPlaneHeader (const std::string& filename) const { amrex::VisMF::IO_Buffer io_buffer(amrex::VisMF::IO_Buffer_Size); std::ofstream HeaderFile;