From 68b7d9b07cdf6fe7406bf75487b9115127ebc7da Mon Sep 17 00:00:00 2001 From: Steven Hahn <hahnse@ornl.gov> Date: Tue, 7 Jun 2016 17:50:41 -0400 Subject: [PATCH] Append endl to strings --- Framework/API/src/AlgorithmHistory.cpp | 2 +- Framework/API/src/ExperimentInfo.cpp | 2 +- Framework/API/src/Expression.cpp | 4 +- Framework/API/src/FileLoaderRegistry.cpp | 2 +- Framework/API/src/FrameworkManager.cpp | 7 +- Framework/API/src/IFunction.cpp | 2 +- Framework/API/src/Run.cpp | 2 +- Framework/API/src/WorkspaceGroup.cpp | 2 +- .../src/ApplyTransmissionCorrection.cpp | 2 +- Framework/Algorithms/src/AverageLogData.cpp | 3 +- .../Algorithms/src/ConvertAxesToRealSpace.cpp | 2 +- Framework/Algorithms/src/ConvertUnits.cpp | 4 +- .../src/CopyInstrumentParameters.cpp | 3 +- Framework/Algorithms/src/CorrectKiKf.cpp | 3 +- .../src/CreateFlatEventWorkspace.cpp | 3 +- .../Algorithms/src/DetectorDiagnostic.cpp | 3 +- .../Algorithms/src/DiffractionFocussing.cpp | 2 +- .../Algorithms/src/DiffractionFocussing2.cpp | 3 +- .../Algorithms/src/EQSANSTofStructure.cpp | 8 +- .../src/FindCenterOfMassPosition.cpp | 11 +-- .../src/FindCenterOfMassPosition2.cpp | 12 +-- .../Algorithms/src/GenerateEventsFilter.cpp | 3 +- .../src/GetDetOffsetsMultiPeaks.cpp | 8 +- Framework/Algorithms/src/InvertMask.cpp | 4 +- Framework/Algorithms/src/MergeRuns.cpp | 4 +- .../Algorithms/src/NormaliseByCurrent.cpp | 3 +- Framework/Algorithms/src/Q1D2.cpp | 3 +- Framework/Algorithms/src/Q1DWeighted.cpp | 3 +- Framework/Algorithms/src/Qxy.cpp | 2 +- Framework/Algorithms/src/RadiusSum.cpp | 19 ++-- Framework/Algorithms/src/Rebin.cpp | 5 +- .../Algorithms/src/SANSDirectBeamScaling.cpp | 2 +- .../Algorithms/src/TOFSANSResolution.cpp | 2 +- .../src/TOFSANSResolutionByPixel.cpp | 3 +- Framework/Algorithms/src/WienerSmooth.cpp | 5 +- .../test/GenerateEventsFilterTest.h | 7 +- .../src/GoniometerAnglesFromPhiRotation.cpp | 5 +- .../Crystal/src/IntegratePeakTimeSlices.cpp | 6 +- Framework/Crystal/src/LoadIsawPeaks.cpp | 4 +- Framework/Crystal/src/PeakHKLErrors.cpp | 3 +- Framework/Crystal/src/PredictPeaks.cpp | 7 +- Framework/Crystal/src/SCDCalibratePanels.cpp | 4 +- Framework/Crystal/src/SaveIsawPeaks.cpp | 2 +- Framework/Crystal/src/SaveIsawUB.cpp | 3 +- .../src/Algorithms/FitPowderDiffPeaks.cpp | 14 ++- .../RefinePowderInstrumentParameters.cpp | 18 ++-- .../src/FuncMinimizers/DampingMinimizer.cpp | 3 +- .../src/FuncMinimizers/FABADAMinimizer.cpp | 3 +- .../LevenbergMarquardtMDMinimizer.cpp | 12 +-- .../src/Functions/CubicSpline.cpp | 6 +- .../src/Functions/ProcessBackground.cpp | 3 +- .../CurveFitting/src/ParameterEstimator.cpp | 2 +- .../test/Algorithms/FitPowderDiffPeaksTest.h | 3 +- .../RefinePowderInstrumentParameters3Test.h | 9 +- .../src/AppendGeometryToSNSNexus.cpp | 14 ++- .../DataHandling/src/DetermineChunking.cpp | 16 ++-- .../src/ImggAggregateWavelengths.cpp | 5 +- .../src/LoadDetectorsGroupingFile.cpp | 13 ++- Framework/DataHandling/src/LoadEventNexus.cpp | 11 ++- Framework/DataHandling/src/LoadFITS.cpp | 2 +- Framework/DataHandling/src/LoadILL.cpp | 7 +- Framework/DataHandling/src/LoadILLSANS.cpp | 4 +- Framework/DataHandling/src/LoadMLZ.cpp | 3 +- Framework/DataHandling/src/LoadMask.cpp | 18 ++-- Framework/DataHandling/src/LoadMcStas.cpp | 3 +- Framework/DataHandling/src/LoadNexusLogs.cpp | 9 +- .../DataHandling/src/LoadNexusMonitors2.cpp | 2 +- .../DataHandling/src/LoadNexusProcessed.cpp | 8 +- .../DataHandling/src/LoadPreNexusMonitors.cpp | 2 +- Framework/DataHandling/src/LoadRaw3.cpp | 6 +- Framework/DataHandling/src/LoadRawHelper.cpp | 7 +- Framework/DataHandling/src/MaskDetectors.cpp | 15 ++-- Framework/DataHandling/src/MergeLogs.cpp | 9 +- Framework/DataHandling/src/NexusTester.cpp | 3 +- .../DataHandling/src/ProcessDasNexusLog.cpp | 7 +- .../src/SaveDetectorsGrouping.cpp | 3 +- Framework/DataHandling/src/SaveFocusedXYE.cpp | 5 +- Framework/DataHandling/src/SaveIsawDetCal.cpp | 4 +- Framework/DataHandling/src/SaveMask.cpp | 3 +- .../DataHandling/src/SaveSavuTomoConfig.cpp | 2 +- .../test/LoadDetectorsGroupingFileTest.h | 2 +- Framework/DataHandling/test/LoadMaskTest.h | 4 +- Framework/DataHandling/test/LoadTBLTest.h | 18 ++-- Framework/DataObjects/src/MDBoxFlatTree.cpp | 3 +- .../DataObjects/src/SpecialWorkspace2D.cpp | 2 +- Framework/DataObjects/test/MDGridBoxTest.h | 12 +-- Framework/DataObjects/test/Workspace2DTest.h | 2 +- .../Instrument/InstrumentDefinitionParser.cpp | 6 +- .../Geometry/src/Instrument/ParameterMap.cpp | 4 +- .../ICat/src/CatalogDownloadDataFiles.cpp | 2 +- Framework/ICat/src/ICat3/ICat3Helper.cpp | 7 +- .../ICat/test/CatalogDownloadDataFilesTest.h | 8 +- Framework/Kernel/src/ConfigService.cpp | 87 +++++++------------ Framework/Kernel/src/FacilityInfo.cpp | 4 +- Framework/Kernel/src/PropertyManager.cpp | 3 +- Framework/Kernel/test/ConfigServiceTest.h | 2 +- .../Kernel/test/DiskBufferISaveableTest.h | 3 +- Framework/Kernel/test/LogParserTest.h | 60 ++++++------- .../src/ISISLiveEventDataListener.cpp | 9 +- Framework/LiveData/src/LoadLiveData.cpp | 3 +- Framework/LiveData/src/MonitorLiveData.cpp | 6 +- .../LiveData/src/SNSLiveEventDataListener.cpp | 46 +++++----- .../src/TOPAZLiveEventDataListener.cpp | 7 +- .../LiveData/test/FakeEventDataListenerTest.h | 2 +- Framework/MDAlgorithms/src/AccumulateMD.cpp | 4 +- .../MDAlgorithms/src/CentroidPeaksMD.cpp | 7 +- .../MDAlgorithms/src/CentroidPeaksMD2.cpp | 3 +- .../MDAlgorithms/src/CloneMDWorkspace.cpp | 2 +- .../src/ConvertToDiffractionMDWorkspace.cpp | 6 +- Framework/MDAlgorithms/src/FindPeaksMD.cpp | 4 +- .../MDAlgorithms/src/IntegratePeaksMD.cpp | 4 +- .../MDAlgorithms/src/LoadILLAsciiHelper.cpp | 6 +- Framework/MDAlgorithms/src/LoadMD.cpp | 6 +- Framework/MDAlgorithms/src/LoadSQW.cpp | 11 +-- Framework/MDAlgorithms/src/MergeMDFiles.cpp | 4 +- Framework/MDAlgorithms/src/SaveZODS.cpp | 5 +- .../src/PythonAlgorithm/AlgorithmAdapter.cpp | 3 +- .../src/DownloadRemoteFile.cpp | 2 +- .../src/DownloadRemoteFile2.cpp | 3 +- .../src/SCARFTomoReconstruction.cpp | 11 ++- .../src/StartRemoteTransaction.cpp | 2 +- .../src/StopRemoteTransaction.cpp | 2 +- .../src/MantidWebServiceAPIJobManager.cpp | 4 +- Framework/SINQ/src/PoldiAutoCorrelation5.cpp | 12 ++- .../SINQ/src/PoldiIndexKnownCompounds.cpp | 7 +- Framework/SINQ/src/PoldiPeakSearch.cpp | 13 ++- Framework/SINQ/src/PoldiTruncateData.cpp | 3 +- .../PoldiAutoCorrelationCore.cpp | 4 +- Framework/SINQ/src/SINQHMListener.cpp | 2 +- .../src/ScriptRepositoryImpl.cpp | 27 +++--- .../WorkflowAlgorithms/src/DgsReduction.cpp | 2 +- .../src/EQSANSDarkCurrentSubtraction.cpp | 3 +- .../src/EQSANSDarkCurrentSubtraction2.cpp | 14 ++- .../WorkflowAlgorithms/src/EQSANSLoad.cpp | 16 ++-- .../src/EQSANSMonitorTOF.cpp | 16 ++-- .../src/EQSANSPatchSensitivity.cpp | 3 +- Framework/WorkflowAlgorithms/src/HFIRLoad.cpp | 3 +- .../WorkflowAlgorithms/src/RefReduction.cpp | 8 +- Framework/WorkflowAlgorithms/src/RefRoi.cpp | 3 +- .../src/SANSSolidAngleCorrection.cpp | 4 +- .../src/SetupEQSANSReduction.cpp | 2 +- .../src/SetupHFIRReduction.cpp | 2 +- .../src/SetupILLD33Reduction.cpp | 2 +- MantidPlot/src/ApplicationWindow.cpp | 7 +- MantidPlot/src/Mantid/MantidUI.cpp | 4 +- MantidPlot/src/main.cpp | 2 +- .../CustomInterfaces/src/DataComparison.cpp | 3 +- .../EnggDiffractionPresenter.cpp | 49 +++++------ .../src/Indirect/IndirectDataReduction.cpp | 5 +- .../CustomInterfaces/src/MantidEVWorker.cpp | 8 +- .../CustomInterfaces/src/SANSDiagnostics.cpp | 15 ++-- .../ImggFormatsConvertPresenter.cpp | 2 +- .../src/IndirectInstrumentConfig.cpp | 6 +- .../src/InstrumentView/PanelsSurface.cpp | 8 +- .../SpectrumViewer/src/MatrixWSDataSource.cpp | 5 +- Vates/VatesAPI/src/vtkMDHexFactory.cpp | 3 +- 156 files changed, 462 insertions(+), 635 deletions(-) diff --git a/Framework/API/src/AlgorithmHistory.cpp b/Framework/API/src/AlgorithmHistory.cpp index 1a6130fc05d..5dabbe92606 100644 --- a/Framework/API/src/AlgorithmHistory.cpp +++ b/Framework/API/src/AlgorithmHistory.cpp @@ -195,7 +195,7 @@ void AlgorithmHistory::printSelf(std::ostream &os, const int indent) const { os << std::string(indent, ' ') << "Execution Date: " << m_executionDate.toFormattedString() << '\n'; os << std::string(indent, ' ') - << "Execution Duration: " << m_executionDuration << " seconds" << '\n'; + << "Execution Duration: " << m_executionDuration << " seconds\n"; os << std::string(indent, ' ') << "Parameters:\n"; diff --git a/Framework/API/src/ExperimentInfo.cpp b/Framework/API/src/ExperimentInfo.cpp index 024a3ccacb7..5943069f613 100644 --- a/Framework/API/src/ExperimentInfo.cpp +++ b/Framework/API/src/ExperimentInfo.cpp @@ -814,7 +814,7 @@ ExperimentInfo::getInstrumentFilename(const std::string &instrumentName, const std::string &date) { if (date.empty()) { // Just use the current date - g_log.debug() << "No date specified, using current date and time." << '\n'; + g_log.debug() << "No date specified, using current date and time.\n"; const std::string now = Kernel::DateAndTime::getCurrentTime().toISO8601String(); // Recursively call this method, but with both parameters. diff --git a/Framework/API/src/Expression.cpp b/Framework/API/src/Expression.cpp index fcdd3ce4036..c9d2eb82650 100644 --- a/Framework/API/src/Expression.cpp +++ b/Framework/API/src/Expression.cpp @@ -354,10 +354,10 @@ std::string Expression::GetOp(size_t i) { void Expression::logPrint(const std::string &pads) const { std::string myPads = pads + " "; if (!m_terms.empty()) { - std::cerr << myPads << m_op << '[' << m_funct << ']' << "(" << '\n'; + std::cerr << myPads << m_op << '[' << m_funct << ']' << "(\n"; for (const auto &term : m_terms) term.logPrint(myPads); - std::cerr << myPads << ")" << '\n'; + std::cerr << myPads << ")\n"; } else std::cerr << myPads << m_op << m_funct << '\n'; } diff --git a/Framework/API/src/FileLoaderRegistry.cpp b/Framework/API/src/FileLoaderRegistry.cpp index 6aa8e2e6c33..f5bea8254e6 100644 --- a/Framework/API/src/FileLoaderRegistry.cpp +++ b/Framework/API/src/FileLoaderRegistry.cpp @@ -99,7 +99,7 @@ FileLoaderRegistryImpl::chooseLoader(const std::string &filename) const { using Kernel::FileDescriptor; using Kernel::NexusDescriptor; - m_log.debug() << "Trying to find loader for '" << filename << "'" << '\n'; + m_log.debug() << "Trying to find loader for '" << filename << "'\n"; IAlgorithm_sptr bestLoader; if (NexusDescriptor::isHDF(filename)) { diff --git a/Framework/API/src/FrameworkManager.cpp b/Framework/API/src/FrameworkManager.cpp index d3763d4002b..25a5dd9981c 100644 --- a/Framework/API/src/FrameworkManager.cpp +++ b/Framework/API/src/FrameworkManager.cpp @@ -93,9 +93,8 @@ void FrameworkManagerImpl::AsynchronousStartupTasks() { if ((retVal == 1) && (updateInstrumentDefinitions == 1)) { UpdateInstrumentDefinitions(); } else { - g_log.information() - << "Instrument updates disabled - cannot update instrument definitions." - << '\n'; + g_log.information() << "Instrument updates disabled - cannot update " + "instrument definitions.\n"; } int checkIfNewerVersionIsAvailable = 0; @@ -402,7 +401,7 @@ bool FrameworkManagerImpl::deleteWorkspace(const std::string &wsName) { retVal = true; } catch (Kernel::Exception::NotFoundError &) { // workspace was not found - g_log.error() << "Workspace " << wsName << " could not be found." << '\n'; + g_log.error() << "Workspace " << wsName << " could not be found.\n"; retVal = false; } return retVal; diff --git a/Framework/API/src/IFunction.cpp b/Framework/API/src/IFunction.cpp index ffd36a058e7..85c03275a41 100644 --- a/Framework/API/src/IFunction.cpp +++ b/Framework/API/src/IFunction.cpp @@ -832,7 +832,7 @@ void IFunction::setMatrixWorkspace( paramValue *= p.Eval(); g_log.debug() << "The FitParameter " << parameterName(i) << " = " << paramValue - << " after result-unit convertion" << '\n'; + << " after result-unit convertion\n"; } catch (mu::Parser::exception_type &e) { g_log.error() << "Cannot convert formula unit to workspace unit" diff --git a/Framework/API/src/Run.cpp b/Framework/API/src/Run.cpp index c34ba349082..0a6411fd44e 100644 --- a/Framework/API/src/Run.cpp +++ b/Framework/API/src/Run.cpp @@ -148,7 +148,7 @@ double Run::getProtonCharge() const { charge = m_manager.getProperty(PROTON_CHARGE_LOG_NAME); } else { g_log.warning() << PROTON_CHARGE_LOG_NAME - << " log was not found. Proton Charge set to 0.0" << '\n'; + << " log was not found. Proton Charge set to 0.0\n"; } return charge; } diff --git a/Framework/API/src/WorkspaceGroup.cpp b/Framework/API/src/WorkspaceGroup.cpp index 7d55093e1b9..8952f854587 100644 --- a/Framework/API/src/WorkspaceGroup.cpp +++ b/Framework/API/src/WorkspaceGroup.cpp @@ -110,7 +110,7 @@ void WorkspaceGroup::addWorkspace(Workspace_sptr workspace) { if (it == m_workspaces.end()) { m_workspaces.push_back(workspace); } else { - g_log.warning() << "Workspace already exists in a WorkspaceGroup" << '\n'; + g_log.warning() << "Workspace already exists in a WorkspaceGroup\n"; ; } } diff --git a/Framework/Algorithms/src/ApplyTransmissionCorrection.cpp b/Framework/Algorithms/src/ApplyTransmissionCorrection.cpp index 7b4c5859b5d..bf02a14b2ab 100644 --- a/Framework/Algorithms/src/ApplyTransmissionCorrection.cpp +++ b/Framework/Algorithms/src/ApplyTransmissionCorrection.cpp @@ -99,7 +99,7 @@ void ApplyTransmissionCorrection::exec() { det = inputWS->getDetector(i); } catch (Exception::NotFoundError &) { g_log.warning() << "Workspace index " << i - << " has no detector assigned to it - discarding" << '\n'; + << " has no detector assigned to it - discarding'\n"; // Catch if no detector. Next line tests whether this happened - test // placed // outside here because Mac Intel compiler doesn't like 'continue' in a diff --git a/Framework/Algorithms/src/AverageLogData.cpp b/Framework/Algorithms/src/AverageLogData.cpp index 5eb8cd43665..5b62de52be8 100644 --- a/Framework/Algorithms/src/AverageLogData.cpp +++ b/Framework/Algorithms/src/AverageLogData.cpp @@ -117,8 +117,7 @@ void AverageLogData::exec() { if (protoncharge != 0) { g_log.warning() - << "Proton charge is 0. Average and standard deviations are NANs" - << '\n'; + << "Proton charge is 0. Average and standard deviations are NANs\n"; } g_log.debug() << "Sum = " << average << std::endl << "Sum squares = " << error << std::endl diff --git a/Framework/Algorithms/src/ConvertAxesToRealSpace.cpp b/Framework/Algorithms/src/ConvertAxesToRealSpace.cpp index d9fb516f6fd..4369eb4c419 100644 --- a/Framework/Algorithms/src/ConvertAxesToRealSpace.cpp +++ b/Framework/Algorithms/src/ConvertAxesToRealSpace.cpp @@ -186,7 +186,7 @@ void ConvertAxesToRealSpace::exec() { } g_log.warning() << "Could not find detector for " << failedCount - << " spectra, see the debug log for more details." << '\n'; + << " spectra, see the debug log for more details.\n"; // set up the axes on the output workspace MantidVecPtr x, y; diff --git a/Framework/Algorithms/src/ConvertUnits.cpp b/Framework/Algorithms/src/ConvertUnits.cpp index 1719d15e201..81cd07e4d7b 100644 --- a/Framework/Algorithms/src/ConvertUnits.cpp +++ b/Framework/Algorithms/src/ConvertUnits.cpp @@ -518,8 +518,8 @@ void ConvertUnits::convertViaTOF(Kernel::Unit_const_sptr fromUnit, if (failedDetectorCount != 0) { g_log.information() << "Unable to calculate sample-detector distance for " - << failedDetectorCount << " spectra. Masking spectrum." - << '\n'; + << failedDetectorCount + << " spectra. Masking spectrum.\n"; } if (m_inputEvents) eventWS->clearMRU(); diff --git a/Framework/Algorithms/src/CopyInstrumentParameters.cpp b/Framework/Algorithms/src/CopyInstrumentParameters.cpp index 761a049c0bb..064fce85543 100644 --- a/Framework/Algorithms/src/CopyInstrumentParameters.cpp +++ b/Framework/Algorithms/src/CopyInstrumentParameters.cpp @@ -133,8 +133,7 @@ void CopyInstrumentParameters::checkProperties() { if (baseInstRec != baseInstGiv) { m_different_instrument_sp = true; g_log.warning() << "The base instrument in the output workspace is not the " - "same as the base instrument in the input workspace." - << '\n'; + "same as the base instrument in the input workspace.\n"; } } diff --git a/Framework/Algorithms/src/CorrectKiKf.cpp b/Framework/Algorithms/src/CorrectKiKf.cpp index 73218228019..071e48e5197 100644 --- a/Framework/Algorithms/src/CorrectKiKf.cpp +++ b/Framework/Algorithms/src/CorrectKiKf.cpp @@ -177,8 +177,7 @@ void CorrectKiKf::exec() { PARALLEL_CHECK_INTERUPT_REGION if (negativeEnergyWarning) - g_log.information() << "Ef <= 0 or Ei <= 0 in at least one spectrum!!!!" - << '\n'; + g_log.information() << "Ef <= 0 or Ei <= 0 in at least one spectrum!!!!\n"; if ((negativeEnergyWarning) && (efixedProp == EMPTY_DBL())) g_log.information() << "Try to set fixed energy\n"; this->setProperty("OutputWorkspace", outputWS); diff --git a/Framework/Algorithms/src/CreateFlatEventWorkspace.cpp b/Framework/Algorithms/src/CreateFlatEventWorkspace.cpp index a139850a8fd..6421e6fc6ed 100644 --- a/Framework/Algorithms/src/CreateFlatEventWorkspace.cpp +++ b/Framework/Algorithms/src/CreateFlatEventWorkspace.cpp @@ -76,8 +76,7 @@ void CreateFlatEventWorkspace::exec() { double dataMin, dataMax; inputWS->getEventXMinMax(dataMin, dataMax); - g_log.debug() << "Data Range (" << dataMin << " < x < " << dataMax << ")" - << '\n'; + g_log.debug() << "Data Range (" << dataMin << " < x < " << dataMax << ")\n"; // How many times do we need to replicate the extracted background region in // order to fill up diff --git a/Framework/Algorithms/src/DetectorDiagnostic.cpp b/Framework/Algorithms/src/DetectorDiagnostic.cpp index 03cded1a0a6..ff77fd151ca 100644 --- a/Framework/Algorithms/src/DetectorDiagnostic.cpp +++ b/Framework/Algorithms/src/DetectorDiagnostic.cpp @@ -504,8 +504,7 @@ MatrixWorkspace_sptr DetectorDiagnostic::integrateSpectra( MatrixWorkspace_sptr finalOutputW = outputW; if (outputWorkspace2D && boost::dynamic_pointer_cast<EventWorkspace>(outputW)) { - g_log.debug() << "Converting output Event Workspace into a Workspace2D." - << '\n'; + g_log.debug() << "Converting output Event Workspace into a Workspace2D.\n"; childAlg = createChildAlgorithm("ConvertToMatrixWorkspace", t0, t1); childAlg->setProperty("InputWorkspace", outputW); childAlg->executeAsChildAlg(); diff --git a/Framework/Algorithms/src/DiffractionFocussing.cpp b/Framework/Algorithms/src/DiffractionFocussing.cpp index 488bd67e65f..d8e902325f4 100644 --- a/Framework/Algorithms/src/DiffractionFocussing.cpp +++ b/Framework/Algorithms/src/DiffractionFocussing.cpp @@ -124,7 +124,7 @@ void DiffractionFocussing::exec() { ++discarded; } g_log.warning() << "Discarded " << discarded - << " spectra that were not assigned to any group" << '\n'; + << " spectra that were not assigned to any group\n"; // Running GroupDetectors leads to a load of redundant spectra // Create a new workspace that's the right size for the meaningful spectra and diff --git a/Framework/Algorithms/src/DiffractionFocussing2.cpp b/Framework/Algorithms/src/DiffractionFocussing2.cpp index 7523dc1e265..e0abe33fdba 100644 --- a/Framework/Algorithms/src/DiffractionFocussing2.cpp +++ b/Framework/Algorithms/src/DiffractionFocussing2.cpp @@ -107,8 +107,7 @@ void DiffractionFocussing2::exec() { Axis *axis = m_matrixInputW->getAxis(0); std::string unitid = axis->unit()->unitID(); if (unitid != "dSpacing" && unitid != "MomentumTransfer" && unitid != "TOF") { - g_log.error() << "UnitID " << unitid << " is not a supported spacing" - << '\n'; + g_log.error() << "UnitID " << unitid << " is not a supported spacing\n"; throw new std::invalid_argument("Workspace Invalid Spacing/UnitID"); } // --- Do we need to read the grouping workspace? ---- diff --git a/Framework/Algorithms/src/EQSANSTofStructure.cpp b/Framework/Algorithms/src/EQSANSTofStructure.cpp index a9344934245..688d59d668d 100644 --- a/Framework/Algorithms/src/EQSANSTofStructure.cpp +++ b/Framework/Algorithms/src/EQSANSTofStructure.cpp @@ -137,7 +137,7 @@ void EQSANSTofStructure::execEvent( det = inputWS->getDetector(ispec); } catch (Exception::NotFoundError &) { g_log.warning() << "Workspace index " << ispec - << " has no detector assigned to it - discarding" << '\n'; + << " has no detector assigned to it - discarding\n"; // 'continue' statement moved outside catch block because Mac Intel // compiler has a problem with it being here in an openmp block. } @@ -453,8 +453,7 @@ double EQSANSTofStructure::getTofOffset(EventWorkspace_const_sptr inputWS, frame_tof0 = frame_srcpulse_wl_1 / 3.9560346 * source_to_detector; g_log.information() << "Frame width " << tmp_frame_width << '\n'; - g_log.information() << "TOF offset = " << frame_tof0 << " microseconds" - << '\n'; + g_log.information() << "TOF offset = " << frame_tof0 << " microseconds\n"; g_log.information() << "Band defined by T1-T4 " << frame_wl_1 << " " << frame_wl_2; if (frame_skipping) @@ -462,8 +461,7 @@ double EQSANSTofStructure::getTofOffset(EventWorkspace_const_sptr inputWS, << '\n'; else g_log.information() << '\n'; - g_log.information() << "Chopper Actual Phase Lambda1 Lambda2" - << '\n'; + g_log.information() << "Chopper Actual Phase Lambda1 Lambda2\n"; for (int i = 0; i < 4; i++) g_log.information() << i << " " << chopper_actual_phase[i] << " " << chopper_wl_1[i] << " " << chopper_wl_2[i] << '\n'; diff --git a/Framework/Algorithms/src/FindCenterOfMassPosition.cpp b/Framework/Algorithms/src/FindCenterOfMassPosition.cpp index 83e04dcfe13..c977648fca9 100644 --- a/Framework/Algorithms/src/FindCenterOfMassPosition.cpp +++ b/Framework/Algorithms/src/FindCenterOfMassPosition.cpp @@ -120,8 +120,7 @@ void FindCenterOfMassPosition::exec() { det = inputWS->getDetector(i); } catch (Exception::NotFoundError &) { g_log.warning() << "Workspace index " << i - << " has no detector assigned to it - discarding" - << '\n'; + << " has no detector assigned to it - discarding\n"; continue; } // If this detector is masked, skip to the next one @@ -164,9 +163,8 @@ void FindCenterOfMassPosition::exec() { double radius_y = std::min((position_y - ymin0), (ymax0 - position_y)); if (!direct_beam && (radius_x <= beam_radius || radius_y <= beam_radius)) { - g_log.error() - << "Center of mass falls within the beam center area: stopping here" - << '\n'; + g_log.error() << "Center of mass falls within the beam center area: " + "stopping here\n"; break; } @@ -196,8 +194,7 @@ void FindCenterOfMassPosition::exec() { // Quit if we haven't converged after the maximum number of iterations. if (++n_iteration > max_iteration) { g_log.warning() << "More than " << max_iteration - << " iteration to find beam center: stopping here" - << '\n'; + << " iteration to find beam center: stopping here\n"; break; } diff --git a/Framework/Algorithms/src/FindCenterOfMassPosition2.cpp b/Framework/Algorithms/src/FindCenterOfMassPosition2.cpp index fe6fca70849..2f4579df4b0 100644 --- a/Framework/Algorithms/src/FindCenterOfMassPosition2.cpp +++ b/Framework/Algorithms/src/FindCenterOfMassPosition2.cpp @@ -155,8 +155,7 @@ void FindCenterOfMassPosition2::exec() { det = inputWS->getDetector(i); } catch (Exception::NotFoundError &) { g_log.warning() << "Workspace index " << i - << " has no detector assigned to it - discarding" - << '\n'; + << " has no detector assigned to it - discarding\n"; continue; } // If this detector is masked, skip to the next one @@ -207,10 +206,8 @@ void FindCenterOfMassPosition2::exec() { double radius_y = std::min((position_y - ymin0), (ymax0 - position_y)); if (!direct_beam && (radius_x <= beam_radius || radius_y <= beam_radius)) { - g_log.error() - << "Center of mass falls within the beam center area: stopping here" - << '\n'; - break; + g_log.error() << "Center of mass falls within the beam center area: " + "stopping here\n" break; } center_x = position_x; @@ -239,8 +236,7 @@ void FindCenterOfMassPosition2::exec() { // Quit if we haven't converged after the maximum number of iterations. if (++n_iteration > max_iteration) { g_log.warning() << "More than " << max_iteration - << " iteration to find beam center: stopping here" - << '\n'; + << " iteration to find beam center: stopping here\n"; break; } diff --git a/Framework/Algorithms/src/GenerateEventsFilter.cpp b/Framework/Algorithms/src/GenerateEventsFilter.cpp index eeb13a12621..5f81abaca99 100644 --- a/Framework/Algorithms/src/GenerateEventsFilter.cpp +++ b/Framework/Algorithms/src/GenerateEventsFilter.cpp @@ -783,8 +783,7 @@ void GenerateEventsFilter::processMultipleValueFilters(double minvalue, << " with interval size = " << valueinterval << "; Log " << m_dblLog->name() << " has range " << minlogvalue << " to " << maxlogvalue - << ". Therefore some workgroup index may not have any splitter." - << '\n'; + << ". Therefore some workgroup index may not have any splitter.\n"; } } diff --git a/Framework/Algorithms/src/GetDetOffsetsMultiPeaks.cpp b/Framework/Algorithms/src/GetDetOffsetsMultiPeaks.cpp index be8e5b0ce8b..a20368f7a36 100644 --- a/Framework/Algorithms/src/GetDetOffsetsMultiPeaks.cpp +++ b/Framework/Algorithms/src/GetDetOffsetsMultiPeaks.cpp @@ -1328,16 +1328,16 @@ void GetDetOffsetsMultiPeaks::makeFitSummary() { if (0 == numunmasked) { g_log.warning() << "Found 0 unmasked rows in the spectra info table. " - "Cannot calculate Chi-sq sensibly. it's value will be NaN" << '\n'; + "Cannot calculate Chi-sq sensibly. it's value will be NaN\n"; avgchi2 = NAN; } else { avgchi2 = sumchi2 / static_cast<double>(numunmasked); } if (0 == weight_numfittedpeaks) { - g_log.warning() << "Found 0 fitted peaks in the spectra info table. " - "Cannot calculate the weighted average Chi-sq sensibly" - << '\n'; + g_log.warning() + << "Found 0 fitted peaks in the spectra info table. " + "Cannot calculate the weighted average Chi-sq sensibly\n"; wtavgchi2 = NAN; } else { wtavgchi2 = weight_sumchi2 / static_cast<double>(weight_numfittedpeaks); diff --git a/Framework/Algorithms/src/InvertMask.cpp b/Framework/Algorithms/src/InvertMask.cpp index 6e63903662a..420643e9bf2 100644 --- a/Framework/Algorithms/src/InvertMask.cpp +++ b/Framework/Algorithms/src/InvertMask.cpp @@ -51,8 +51,8 @@ void InvertMask::exec() { invert->execute(); if (!invert->isExecuted()) { - g_log.error() << "ChildAlgorithm BinaryOperateMask() cannot be executed. " - << '\n'; + g_log.error() + << "ChildAlgorithm BinaryOperateMask() cannot be executed. \n"; throw std::runtime_error( "ChildAlgorithm BinaryOperateMask() cannot be executed. "); } diff --git a/Framework/Algorithms/src/MergeRuns.cpp b/Framework/Algorithms/src/MergeRuns.cpp index 127d89c3e04..35223d39d9d 100644 --- a/Framework/Algorithms/src/MergeRuns.cpp +++ b/Framework/Algorithms/src/MergeRuns.cpp @@ -427,8 +427,8 @@ MergeRuns::validateInputs(const std::vector<std::string> &inputWorkspaces) { } inWS.push_back(ws); } catch (Exception::NotFoundError &) { - g_log.error() << "Input workspace " << inputWorkspaces[i] << " not found." - << '\n'; + g_log.error() << "Input workspace " << inputWorkspaces[i] + << " not found.\n"; throw; } // Check that it has common binning diff --git a/Framework/Algorithms/src/NormaliseByCurrent.cpp b/Framework/Algorithms/src/NormaliseByCurrent.cpp index 25efc5ca798..04dcc6ef352 100644 --- a/Framework/Algorithms/src/NormaliseByCurrent.cpp +++ b/Framework/Algorithms/src/NormaliseByCurrent.cpp @@ -112,8 +112,7 @@ void NormaliseByCurrent::exec() { // Get the good proton charge and check it's valid double charge = extractCharge(inputWS); - g_log.information() << "Normalisation current: " << charge << " uamps" - << '\n'; + g_log.information() << "Normalisation current: " << charge << " uamps\n"; double invcharge = 1.0 / charge; // Inverse of the charge to be multiplied by diff --git a/Framework/Algorithms/src/Q1D2.cpp b/Framework/Algorithms/src/Q1D2.cpp index a1bb398c1c7..2f9f1587607 100644 --- a/Framework/Algorithms/src/Q1D2.cpp +++ b/Framework/Algorithms/src/Q1D2.cpp @@ -162,8 +162,7 @@ void Q1D2::exec() { } catch (Exception::NotFoundError &) { g_log.warning() << "Workspace index " << i << " (SpectrumIndex = " << m_dataWS->getSpectrum(i)->getSpectrumNo() - << ") has no detector assigned to it - discarding" - << '\n'; + << ") has no detector assigned to it - discarding\n"; // Catch if no detector. Next line tests whether this happened - test // placed // outside here because Mac Intel compiler doesn't like 'continue' in a diff --git a/Framework/Algorithms/src/Q1DWeighted.cpp b/Framework/Algorithms/src/Q1DWeighted.cpp index 6ceab7f947c..0f693088219 100644 --- a/Framework/Algorithms/src/Q1DWeighted.cpp +++ b/Framework/Algorithms/src/Q1DWeighted.cpp @@ -185,8 +185,7 @@ void Q1DWeighted::exec() { det = inputWS->getDetector(i); } catch (Exception::NotFoundError &) { g_log.warning() << "Workspace index " << i - << " has no detector assigned to it - discarding" - << '\n'; + << " has no detector assigned to it - discarding\n"; // Catch if no detector. Next line tests whether this happened - test // placed // outside here because Mac Intel compiler doesn't like 'continue' in a diff --git a/Framework/Algorithms/src/Qxy.cpp b/Framework/Algorithms/src/Qxy.cpp index b34718be57b..04512df1282 100644 --- a/Framework/Algorithms/src/Qxy.cpp +++ b/Framework/Algorithms/src/Qxy.cpp @@ -133,7 +133,7 @@ void Qxy::exec() { det = inputWorkspace->getDetector(i); } catch (Exception::NotFoundError &) { g_log.warning() << "Workspace index " << i - << " has no detector assigned to it - discarding" << '\n'; + << " has no detector assigned to it - discarding\n"; // Catch if no detector. Next line tests whether this happened - test // placed // outside here because Mac Intel compiler doesn't like 'continue' in a diff --git a/Framework/Algorithms/src/RadiusSum.cpp b/Framework/Algorithms/src/RadiusSum.cpp index 89a376bb2b6..743bdcfab16 100644 --- a/Framework/Algorithms/src/RadiusSum.cpp +++ b/Framework/Algorithms/src/RadiusSum.cpp @@ -122,8 +122,7 @@ std::vector<double> RadiusSum::processInstrumentRadiusSum() { std::vector<double> accumulator(num_bins, 0); g_log.debug() << "For every detector in the image get its position " - << " and sum up all the counts inside the related spectrum" - << '\n'; + << " and sum up all the counts inside the related spectrum\n"; for (size_t i = 0; i < inputWS->getNumberHistograms(); i++) { try { auto det = inputWS->getDetector(i); @@ -179,8 +178,7 @@ std::vector<double> RadiusSum::processNumericImageRadiusSum() { x_pos[ind] = (refX[ind] + refX[ind + 1]) / 2.0; } - g_log.debug() << "For every pixel define its bin position and sum them up" - << '\n'; + g_log.debug() << "For every pixel define its bin position and sum them up\n"; // for each row in the image for (size_t i = 0; i < inputWS->getNumberHistograms(); i++) { @@ -233,8 +231,7 @@ void RadiusSum::cacheInputPropertyValues() { centre = V3D(centre_aux[0], centre_aux[1], centre_aux[2]); g_log.debug() - << "Copy the remaning properties: MinRadius, MaxRadius and NumBins" - << '\n'; + << "Copy the remaning properties: MinRadius, MaxRadius and NumBins\n"; min_radius = getProperty("MinRadius"); max_radius = getProperty("MaxRadius"); num_bins = getProperty("NumBins"); @@ -262,7 +259,7 @@ void RadiusSum::inputValidationSanityCheck() { "image or instrument\n"; centerIsInsideLimits(getProperty("centre"), boundary_limits); - g_log.debug() << "Recalculate MaxRadius if default value is given" << '\n'; + g_log.debug() << "Recalculate MaxRadius if default value is given\n"; if (max_radius > 0.9 * std::numeric_limits<double>::max()) { max_radius = getMaxDistance(centre, boundary_limits); g_log.notice() << "RadiusMax automatically calculated and set to " @@ -270,8 +267,7 @@ void RadiusSum::inputValidationSanityCheck() { } g_log.debug() - << "Check number of bins to alert user if many bins will end up empty" - << '\n'; + << "Check number of bins to alert user if many bins will end up empty\n"; numBinsIsReasonable(); } @@ -585,8 +581,7 @@ double RadiusSum::getMinBinSizeForNumericImage(API::MatrixWorkspace_sptr inWS) { void RadiusSum::normalizeOutputByRadius(std::vector<double> &values, double exp_power) { g_log.debug() - << "Normalization of the output in relation to the 'radius' (distance)" - << '\n'; + << "Normalization of the output in relation to the 'radius' (distance)\n"; // the radius can be defined as: // radius_min + bin_size/2 + n * bin_size ; for 0<= n <= num_bins @@ -634,7 +629,7 @@ double RadiusSum::getMaxDistance(const V3D ¢re, void RadiusSum::setUpOutputWorkspace(std::vector<double> &values) { - g_log.debug() << "Output calculated, setting up the output workspace" << '\n'; + g_log.debug() << "Output calculated, setting up the output workspace\n"; API::MatrixWorkspace_sptr outputWS = API::WorkspaceFactory::Instance().create( inputWS, 1, values.size() + 1, values.size()); diff --git a/Framework/Algorithms/src/Rebin.cpp b/Framework/Algorithms/src/Rebin.cpp index 361b053401d..b146c7a6c74 100644 --- a/Framework/Algorithms/src/Rebin.cpp +++ b/Framework/Algorithms/src/Rebin.cpp @@ -219,7 +219,7 @@ void Rebin::exec() { { //------- Workspace2D or other MatrixWorkspace --------------------------- if (!isHist) { - g_log.information() << "Rebin: Converting Data to Histogram." << '\n'; + g_log.information() << "Rebin: Converting Data to Histogram.\n"; Mantid::API::Algorithm_sptr ChildAlg = createChildAlgorithm("ConvertToHistogram"); ChildAlg->initialize(); @@ -287,8 +287,7 @@ void Rebin::exec() { } if (!isHist) { - g_log.information() << "Rebin: Converting Data back to Data Points." - << '\n'; + g_log.information() << "Rebin: Converting Data back to Data Points.\n"; Mantid::API::Algorithm_sptr ChildAlg = createChildAlgorithm("ConvertToPointData"); ChildAlg->initialize(); diff --git a/Framework/Algorithms/src/SANSDirectBeamScaling.cpp b/Framework/Algorithms/src/SANSDirectBeamScaling.cpp index 48347062fcb..0afd782d6c6 100644 --- a/Framework/Algorithms/src/SANSDirectBeamScaling.cpp +++ b/Framework/Algorithms/src/SANSDirectBeamScaling.cpp @@ -107,7 +107,7 @@ void SANSDirectBeamScaling::exec() { det = inputWS->getDetector(i); } catch (Exception::NotFoundError &) { g_log.warning() << "Workspace index " << i - << " has no detector assigned to it - discarding" << '\n'; + << " has no detector assigned to it - discarding\n"; continue; } diff --git a/Framework/Algorithms/src/TOFSANSResolution.cpp b/Framework/Algorithms/src/TOFSANSResolution.cpp index a51d85293d6..b139d3e9314 100644 --- a/Framework/Algorithms/src/TOFSANSResolution.cpp +++ b/Framework/Algorithms/src/TOFSANSResolution.cpp @@ -133,7 +133,7 @@ void TOFSANSResolution::exec() { det = reducedWS->getDetector(i); } catch (Exception::NotFoundError &) { g_log.warning() << "Workspace index " << i - << " has no detector assigned to it - discarding" << '\n'; + << " has no detector assigned to it - discarding\n"; // Catch if no detector. Next line tests whether this happened - test // placed // outside here because Mac Intel compiler doesn't like 'continue' in a diff --git a/Framework/Algorithms/src/TOFSANSResolutionByPixel.cpp b/Framework/Algorithms/src/TOFSANSResolutionByPixel.cpp index 78c8dde877d..9d6f8de049b 100644 --- a/Framework/Algorithms/src/TOFSANSResolutionByPixel.cpp +++ b/Framework/Algorithms/src/TOFSANSResolutionByPixel.cpp @@ -142,8 +142,7 @@ void TOFSANSResolutionByPixel::exec() { det = inWS->getDetector(i); } catch (Exception::NotFoundError &) { g_log.information() << "Workspace index " << i - << " has no detector assigned to it - discarding" - << '\n'; + << " has no detector assigned to it - discarding\n"; } // If no detector found or if it's masked or a monitor, skip onto the next // spectrum diff --git a/Framework/Algorithms/src/WienerSmooth.cpp b/Framework/Algorithms/src/WienerSmooth.cpp index d9c93bd9d32..e0cd5c911ba 100644 --- a/Framework/Algorithms/src/WienerSmooth.cpp +++ b/Framework/Algorithms/src/WienerSmooth.cpp @@ -326,7 +326,7 @@ WienerSmooth::smoothSingleSpectrum(API::MatrixWorkspace_sptr inputWS, // cut-off index double ri1 = floor((dblev / 4 - b1) / a1); if (ri1 < static_cast<double>(i0)) { - g_log.warning() << "Failed to build Wiener filter: no smoothing." << '\n'; + g_log.warning() << "Failed to build Wiener filter: no smoothing.\n"; ri1 = static_cast<double>(i0); } size_t i1 = static_cast<size_t>(ri1); @@ -340,8 +340,7 @@ WienerSmooth::smoothSingleSpectrum(API::MatrixWorkspace_sptr inputWS, g_log.debug() << "Cut-off index " << i1 << '\n'; } else { - g_log.warning() << "Power spectrum has an unexpected shape: no smoothing" - << '\n'; + g_log.warning() << "Power spectrum has an unexpected shape: no smoothing\n"; return copyInput(inputWS, wsIndex); } diff --git a/Framework/Algorithms/test/GenerateEventsFilterTest.h b/Framework/Algorithms/test/GenerateEventsFilterTest.h index 59ed093f16a..be42069004d 100644 --- a/Framework/Algorithms/test/GenerateEventsFilterTest.h +++ b/Framework/Algorithms/test/GenerateEventsFilterTest.h @@ -712,11 +712,10 @@ public: */ void test_genMultipleLogValuesFilterMatrixSplitter() { std::cout - << "\n==== Test Multiple Log Value Filter (Matrix Splitter) ====\n" - << '\n'; + << "\n==== Test Multiple Log Value Filter (Matrix Splitter) ====\n\n" - // Create input - DataObjects::EventWorkspace_sptr eventWS = createEventWorkspace(); + // Create input + DataObjects::EventWorkspace_sptr eventWS = createEventWorkspace(); AnalysisDataService::Instance().addOrReplace("TestEventWS04B", eventWS); // Init and set property diff --git a/Framework/Crystal/src/GoniometerAnglesFromPhiRotation.cpp b/Framework/Crystal/src/GoniometerAnglesFromPhiRotation.cpp index ae4b7dc6667..d5be852e913 100644 --- a/Framework/Crystal/src/GoniometerAnglesFromPhiRotation.cpp +++ b/Framework/Crystal/src/GoniometerAnglesFromPhiRotation.cpp @@ -356,13 +356,12 @@ void GoniometerAnglesFromPhiRotation::exec() { double omega2 = atan2(ax3, -ax1) / M_PI * 180; g_log.notice() - << "============================ Results ============================" - << '\n'; + << "============================ Results ============================\n"; g_log.notice() << " phi,chi, and omega= (" << phi2 << "," << chi2 << "," << omega2 << ")\n"; g_log.notice() << " #indexed =" << Nindexed << '\n'; g_log.notice() - << " ==============================================" << '\n'; + << " ==============================================\n"; // std::cout << "============================ Results // ============================\n"; diff --git a/Framework/Crystal/src/IntegratePeakTimeSlices.cpp b/Framework/Crystal/src/IntegratePeakTimeSlices.cpp index 8e36d284b13..c3e3d224b26 100644 --- a/Framework/Crystal/src/IntegratePeakTimeSlices.cpp +++ b/Framework/Crystal/src/IntegratePeakTimeSlices.cpp @@ -2301,8 +2301,8 @@ bool IntegratePeakTimeSlices::isGoodFit(std::vector<double> const ¶ms, std::string obj = " parameter "; if (!paramBad) obj = " error "; - g_log.debug() << " Bad Slice." << obj << BadParamNum << " is not a number" - << '\n'; + g_log.debug() << " Bad Slice." << obj << BadParamNum + << " is not a number\n"; } if (!GoodNums) @@ -2371,7 +2371,7 @@ bool IntegratePeakTimeSlices::isGoodFit(std::vector<double> const ¶ms, // intensity center if (params[IVXX] + params[IVYY] > 2.6 * (params[IVXX] * params[IVYY] - params[IVXY] * params[IVXY])) { - g_log.debug() << " Bad Slice. Too steep of an exponential" << '\n'; + g_log.debug() << " Bad Slice. Too steep of an exponential\n"; return false; } diff --git a/Framework/Crystal/src/LoadIsawPeaks.cpp b/Framework/Crystal/src/LoadIsawPeaks.cpp index 85549090f6d..ba26358f371 100644 --- a/Framework/Crystal/src/LoadIsawPeaks.cpp +++ b/Framework/Crystal/src/LoadIsawPeaks.cpp @@ -209,8 +209,8 @@ LoadIsawPeaks::ApplyCalibInfo(std::ifstream &in, std::string startChar, getCachedBankByName(bankName, instr_old); if (!bank) { - g_log.error() << "There is no bank " << bankName << " in the instrument" - << '\n'; + g_log.error() << "There is no bank " << bankName + << " in the instrument\n"; throw std::length_error("There is no bank " + bankName + " in the instrument"); } diff --git a/Framework/Crystal/src/PeakHKLErrors.cpp b/Framework/Crystal/src/PeakHKLErrors.cpp index 8ee64b6dc9a..7b89e3f2266 100644 --- a/Framework/Crystal/src/PeakHKLErrors.cpp +++ b/Framework/Crystal/src/PeakHKLErrors.cpp @@ -452,8 +452,7 @@ void PeakHKLErrors::functionDeriv1D(Jacobian *out, const double *xValues, getRun2MatMap(Peaks, OptRuns, RunNums2GonMatrix); g_log.debug() - << "----------------------------Derivative------------------------" - << '\n'; + << "----------------------------Derivative------------------------\n"; V3D samplePosition = instNew->getSample()->getPos(); IPeak &ppeak = Peaks->getPeak(0); diff --git a/Framework/Crystal/src/PredictPeaks.cpp b/Framework/Crystal/src/PredictPeaks.cpp index ae036d32e5e..de4759d04ff 100644 --- a/Framework/Crystal/src/PredictPeaks.cpp +++ b/Framework/Crystal/src/PredictPeaks.cpp @@ -142,8 +142,7 @@ void PredictPeaks::exec() { g_log.error() << "Error getting the goniometer rotation matrix from the " "InputWorkspace." << std::endl << e.what() << '\n'; - g_log.warning() << "Using identity goniometer rotation matrix instead." - << '\n'; + g_log.warning() << "Using identity goniometer rotation matrix instead.\n"; } } else if (peaksWS) { // Sort peaks by run number so that peaks with equal goniometer matrices are @@ -187,8 +186,8 @@ void PredictPeaks::exec() { << "Error getting the goniometer rotation matrix from the " "InputWorkspace." << std::endl << e.what() << '\n'; - g_log.warning() << "Using identity goniometer rotation matrix instead." - << '\n'; + g_log.warning() + << "Using identity goniometer rotation matrix instead.\n"; } } } diff --git a/Framework/Crystal/src/SCDCalibratePanels.cpp b/Framework/Crystal/src/SCDCalibratePanels.cpp index 6b04538089c..6af440c44eb 100644 --- a/Framework/Crystal/src/SCDCalibratePanels.cpp +++ b/Framework/Crystal/src/SCDCalibratePanels.cpp @@ -700,8 +700,8 @@ void SCDCalibratePanels::exec() { if (!GoodStart(peaksWs, a, b, c, alpha, beta, gamma, tolerance)) { g_log.warning() << "**** Indexing is NOT compatible with given lattice " "parameters******\n"; - g_log.warning() << " Index with conventional orientation matrix???" - << '\n'; + g_log.warning() + << " Index with conventional orientation matrix???\n"; } //----------- Initialize peaksWorkspace, initial parameter values diff --git a/Framework/Crystal/src/SaveIsawPeaks.cpp b/Framework/Crystal/src/SaveIsawPeaks.cpp index d8bdeaf9abb..bf279b46d98 100644 --- a/Framework/Crystal/src/SaveIsawPeaks.cpp +++ b/Framework/Crystal/src/SaveIsawPeaks.cpp @@ -268,7 +268,7 @@ void SaveIsawPeaks::exec() { if (!ids.empty()) { // Write the bank header - out << "0 NRUN DETNUM CHI PHI OMEGA MONCNT" << '\n'; + out << "0 NRUN DETNUM CHI PHI OMEGA MONCNT\n"; out << "1 " << std::setw(5) << run << std::setw(7) << std::right << bank; diff --git a/Framework/Crystal/src/SaveIsawUB.cpp b/Framework/Crystal/src/SaveIsawUB.cpp index 88cab31fa25..57f75fe5fd9 100644 --- a/Framework/Crystal/src/SaveIsawUB.cpp +++ b/Framework/Crystal/src/SaveIsawUB.cpp @@ -143,8 +143,7 @@ void SaveIsawUB::exec() { << lattice.errorgamma() << setw(12) << setprecision(4) << ErrorVolume << " \n"; - out << endl - << '\n'; + out << "\n\n"; out << "The above matrix is the Transpose of the UB Matrix. "; out << "The UB matrix maps the column\n"; diff --git a/Framework/CurveFitting/src/Algorithms/FitPowderDiffPeaks.cpp b/Framework/CurveFitting/src/Algorithms/FitPowderDiffPeaks.cpp index 728d6617094..86442b1109e 100644 --- a/Framework/CurveFitting/src/Algorithms/FitPowderDiffPeaks.cpp +++ b/Framework/CurveFitting/src/Algorithms/FitPowderDiffPeaks.cpp @@ -246,10 +246,9 @@ void FitPowderDiffPeaks::exec() { g_log.information() << "Fit (Single) Peaks In Robust Mode.\n"; fitPeaksRobust(); } else if (m_fitMode == TRUSTINPUTFIT) { - g_log.information() - << "Fit Peaks In Trust Mode. Possible to fit overlapped peaks." - << '\n'; - fitPeaksWithGoodStartingValues(); + g_log.information() << "Fit Peaks In Trust Mode. Possible to fit " + "overlapped " + "peaks.\n" fitPeaksWithGoodStartingValues(); } else { g_log.error("Unsupported fit mode!"); throw runtime_error("Unsupported fit mode."); @@ -577,8 +576,7 @@ void FitPowderDiffPeaks::observePeakRange(BackToBackExponential_sptr thispeak, peakrightbound = rightpeakleftbound; if (peakrightbound < 2.0 * rightfwhm + peakcentre) g_log.warning() << "Peak @ " << peakcentre - << "'s right boundary is too close to its right peak!" - << '\n'; + << "'s right boundary is too close to its right peak!\n"; } return; @@ -664,8 +662,8 @@ bool FitPowderDiffPeaks::fitSinglePeakRobust( } else if (height < m_minPeakHeight) { g_log.notice() << "[FLAGx409] Peak proposed @ TOF = " << peak->centre() << " has a trivial " - << "peak height = " << height << " by observation. Skipped." - << '\n'; + << "peak height = " << height + << " by observation. Skipped.\n"; return false; } else { g_log.information() << "[DBx201] Peak Predicted @ TOF = " << peak->centre() diff --git a/Framework/CurveFitting/src/Algorithms/RefinePowderInstrumentParameters.cpp b/Framework/CurveFitting/src/Algorithms/RefinePowderInstrumentParameters.cpp index fc0b1400ecf..9f17c39142f 100644 --- a/Framework/CurveFitting/src/Algorithms/RefinePowderInstrumentParameters.cpp +++ b/Framework/CurveFitting/src/Algorithms/RefinePowderInstrumentParameters.cpp @@ -225,8 +225,7 @@ void RefinePowderInstrumentParameters::exec() { /** Fit instrument parameters. It is a straight forward fitting to */ void RefinePowderInstrumentParameters::fitInstrumentParameters() { - cout << "=========== Method [FitInstrumentParameters] ===============" - << '\n'; + cout << "=========== Method [FitInstrumentParameters] ===============\n"; // 1. Initialize the fitting function ThermalNeutronDtoTOFFunction rawfunc; @@ -313,7 +312,7 @@ void RefinePowderInstrumentParameters::fitInstrumentParameters() { bool successfulfit = fitalg->execute(); if (!fitalg->isExecuted() || !successfulfit) { // Early return due to bad fit - g_log.error() << "Fitting to instrument geometry function failed. " << '\n'; + g_log.error() << "Fitting to instrument geometry function failed. \n"; throw std::runtime_error("Fitting failed."); } @@ -400,7 +399,7 @@ bool RefinePowderInstrumentParameters::fitFunction(IFunction_sptr func, bool successfulfit = fitalg->execute(); if (!fitalg->isExecuted() || !successfulfit) { // Early return due to bad fit - g_log.error() << "Fitting to instrument geometry function failed. " << '\n'; + g_log.error() << "Fitting to instrument geometry function failed. \n"; throw std::runtime_error("Fitting failed."); } @@ -441,7 +440,7 @@ double RefinePowderInstrumentParameters::calculateFunctionStatistic( bool successfulfit = fitalg->execute(); if (!fitalg->isExecuted() || !successfulfit) { // Early return due to bad fit - g_log.error() << "Fitting to instrument geometry function failed. " << '\n'; + g_log.error() << "Fitting to instrument geometry function failed. \n"; throw std::runtime_error("Fitting failed."); } @@ -861,8 +860,7 @@ void RefinePowderInstrumentParameters::genPeaksFromTable( DataObjects::TableWorkspace_sptr peakparamws) { // 1. Check and clear input and output if (!peakparamws) { - g_log.error() << "Input tableworkspace for peak parameters is invalid!" - << '\n'; + g_log.error() << "Input tableworkspace for peak parameters is invalid!\n"; throw std::invalid_argument( "Invalid input table workspace for peak parameters"); } @@ -985,8 +983,7 @@ void RefinePowderInstrumentParameters::importParametersFromTable( } catch (runtime_error &) { g_log.error() << "Import table workspace " << parameterWS->name() << " error in line " << ir << ". " - << " Requires [string, double] in the first 2 columns." - << '\n'; + << " Requires [string, double] in the first 2 columns.\n"; throw; } } @@ -1076,8 +1073,7 @@ void RefinePowderInstrumentParameters::importMonteCarloParametersFromTable( stringstream errss; errss << "Input instrument parameter workspace does not have parameter " << parname - << ". Information is incomplete for Monte Carlo simulation." - << '\n'; + << ". Information is incomplete for Monte Carlo simulation.\n"; g_log.error(errss.str()); throw runtime_error(errss.str()); } diff --git a/Framework/CurveFitting/src/FuncMinimizers/DampingMinimizer.cpp b/Framework/CurveFitting/src/FuncMinimizers/DampingMinimizer.cpp index 2374ab650f8..6120555a14a 100644 --- a/Framework/CurveFitting/src/FuncMinimizers/DampingMinimizer.cpp +++ b/Framework/CurveFitting/src/FuncMinimizers/DampingMinimizer.cpp @@ -90,8 +90,7 @@ bool DampingMinimizer::iterate(size_t) { for (size_t j = 0; j < n; ++j) { std::cerr << dx.get(j) << ' '; } - std::cerr << std::endl - << '\n'; + std::cerr << "\n\n"; } // Update the parameters of the cost function. diff --git a/Framework/CurveFitting/src/FuncMinimizers/FABADAMinimizer.cpp b/Framework/CurveFitting/src/FuncMinimizers/FABADAMinimizer.cpp index 5eefebe4472..5aa4c7c0ffa 100644 --- a/Framework/CurveFitting/src/FuncMinimizers/FABADAMinimizer.cpp +++ b/Framework/CurveFitting/src/FuncMinimizers/FABADAMinimizer.cpp @@ -308,8 +308,7 @@ bool FABADAMinimizer::iterate(size_t) { API::IFunction_sptr fun = m_leastSquares->getFittingFunction(); g_log.warning() << "Wrong convergence for parameter " + fun->parameterName(i) + - ". Try to set a proper initial value for this parameter" - << '\n'; + ". Try to set a proper initial value for this parameter\n"; } } diff --git a/Framework/CurveFitting/src/FuncMinimizers/LevenbergMarquardtMDMinimizer.cpp b/Framework/CurveFitting/src/FuncMinimizers/LevenbergMarquardtMDMinimizer.cpp index 737bc2fdcc9..9bf4cb3bebd 100644 --- a/Framework/CurveFitting/src/FuncMinimizers/LevenbergMarquardtMDMinimizer.cpp +++ b/Framework/CurveFitting/src/FuncMinimizers/LevenbergMarquardtMDMinimizer.cpp @@ -92,8 +92,7 @@ bool LevenbergMarquardtMDMinimizer::iterate(size_t) { if (debug) { g_log.warning() - << "===========================================================" - << '\n'; + << "===========================================================\n"; g_log.warning() << "mu=" << m_mu << std::endl << '\n'; } @@ -165,8 +164,7 @@ bool LevenbergMarquardtMDMinimizer::iterate(size_t) { for (size_t j = 0; j < n; ++j) { g_log.warning() << dx.get(j) << ' '; } - g_log.warning() << std::endl - << '\n'; + g_log.warning() << "\n\n"; } // restore scaling @@ -225,8 +223,7 @@ bool LevenbergMarquardtMDMinimizer::iterate(size_t) { g_log.warning() << m_errorString << '\n'; } if (debug) { - g_log.warning() << "Successful fit, cost function didn't change." - << '\n'; + g_log.warning() << "Successful fit, cost function didn't change.\n"; } return false; } @@ -273,8 +270,7 @@ bool LevenbergMarquardtMDMinimizer::iterate(size_t) { m_F = m_leastSquares->val(); if (debug) { g_log.warning() - << "Bad iteration, increase mu and revert changes to parameters." - << '\n'; + << "Bad iteration, increase mu and revert changes to parameters.\n"; } } diff --git a/Framework/CurveFitting/src/Functions/CubicSpline.cpp b/Framework/CurveFitting/src/Functions/CubicSpline.cpp index b7db479a86c..aa4a14f08d0 100644 --- a/Framework/CurveFitting/src/Functions/CubicSpline.cpp +++ b/Framework/CurveFitting/src/Functions/CubicSpline.cpp @@ -165,8 +165,7 @@ void CubicSpline::calculateSpline(double *out, const double *xValues, // warn user than some values wern't calculated if (outOfRange) { g_log.warning() - << "Some x values where out of range and will not be calculated." - << '\n'; + << "Some x values where out of range and will not be calculated.\n"; } } @@ -234,8 +233,7 @@ void CubicSpline::calculateDerivative(double *out, const double *xValues, // warn user that some values weren't calculated if (outOfRange) { g_log.warning() - << "Some x values where out of range and will not be calculated." - << '\n'; + << "Some x values where out of range and will not be calculated.\n"; } } diff --git a/Framework/CurveFitting/src/Functions/ProcessBackground.cpp b/Framework/CurveFitting/src/Functions/ProcessBackground.cpp index c053c47012f..c7c003dea13 100644 --- a/Framework/CurveFitting/src/Functions/ProcessBackground.cpp +++ b/Framework/CurveFitting/src/Functions/ProcessBackground.cpp @@ -431,8 +431,7 @@ void ProcessBackground::addRegion() { for (size_t i = 1; i < vx.size(); ++i) { if (vx[i] <= vx[i - 1]) { g_log.error() - << "The vector X with value inserted is not ordered incrementally" - << '\n'; + << "The vector X with value inserted is not ordered incrementally\n"; throw std::runtime_error("Build new vector error!"); } } diff --git a/Framework/CurveFitting/src/ParameterEstimator.cpp b/Framework/CurveFitting/src/ParameterEstimator.cpp index a8cf8a9f223..a395a5de317 100644 --- a/Framework/CurveFitting/src/ParameterEstimator.cpp +++ b/Framework/CurveFitting/src/ParameterEstimator.cpp @@ -261,7 +261,7 @@ void setBackToBackExponential(API::IFunction &function, sigma = 1e-06; function.setParameter("S", sigma); - g_log.debug() << "Estimating parameters of BackToBackExponential" << '\n'; + g_log.debug() << "Estimating parameters of BackToBackExponential\n"; g_log.debug() << "centre= " << centre << '\n'; g_log.debug() << "sigma = " << sigma << '\n'; diff --git a/Framework/CurveFitting/test/Algorithms/FitPowderDiffPeaksTest.h b/Framework/CurveFitting/test/Algorithms/FitPowderDiffPeaksTest.h index 286f8a68a95..2ec48f39c0c 100644 --- a/Framework/CurveFitting/test/Algorithms/FitPowderDiffPeaksTest.h +++ b/Framework/CurveFitting/test/Algorithms/FitPowderDiffPeaksTest.h @@ -404,8 +404,7 @@ public: default: stringstream errss; errss << "Option " << option - << " is not supported by createInstrumentParameterWorkspace." - << '\n'; + << " is not supported by createInstrumentParameterWorkspace.\n"; errss << "Supported options are 1 (PG3 bank1). "; throw invalid_argument(errss.str()); break; diff --git a/Framework/CurveFitting/test/Algorithms/RefinePowderInstrumentParameters3Test.h b/Framework/CurveFitting/test/Algorithms/RefinePowderInstrumentParameters3Test.h index 107fb6d75bd..c3c2e319bda 100644 --- a/Framework/CurveFitting/test/Algorithms/RefinePowderInstrumentParameters3Test.h +++ b/Framework/CurveFitting/test/Algorithms/RefinePowderInstrumentParameters3Test.h @@ -176,8 +176,8 @@ public: for (mapiter = fitparamvalues.begin(); mapiter != fitparamvalues.end(); ++mapiter) { - cout << "[P] " << mapiter->first << "\t = \t" << mapiter->second << "\t" - << '\n'; + cout << "[P] " << mapiter->first << "\t = \t" << mapiter->second + << "\t\n"; } } @@ -460,11 +460,10 @@ public: ins.open(filename.c_str()); if (!ins.is_open()) { - std::cout << "Data file " << filename << " cannot be opened. " << '\n'; + std::cout << "Data file " << filename << " cannot be opened. \n"; throw std::invalid_argument("Unable to open data fiile. "); } else { - std::cout << "Data file " << filename << " is opened for parsing. " - << '\n'; + std::cout << "Data file " << filename << " is opened for parsing. \n"; } char line[256]; diff --git a/Framework/DataHandling/src/AppendGeometryToSNSNexus.cpp b/Framework/DataHandling/src/AppendGeometryToSNSNexus.cpp index 72865173d58..1f6cb2f57ed 100644 --- a/Framework/DataHandling/src/AppendGeometryToSNSNexus.cpp +++ b/Framework/DataHandling/src/AppendGeometryToSNSNexus.cpp @@ -79,8 +79,7 @@ void AppendGeometryToSNSNexus::exec() { g_log.warning() << "This is intended as a proof of principle and not a long " "term implementation.\n"; g_log.warning() - << "(the created arrays in the NeXus file will have the '_new' suffix)" - << '\n'; + << "(the created arrays in the NeXus file will have the '_new' suffix)\n"; // Retrieve filename from the properties m_filename = getPropertyValue("Filename"); @@ -269,8 +268,8 @@ void AppendGeometryToSNSNexus::exec() { } // Look for monitors else if (entry_iter->second == "NXmonitor") { - g_log.debug() << "Monitor called '" << entry_iter->first << "' found." - << '\n'; + g_log.debug() << "Monitor called '" << entry_iter->first + << "' found.\n"; nxfile.openGroup(entry_iter->first, "NXmonitor"); Geometry::IComponent_const_sptr monitor = @@ -298,8 +297,8 @@ void AppendGeometryToSNSNexus::exec() { } } else { - g_log.error() << "There are no NXentry nodes in the specified NeXus file." - << '\n'; + g_log.error() + << "There are no NXentry nodes in the specified NeXus file.\n"; } } } @@ -399,8 +398,7 @@ bool AppendGeometryToSNSNexus::runLoadNexusLogs( // Execute the Child Algorithm, catching errors without stopping. bool executionSuccessful(true); try { - alg->getLogger().information() << "Loading logs from the NeXus file..." - << '\n'; + alg->getLogger().information() << "Loading logs from the NeXus file...\n"; loadLogs->setPropertyValue("Filename", nexusFileName); loadLogs->setProperty<MatrixWorkspace_sptr>("Workspace", localWorkspace); loadLogs->executeAsChildAlg(); diff --git a/Framework/DataHandling/src/DetermineChunking.cpp b/Framework/DataHandling/src/DetermineChunking.cpp index c45394a2735..936eeee845d 100644 --- a/Framework/DataHandling/src/DetermineChunking.cpp +++ b/Framework/DataHandling/src/DetermineChunking.cpp @@ -195,9 +195,8 @@ void DetermineChunking::exec() { file.closeData(); file.closeGroup(); } catch (::NeXus::Exception &) { - g_log.error() - << "Unable to find total counts to determine chunking strategy." - << '\n'; + g_log.error() << "Unable to find total counts to determine " + "chunking strategy.\n"; } } } @@ -222,8 +221,7 @@ void DetermineChunking::exec() { // Read in the number of spectra in the RAW file m_numberOfSpectra = iraw.t_nsp1; - g_log.notice() << "Spectra size is " << m_numberOfSpectra << " spectra" - << '\n'; + g_log.notice() << "Spectra size is " << m_numberOfSpectra << " spectra\n"; fclose(file); } // Histo Nexus @@ -239,8 +237,7 @@ void DetermineChunking::exec() { std::vector<std::string> bankNames; lp.countPixels(filename, entry_name, bankNames); m_numberOfSpectra = static_cast<int>(lp.m_numPixels); - g_log.notice() << "Spectra size is " << m_numberOfSpectra << " spectra" - << '\n'; + g_log.notice() << "Spectra size is " << m_numberOfSpectra << " spectra\n"; } else { throw(std::invalid_argument("unsupported file type")); } @@ -313,9 +310,8 @@ std::string DetermineChunking::setTopEntryName(std::string filename) { } } } catch (const std::exception &) { - g_log.error() - << "Unable to determine name of top level NXentry - assuming \"entry\"." - << '\n'; + g_log.error() << "Unable to determine name of top level NXentry - assuming " + "\"entry\".\n"; top_entry_name = "entry"; } return top_entry_name; diff --git a/Framework/DataHandling/src/ImggAggregateWavelengths.cpp b/Framework/DataHandling/src/ImggAggregateWavelengths.cpp index 6566458c640..28d2f6676e4 100644 --- a/Framework/DataHandling/src/ImggAggregateWavelengths.cpp +++ b/Framework/DataHandling/src/ImggAggregateWavelengths.cpp @@ -291,7 +291,7 @@ void ImggAggregateWavelengths::exec() { aggToFBands(inputPath, outputPath, tofRanges); g_log.notice() << "Saved output aggregated images into: " << outputPath - << ". They are now ready for further processing. " << '\n'; + << ". They are now ready for further processing. \n"; } void ImggAggregateWavelengths::aggUniformBands(const std::string &inputPath, @@ -330,8 +330,7 @@ void ImggAggregateWavelengths::aggIndexBands(const std::string &inputPath, if (inputSubDirs.empty()) { g_log.warning() << "Could not find any input files or directories in " << inputPath << " when looking for input bands. Nothing " - "will be produced in the output path." - << '\n'; + "will be produced in the output path.\n"; } auto outRanges = rangesFromStringProperty(rangesSpec, PROP_INDEX_RANGES); diff --git a/Framework/DataHandling/src/LoadDetectorsGroupingFile.cpp b/Framework/DataHandling/src/LoadDetectorsGroupingFile.cpp index f3ea660314c..03032545603 100644 --- a/Framework/DataHandling/src/LoadDetectorsGroupingFile.cpp +++ b/Framework/DataHandling/src/LoadDetectorsGroupingFile.cpp @@ -243,8 +243,8 @@ void LoadDetectorsGroupingFile::setByComponents() { size_t wsindex = itx->second; m_groupWS->dataY(wsindex)[0] = componentMap.first; } else { - g_log.error() << "Pixel w/ ID = " << detid << " Cannot Be Located" - << '\n'; + g_log.error() << "Pixel w/ ID = " << detid + << " Cannot Be Located\n"; } } // ENDIF Detector @@ -295,8 +295,7 @@ void LoadDetectorsGroupingFile::setByDetectors() { size_t wsindex = itx->second; m_groupWS->dataY(wsindex)[0] = detectorMap.first; } else { - g_log.error() << "Pixel w/ ID = " << detid << " Cannot Be Located" - << '\n'; + g_log.error() << "Pixel w/ ID = " << detid << " Cannot Be Located\n"; } } // ENDFOR detid (in range) } // ENDFOR each group ID @@ -323,8 +322,7 @@ void LoadDetectorsGroupingFile::setBySpectrumNos() { if (s2iter == s2imap.end()) { g_log.error() << "Spectrum " << specNo - << " does not have an entry in GroupWorkspace's spec2index map" - << '\n'; + << " does not have an entry in GroupWorkspace's spec2index map\n"; throw std::runtime_error("Logic error"); } else { size_t wsindex = s2iter->second; @@ -382,8 +380,7 @@ void LoadDetectorsGroupingFile::generateNoInstrumentGroupWorkspace() { std::sort(specids.begin(), specids.end()); if (specids.size() != spectrumidgroupmap.size()) { - g_log.warning() << "Duplicate spectrum No is defined in input XML file!" - << '\n'; + g_log.warning() << "Duplicate spectrum No is defined in input XML file!\n"; } // 2. Initialize group workspace and set the spectrum workspace map diff --git a/Framework/DataHandling/src/LoadEventNexus.cpp b/Framework/DataHandling/src/LoadEventNexus.cpp index 1d8fb32f4b8..71c8afa64f1 100644 --- a/Framework/DataHandling/src/LoadEventNexus.cpp +++ b/Framework/DataHandling/src/LoadEventNexus.cpp @@ -1274,9 +1274,8 @@ void LoadEventNexus::setTopEntryName() { } } } catch (const std::exception &) { - g_log.error() - << "Unable to determine name of top level NXentry - assuming \"entry\"." - << '\n'; + g_log.error() << "Unable to determine name of top level NXentry - assuming " + "\"entry\".\n"; m_top_entry_name = "entry"; } } @@ -1370,9 +1369,9 @@ void LoadEventNexus::exec() { const bool monitorsAsEvents = getProperty("MonitorsAsEvents"); if (monitorsAsEvents && !this->hasEventMonitors()) { - g_log.warning() << "The property MonitorsAsEvents has been enabled but " - "this file does not seem to have monitors with events." - << '\n'; + g_log.warning() + << "The property MonitorsAsEvents has been enabled but " + "this file does not seem to have monitors with events.\n"; } if (monitorsAsEvents) { // no matter whether the file has events or not, the user has requested to diff --git a/Framework/DataHandling/src/LoadFITS.cpp b/Framework/DataHandling/src/LoadFITS.cpp index 72f23f0c84b..cd2f1ce1ab2 100644 --- a/Framework/DataHandling/src/LoadFITS.cpp +++ b/Framework/DataHandling/src/LoadFITS.cpp @@ -329,7 +329,7 @@ void LoadFITS::loadHeader(const std::string &filePath, FITSInfo &header) { "offset (" + m_headerOffsetKey + " = " + header.headerKeys[m_headerOffsetKey] + - ") has a fractional part, and it will be ignored!" << '\n'; + ") has a fractional part, and it will be ignored!\n"; } header.offset = static_cast<int>(doff); } catch (std::exception &e) { diff --git a/Framework/DataHandling/src/LoadILL.cpp b/Framework/DataHandling/src/LoadILL.cpp index 96f20e37b28..358eb5cb8c5 100644 --- a/Framework/DataHandling/src/LoadILL.cpp +++ b/Framework/DataHandling/src/LoadILL.cpp @@ -192,7 +192,7 @@ int LoadILL::getEPPFromVanadium(const std::string &filenameVanadium, } if (calculatedDetectorElasticPeakPosition == -1 && filenameVanadium != "") { g_log.information() - << "Calculating the elastic peak position from the Vanadium." << '\n'; + << "Calculating the elastic peak position from the Vanadium.\n"; calculatedDetectorElasticPeakPosition = validateVanadium(filenameVanadium); } return calculatedDetectorElasticPeakPosition; @@ -512,8 +512,7 @@ void LoadILL::loadDataIntoTheWorkSpace( g_log.information() << " :: Calculated bin = [" << detectorTofBins[calculatedDetectorElasticPeakPosition] << "," - << detectorTofBins[calculatedDetectorElasticPeakPosition + 1] << "]" - << '\n'; + << detectorTofBins[calculatedDetectorElasticPeakPosition + 1] << "]\n"; // The binning for monitors is considered the same as for detectors size_t spec = 0; @@ -564,7 +563,7 @@ void LoadILL::loadDataIntoTheWorkSpace( * IN4 Low angle and high angle have been split! */ if (m_instrumentName == "IN4") { - g_log.debug() << "Loading data into the workspace: IN4 Rosace!" << '\n'; + g_log.debug() << "Loading data into the workspace: IN4 Rosace!\n"; // read in the data NXData dataGroup = entry.openNXData("instrument/Detector_Rosace/data"); NXInt data = dataGroup.openIntData(); diff --git a/Framework/DataHandling/src/LoadILLSANS.cpp b/Framework/DataHandling/src/LoadILLSANS.cpp index 10fd7cf2c0a..43f31a24662 100644 --- a/Framework/DataHandling/src/LoadILLSANS.cpp +++ b/Framework/DataHandling/src/LoadILLSANS.cpp @@ -633,8 +633,8 @@ std::pair<double, double> LoadILLSANS::calculateQMaxQMin() { << '\n'; } - g_log.debug() << "Calculating Qmin Qmax. Done : [" << min << "," << max << "]" - << '\n'; + g_log.debug() << "Calculating Qmin Qmax. Done : [" << min << "," << max + << "]\n"; return std::pair<double, double>(min, max); } diff --git a/Framework/DataHandling/src/LoadMLZ.cpp b/Framework/DataHandling/src/LoadMLZ.cpp index 400ab29b77f..04423a4ea69 100644 --- a/Framework/DataHandling/src/LoadMLZ.cpp +++ b/Framework/DataHandling/src/LoadMLZ.cpp @@ -159,8 +159,7 @@ void LoadMLZ::maskDetectors(NeXus::NXEntry &entry) { pmap.addBool(det, "masked", true); } } catch (Kernel::Exception::NotFoundError &e) { - g_log.warning() << e.what() << " Found while running MaskDetectors" - << '\n'; + g_log.warning() << e.what() << " Found while running MaskDetectors\n"; } } } diff --git a/Framework/DataHandling/src/LoadMask.cpp b/Framework/DataHandling/src/LoadMask.cpp index beba643218f..c4bef801a04 100644 --- a/Framework/DataHandling/src/LoadMask.cpp +++ b/Framework/DataHandling/src/LoadMask.cpp @@ -108,8 +108,7 @@ void LoadMask::exec() { loadISISMaskFile(filename); m_defaultToUse = true; } else { - g_log.error() << "File " << filename << " is not in supported format. " - << '\n'; + g_log.error() << "File " << filename << " is not in supported format. \n"; return; } @@ -189,8 +188,7 @@ void LoadMask::processMaskOnDetectors(bool tomask, else m_maskWS->dataY(index)[0] = 0; } else { - g_log.error() << "Pixel w/ ID = " << detid << " Cannot Be Located" - << '\n'; + g_log.error() << "Pixel w/ ID = " << detid << " Cannot Be Located\n"; } } @@ -221,8 +219,7 @@ void LoadMask::componentToDetectors(std::vector<std::string> componentnames, g_log.debug() << "Component ID = " << component->getComponentID() << '\n'; else { // A non-exiting component. Ignore - g_log.warning() << "Component " << componentname << " does not exist!" - << '\n'; + g_log.warning() << "Component " << componentname << " does not exist!\n"; continue; } @@ -344,8 +341,7 @@ void LoadMask::processMaskOnWorkspaceIndex(bool mask, // spectrum not found. bad branch g_log.error() << "Spectrum " << specNo - << " does not have an entry in GroupWorkspace's spec2index map" - << '\n'; + << " does not have an entry in GroupWorkspace's spec2index map\n"; throw std::runtime_error("Logic error"); } else { size_t wsindex = s2iter->second; @@ -669,8 +665,7 @@ void LoadMask::parseRangeText(std::string inputstr, std::vector<std::string> ptemp; this->splitString(strpair, ptemp, "-"); if (ptemp.size() != 2) { - g_log.error() << "Range string " << strpair << " has a wrong format!" - << '\n'; + g_log.error() << "Range string " << strpair << " has a wrong format!\n"; throw std::invalid_argument("Wrong format"); } @@ -678,8 +673,7 @@ void LoadMask::parseRangeText(std::string inputstr, int32_t intstart = atoi(ptemp[0].c_str()); int32_t intend = atoi(ptemp[1].c_str()); if (intstart >= intend) { - g_log.error() << "Range string " << strpair << " has a reversed order" - << '\n'; + g_log.error() << "Range string " << strpair << " has a reversed order\n"; throw std::invalid_argument("Wrong format"); } pairs.push_back(intstart); diff --git a/Framework/DataHandling/src/LoadMcStas.cpp b/Framework/DataHandling/src/LoadMcStas.cpp index 40fc76611bf..65dfab87396 100644 --- a/Framework/DataHandling/src/LoadMcStas.cpp +++ b/Framework/DataHandling/src/LoadMcStas.cpp @@ -281,8 +281,7 @@ void LoadMcStas::readEventData( int64_t nNeutrons = id_info.dims[0]; int64_t numberOfDataColumn = id_info.dims[1]; if (nNeutrons && numberOfDataColumn != 6) { - g_log.error() << "Event data in McStas nexus file expecting 6 columns" - << '\n'; + g_log.error() << "Event data in McStas nexus file expecting 6 columns\n"; return; } if (!isAnyNeutrons && nNeutrons > 0) diff --git a/Framework/DataHandling/src/LoadNexusLogs.cpp b/Framework/DataHandling/src/LoadNexusLogs.cpp index bbb5fb241b5..8ff857de96f 100644 --- a/Framework/DataHandling/src/LoadNexusLogs.cpp +++ b/Framework/DataHandling/src/LoadNexusLogs.cpp @@ -192,8 +192,7 @@ void LoadNexusLogs::exec() { if (workspace->mutableRun().hasProperty("proton_log")) { std::vector<int> event_frame_number; this->getLogger().notice() - << "Using old ISIS proton_log and event_frame_number indirection..." - << '\n'; + << "Using old ISIS proton_log and event_frame_number indirection...\n"; try { // Find the bank/name corresponding to the first event data entry, i.e. // one with type NXevent_data. @@ -215,9 +214,9 @@ void LoadNexusLogs::exec() { "/event_frame_number"); file.getData(event_frame_number); } catch (const ::NeXus::Exception &) { - this->getLogger().warning() << "Unable to load event_frame_number - " - "filtering events by time will not work " - << '\n'; + this->getLogger().warning() + << "Unable to load event_frame_number - " + "filtering events by time will not work \n"; } file.openPath("/" + entry_name); if (!event_frame_number.empty()) // ISIS indirection - see above comments diff --git a/Framework/DataHandling/src/LoadNexusMonitors2.cpp b/Framework/DataHandling/src/LoadNexusMonitors2.cpp index 8ef92e56efb..8e718f7a89e 100644 --- a/Framework/DataHandling/src/LoadNexusMonitors2.cpp +++ b/Framework/DataHandling/src/LoadNexusMonitors2.cpp @@ -179,7 +179,7 @@ void LoadNexusMonitors2::exec() { if (!m_allMonitorsHaveHistoData) { g_log.information() << "Cannot load monitors as histogram data. Loading " "as events even if the opposite was requested by " - "disabling the property MonitorsAsEvents" << '\n'; + "disabling the property MonitorsAsEvents\n"; monitorsAsEvents = true; } diff --git a/Framework/DataHandling/src/LoadNexusProcessed.cpp b/Framework/DataHandling/src/LoadNexusProcessed.cpp index b6ceeda56d8..007afe2a615 100644 --- a/Framework/DataHandling/src/LoadNexusProcessed.cpp +++ b/Framework/DataHandling/src/LoadNexusProcessed.cpp @@ -131,7 +131,7 @@ SpectraInfo extractMappingInfo(NXEntry &mtd_entry, Logger &logger) { detectorList = detlist_group.sharedBuffer(); } catch (std::runtime_error &) { logger.information() << "detector_list block not found. The workspace will " - "not contain any detector information." << '\n'; + "not contain any detector information.\n"; return SpectraInfo(); } @@ -290,10 +290,8 @@ Workspace_sptr LoadNexusProcessed::doAccelleratedMultiPeriodLoading( NXData wsEntry(mtdEntry, "workspace"); if (!wsEntry.openLocal()) { std::stringstream buffer; - buffer - << "Group entry " << p - 1 - << " is not a workspace 2D. Retry with FastMultiPeriod option set off." - << '\n'; + buffer << "Group entry " << p - 1 << " is not a workspace 2D. Retry with " + "FastMultiPeriod option set off.\n"; throw std::runtime_error(buffer.str()); } diff --git a/Framework/DataHandling/src/LoadPreNexusMonitors.cpp b/Framework/DataHandling/src/LoadPreNexusMonitors.cpp index d36e38e56db..890411be642 100644 --- a/Framework/DataHandling/src/LoadPreNexusMonitors.cpp +++ b/Framework/DataHandling/src/LoadPreNexusMonitors.cpp @@ -161,7 +161,7 @@ void LoadPreNexusMonitors::exec() { pNode = it.nextNode(); } - g_log.information() << "Found " << nMonitors << " beam monitors." << '\n'; + g_log.information() << "Found " << nMonitors << " beam monitors.\n"; g_log.information() << "Number of Time Channels = " << tchannels << '\n'; diff --git a/Framework/DataHandling/src/LoadRaw3.cpp b/Framework/DataHandling/src/LoadRaw3.cpp index fb11fdd8c3d..3bbc3acd7a8 100644 --- a/Framework/DataHandling/src/LoadRaw3.cpp +++ b/Framework/DataHandling/src/LoadRaw3.cpp @@ -224,14 +224,12 @@ void LoadRaw3::exec() { m_lengthIn, m_lengthIn - 1); } catch (std::out_of_range &) { g_log.information() << "Separate Monitors option is selected and no " - "monitors in the selected specra range." - << '\n'; + "monitors in the selected specra range.\n"; g_log.information() << "Error in creating one of the output workspaces\n"; } catch (std::runtime_error &) { g_log.information() << "Separate Monitors option is selected,Error " - "in creating one of the output workspaces" - << '\n'; + "in creating one of the output workspaces\n"; } } // end of separate Monitors diff --git a/Framework/DataHandling/src/LoadRawHelper.cpp b/Framework/DataHandling/src/LoadRawHelper.cpp index 0165d558264..414c8471d47 100644 --- a/Framework/DataHandling/src/LoadRawHelper.cpp +++ b/Framework/DataHandling/src/LoadRawHelper.cpp @@ -282,9 +282,9 @@ void LoadRawHelper::createMonitorWorkspace( } } catch (std::out_of_range &) { - pAlg->getLogger().debug() << "Error in creating monitor workspace" << '\n'; + pAlg->getLogger().debug() << "Error in creating monitor workspace\n"; } catch (std::runtime_error &) { - pAlg->getLogger().debug() << "Error in creating monitor workspace" << '\n'; + pAlg->getLogger().debug() << "Error in creating monitor workspace\n"; } } @@ -438,8 +438,7 @@ LoadRawHelper::getmonitorSpectrumList(const SpectrumDetectorMapping &mapping) { } } else { g_log.error() - << "monitor detector id list is empty for the selected workspace" - << '\n'; + << "monitor detector id list is empty for the selected workspace\n"; } return spectrumIndices; diff --git a/Framework/DataHandling/src/MaskDetectors.cpp b/Framework/DataHandling/src/MaskDetectors.cpp index 3a10ee8e8f0..ec4aec353aa 100644 --- a/Framework/DataHandling/src/MaskDetectors.cpp +++ b/Framework/DataHandling/src/MaskDetectors.cpp @@ -134,8 +134,8 @@ void MaskDetectors::exec() { g_log.error() << "Input workspace has " << WS->getNumberHistograms() << " histograms vs. " << "Input masking workspace has " - << prevMasking->getNumberHistograms() << " histograms. " - << '\n'; + << prevMasking->getNumberHistograms() + << " histograms. \n"; throw std::runtime_error("Size mismatch between two input workspaces."); } appendToIndexListFromWS(indexList, prevMasking); @@ -158,8 +158,7 @@ void MaskDetectors::exec() { pmap.addBool(det, "masked", true); } } catch (Kernel::Exception::NotFoundError &e) { - g_log.warning() << e.what() << " Found while running MaskDetectors" - << '\n'; + g_log.warning() << e.what() << " Found while running MaskDetectors\n"; } } } @@ -253,8 +252,7 @@ void MaskDetectors::execPeaks(PeaksWorkspace_sptr WS) { detectorList.push_back(detID); } } catch (Kernel::Exception::NotFoundError &e) { - g_log.warning() << e.what() << " Found while running MaskDetectors" - << '\n'; + g_log.warning() << e.what() << " Found while running MaskDetectors\n"; } } } @@ -272,8 +270,7 @@ void MaskDetectors::execPeaks(PeaksWorkspace_sptr WS) { pmap.addBool(det, "masked", true); } } catch (Kernel::Exception::NotFoundError &e) { - g_log.warning() << e.what() << " Found while running MaskDetectors" - << '\n'; + g_log.warning() << e.what() << " Found while running MaskDetectors\n"; } } } @@ -353,7 +350,7 @@ void MaskDetectors::appendToIndexListFromMaskWS( if (maskedWorkspace->dataY(i - startIndex)[0] > 0.5 && existingIndices.count(i) == 0) { - g_log.debug() << "Adding WorkspaceIndex " << i << " to mask." << '\n'; + g_log.debug() << "Adding WorkspaceIndex " << i << " to mask.\n"; indexList.push_back(i); } } diff --git a/Framework/DataHandling/src/MergeLogs.cpp b/Framework/DataHandling/src/MergeLogs.cpp index f32d5c5fb72..8029046c0cd 100644 --- a/Framework/DataHandling/src/MergeLogs.cpp +++ b/Framework/DataHandling/src/MergeLogs.cpp @@ -56,8 +56,8 @@ void Merge2WorkspaceLogs::exec() { } if (resetlogvalue && fabs(logvalue1 - logvalue2) < 1.0E-9) { - g_log.warning() << "User re-defined log values of two logs are very close!" - << '\n'; + g_log.warning() + << "User re-defined log values of two logs are very close!\n"; } // 3. Merge log @@ -162,9 +162,8 @@ void Merge2WorkspaceLogs::mergeLogs(std::string ilogname1, // 3. Check and add new log int newlogsize = rp->size(); if (size_t(newlogsize) != (times1.size() + times2.size())) { - g_log.error() - << "Resulted log size is not equal to the sum of two source log sizes" - << '\n'; + g_log.error() << "Resulted log size is not equal to the sum of two source " + "log sizes\n"; throw; } diff --git a/Framework/DataHandling/src/NexusTester.cpp b/Framework/DataHandling/src/NexusTester.cpp index 3d97fa15010..acc103b9ced 100644 --- a/Framework/DataHandling/src/NexusTester.cpp +++ b/Framework/DataHandling/src/NexusTester.cpp @@ -143,8 +143,7 @@ void NexusTester::exec() { file.close(); double seconds = tim.elapsedWallClock(false); double MBperSec = dataSizeMB / seconds; - g_log.notice() << tim << " to save the file = " << MBperSec << " MB/sec" - << '\n'; + g_log.notice() << tim << " to save the file = " << MBperSec << " MB/sec\n"; this->setProperty("SaveSpeed", MBperSec); } diff --git a/Framework/DataHandling/src/ProcessDasNexusLog.cpp b/Framework/DataHandling/src/ProcessDasNexusLog.cpp index 715035bb821..59e53eba975 100644 --- a/Framework/DataHandling/src/ProcessDasNexusLog.cpp +++ b/Framework/DataHandling/src/ProcessDasNexusLog.cpp @@ -77,7 +77,7 @@ void ProcessDasNexusLog::exec() { Kernel::TimeSeriesProperty<double> *tslog = dynamic_cast<Kernel::TimeSeriesProperty<double> *>(log); if (!tslog) { - g_log.error() << "Log " << inlogname << " is not time series log" << '\n'; + g_log.error() << "Log " << inlogname << " is not time series log\n"; throw std::invalid_argument("Log type error!"); } @@ -332,7 +332,7 @@ void ProcessDasNexusLog::checkLog(API::MatrixWorkspace_sptr ws, Kernel::TimeSeriesProperty<double> *tslog = dynamic_cast<Kernel::TimeSeriesProperty<double> *>(log); if (!tslog) { - g_log.error() << "Log " << logname << " is not time series log" << '\n'; + g_log.error() << "Log " << logname << " is not time series log\n"; throw std::invalid_argument("Log type error!"); } @@ -453,8 +453,7 @@ void ProcessDasNexusLog::writeLogtoFile(API::MatrixWorkspace_sptr ws, // 2. Write out std::ofstream ofs; ofs.open(outputfilename.c_str(), std::ios::out); - ofs << "# Absolute Time (nanosecond)\tPulse Time (nanosecond)\tTOF (ms)" - << '\n'; + ofs << "# Absolute Time (nanosecond)\tPulse Time (nanosecond)\tTOF (ms)\n"; Kernel::DateAndTime prevtime(0); std::vector<double> tofs; diff --git a/Framework/DataHandling/src/SaveDetectorsGrouping.cpp b/Framework/DataHandling/src/SaveDetectorsGrouping.cpp index 73c935de0c1..3a437a70d23 100644 --- a/Framework/DataHandling/src/SaveDetectorsGrouping.cpp +++ b/Framework/DataHandling/src/SaveDetectorsGrouping.cpp @@ -112,8 +112,7 @@ void SaveDetectorsGrouping::createGroupDetectorIDMap( auto detids = mspec->getDetectorIDs(); if (detids.size() != 1) { g_log.error() << "Spectrum " << mspec->getSpectrumNo() << " has " - << detids.size() << " detectors. Not allowed situation!" - << '\n'; + << detids.size() << " detectors. Not allowed situation!\n"; throw; } it->second.insert(it->second.end(), detids.begin(), detids.end()); diff --git a/Framework/DataHandling/src/SaveFocusedXYE.cpp b/Framework/DataHandling/src/SaveFocusedXYE.cpp index 2f7ec4e7f6f..e38935cae7b 100644 --- a/Framework/DataHandling/src/SaveFocusedXYE.cpp +++ b/Framework/DataHandling/src/SaveFocusedXYE.cpp @@ -89,7 +89,7 @@ void SaveFocusedXYE::exec() { int startingbank = getProperty("StartAtBankNumber"); if (startingbank < 0) { - g_log.error() << "Starting bank number cannot be less than 0. " << '\n'; + g_log.error() << "Starting bank number cannot be less than 0. \n"; throw std::invalid_argument("Incorrect starting bank number"); } bool split = getProperty("SplitFiles"); @@ -286,8 +286,7 @@ void SaveFocusedXYE::writeXYESpectraHeader(std::ostream &os, size_t index1, UNUSED_ARG(flightPath); UNUSED_ARG(tth); os << m_comment << " Data for spectra :" << index1 << '\n'; - os << m_comment << " " << caption << " Y E" - << '\n'; + os << m_comment << " " << caption << " Y E\n"; } /// Write spectra MAUD header diff --git a/Framework/DataHandling/src/SaveIsawDetCal.cpp b/Framework/DataHandling/src/SaveIsawDetCal.cpp index 022d9977181..ab51b2b2273 100644 --- a/Framework/DataHandling/src/SaveIsawDetCal.cpp +++ b/Framework/DataHandling/src/SaveIsawDetCal.cpp @@ -136,9 +136,9 @@ void SaveIsawDetCal::exec() { out.open(filename.c_str(), std::ios::app); } else { out.open(filename.c_str()); - out << "# NEW CALIBRATION FILE FORMAT (in NeXus/SNS coordinates):" << '\n'; + out << "# NEW CALIBRATION FILE FORMAT (in NeXus/SNS coordinates):\n"; out << "# Lengths are in centimeters.\n"; - out << "# Base and up give directions of unit vectors for a local " << '\n'; + out << "# Base and up give directions of unit vectors for a local \n"; out << "# x,y coordinate system on the face of the detector.\n"; out << "#\n"; out << "#\n"; diff --git a/Framework/DataHandling/src/SaveMask.cpp b/Framework/DataHandling/src/SaveMask.cpp index 928843496a1..b57e737d23e 100644 --- a/Framework/DataHandling/src/SaveMask.cpp +++ b/Framework/DataHandling/src/SaveMask.cpp @@ -146,8 +146,7 @@ void SaveMask::exec() { for (size_t i = 0; i < idx0sts.size(); i++) { g_log.information() << "Section " << i << " : " << idx0sts[i] << " , " - << idx0eds[i] << " to be masked and recorded." - << '\n'; + << idx0eds[i] << " to be masked and recorded.\n"; } } // Only work for detid > 0 diff --git a/Framework/DataHandling/src/SaveSavuTomoConfig.cpp b/Framework/DataHandling/src/SaveSavuTomoConfig.cpp index aaf950b8a65..798792a925e 100644 --- a/Framework/DataHandling/src/SaveSavuTomoConfig.cpp +++ b/Framework/DataHandling/src/SaveSavuTomoConfig.cpp @@ -142,7 +142,7 @@ void SaveSavuTomoConfig::saveFile( // If file exists, delete it. Poco::File f(fileName); if (f.exists()) { - g_log.notice() << "Overwriting existing file: '" << fileName << "'" << '\n'; + g_log.notice() << "Overwriting existing file: '" << fileName << "'\n"; f.remove(); } else { g_log.notice() << "Creating file: '" << fileName << ";\n"; diff --git a/Framework/DataHandling/test/LoadDetectorsGroupingFileTest.h b/Framework/DataHandling/test/LoadDetectorsGroupingFileTest.h index 1e4bdeaccb9..71166358b8b 100644 --- a/Framework/DataHandling/test/LoadDetectorsGroupingFileTest.h +++ b/Framework/DataHandling/test/LoadDetectorsGroupingFileTest.h @@ -316,7 +316,7 @@ public: << "# Group 3\n" << "333\n" << "2\n" - << " 6 -7\n" << '\n'; + << " 6 -7\n\n"; ScopedFile file(ss.str(), "test_mapfile_ranges.map"); diff --git a/Framework/DataHandling/test/LoadMaskTest.h b/Framework/DataHandling/test/LoadMaskTest.h index cd28ecdd613..d39e98b12f1 100644 --- a/Framework/DataHandling/test/LoadMaskTest.h +++ b/Framework/DataHandling/test/LoadMaskTest.h @@ -152,8 +152,8 @@ public: TS_ASSERT_DELTA(y, 0.0, 1.0E-5); if (fabs(y) > 1.0E-5) { errorcounts++; - std::cout << "Workspace Index " << iws << " has a wrong set on masks" - << '\n'; + std::cout << "Workspace Index " << iws + << " has a wrong set on masks\n"; } } } diff --git a/Framework/DataHandling/test/LoadTBLTest.h b/Framework/DataHandling/test/LoadTBLTest.h index eb1f2db28d9..910ba943035 100644 --- a/Framework/DataHandling/test/LoadTBLTest.h +++ b/Framework/DataHandling/test/LoadTBLTest.h @@ -28,12 +28,10 @@ public: // create a file with each line containing different but valid data format std::ofstream file(m_filename.c_str()); file << "13460,0.7,13463,0.01,0.06,,,,,,,,,,,0.04,2\n"; - file << "13469,0.7,13463,0.01,0.06,13470,2.3,13463,0.035,0.3,,,,,,0.04,2" - << '\n'; + file << "13469,0.7,13463,0.01,0.06,13470,2.3,13463,0.035,0.3,,,,,,0.04,2\n"; file << "13460,0.7,13463,0.01,0.06,13462,2.3,13463,0.035,0.3,13470,2.3," "13463,0.035,0.3,0.04,2\n"; - file << "13460,0.7,13463,0.01,0.06,,,,,,13470,2.3,13463,0.035,0.3,0.04,2" - << '\n'; + file << "13460,0.7,13463,0.01,0.06,,,,,,13470,2.3,13463,0.035,0.3,0.04,2\n"; file << ",,,,,13470,2.3,13463,0.035,0.3,,,,,,0.04,2\n"; file << ",,,,,,,,,,13462,2.3,13463,0.035,0.3,0.04,2\n"; file.close(); @@ -249,17 +247,15 @@ public: void testManyColumnsTwo() { // create a file with each line containing too many columns std::ofstream file(m_filename.c_str()); - file << "13460,0.7,\"13463,0.01\",0.06,,,,,,,,,,,0.04,2,,,,0.04,2" << '\n'; + file << "13460,0.7,\"13463,0.01\",0.06,,,,,,,,,,,0.04,2,,,,0.04,2\n"; file << "13469,0.7,13463,\"0.01,0.06\",13470,2.3,13463,0.06,\"13470,0.06," "13470\",2.3,13463,0.035,0.3,,,,,,,,,0.04,2,,,,0.04,2\n"; file << "13460,0.7,13463,0.01,0.06,13462,2.3,13463,0.035,0.3,13470,2.3," "13463,0.035,0.3,0.04,2,,,,0.04,2\n"; file << "13460,0.7,\"13463,0.01\",0.06,,,,,,,,,,13470,2.3,\"13463,0.035\"," "0.3,0.04,2,,,,0.04,2\n"; - file << ",,,,,13470,2.3,\"13463,0.035\",0.3,,,,,,,,,0.04,2,,,,0.04,2" - << '\n'; - file << ",,,,,,,,,,,,13462,2.3,\"13463,0.035\",0.3,0.04,2,,,,0.04,2" - << '\n'; + file << ",,,,,13470,2.3,\"13463,0.035\",0.3,,,,,,,,,0.04,2,,,,0.04,2\n"; + file << ",,,,,,,,,,,,13462,2.3,\"13463,0.035\",0.3,0.04,2,,,,0.04,2\n"; file.close(); Mantid::API::IAlgorithm_sptr alg = @@ -277,8 +273,8 @@ public: void testTBLWithColumnHeadingsRowAndData() { std::ofstream file(m_filename.c_str()); - file << "Runs,Angle,QMin,QMax,Group,Options" << std::endl - << "14456,0.7,1.443,8.992,1," << std::endl + file << "Runs,Angle,QMin,QMax,Group,Options\n" + << "14456,0.7,1.443,8.992,1,\n" << "18553,0.3,1.233,4.388,3,\n"; file.close(); Mantid::API::IAlgorithm_sptr alg = diff --git a/Framework/DataObjects/src/MDBoxFlatTree.cpp b/Framework/DataObjects/src/MDBoxFlatTree.cpp index 300b4c712fe..6142e6cc179 100644 --- a/Framework/DataObjects/src/MDBoxFlatTree.cpp +++ b/Framework/DataObjects/src/MDBoxFlatTree.cpp @@ -430,8 +430,7 @@ void MDBoxFlatTree::loadExperimentInfos( std::string groupName = "experiment" + Kernel::Strings::toString(i); g_log.warning() << "NXS file is missing a ExperimentInfo block " << groupName - << ". Workspace will be missing ExperimentInfo." - << '\n'; + << ". Workspace will be missing ExperimentInfo.\n"; } } ic++; diff --git a/Framework/DataObjects/src/SpecialWorkspace2D.cpp b/Framework/DataObjects/src/SpecialWorkspace2D.cpp index 7fdab4f23eb..7a3dbb3e57c 100644 --- a/Framework/DataObjects/src/SpecialWorkspace2D.cpp +++ b/Framework/DataObjects/src/SpecialWorkspace2D.cpp @@ -239,7 +239,7 @@ void SpecialWorkspace2D::binaryOperation(const unsigned int operatortype) { break; default: g_log.error() << "Operator " << operatortype - << " Is Not Valid In BinaryOperation(operatortype)" << '\n'; + << " Is Not Valid In BinaryOperation(operatortype)\n"; throw std::invalid_argument("Invalid Operator"); break; } diff --git a/Framework/DataObjects/test/MDGridBoxTest.h b/Framework/DataObjects/test/MDGridBoxTest.h index 73b8ed7a44d..846cc2bb792 100644 --- a/Framework/DataObjects/test/MDGridBoxTest.h +++ b/Framework/DataObjects/test/MDGridBoxTest.h @@ -87,17 +87,13 @@ public: BoxController *const bcc = b->getBoxController(); delete b; if (DODEBUG) { - std::cout << sizeof(MDLeanEvent<3>) << " bytes per MDLeanEvent(3)" - << '\n'; - std::cout << sizeof(MDLeanEvent<4>) << " bytes per MDLeanEvent(4)" - << '\n'; + std::cout << sizeof(MDLeanEvent<3>) << " bytes per MDLeanEvent(3)\n"; + std::cout << sizeof(MDLeanEvent<4>) << " bytes per MDLeanEvent(4)\n"; std::cout << sizeof(std::mutex) << " bytes per Mutex\n"; std::cout << sizeof(MDDimensionExtents<coord_t>) << " bytes per MDDimensionExtents\n"; - std::cout << sizeof(MDBox<MDLeanEvent<3>, 3>) << " bytes per MDBox(3)" - << '\n'; - std::cout << sizeof(MDBox<MDLeanEvent<4>, 4>) << " bytes per MDBox(4)" - << '\n'; + std::cout << sizeof(MDBox<MDLeanEvent<3>, 3>) << " bytes per MDBox(3)\n"; + std::cout << sizeof(MDBox<MDLeanEvent<4>, 4>) << " bytes per MDBox(4)\n"; std::cout << sizeof(MDGridBox<MDLeanEvent<3>, 3>) << " bytes per MDGridBox(3)\n"; std::cout << sizeof(MDGridBox<MDLeanEvent<4>, 4>) diff --git a/Framework/DataObjects/test/Workspace2DTest.h b/Framework/DataObjects/test/Workspace2DTest.h index 5bc2a4a6467..059318ab614 100644 --- a/Framework/DataObjects/test/Workspace2DTest.h +++ b/Framework/DataObjects/test/Workspace2DTest.h @@ -324,7 +324,7 @@ public: spec->setDetectorID(detid_t(i)); } std::cout << tim << " to set all detector IDs for " << nhist - << " spectra, using the ISpectrum method (in parallel)." << '\n'; + << " spectra, using the ISpectrum method (in parallel).\n"; } }; diff --git a/Framework/Geometry/src/Instrument/InstrumentDefinitionParser.cpp b/Framework/Geometry/src/Instrument/InstrumentDefinitionParser.cpp index 8503252f004..c8567393c5c 100644 --- a/Framework/Geometry/src/Instrument/InstrumentDefinitionParser.cpp +++ b/Framework/Geometry/src/Instrument/InstrumentDefinitionParser.cpp @@ -2304,8 +2304,8 @@ void InstrumentDefinitionParser::setComponentLinks( if (!detector) { g_log.error() << "Error whilst loading parameters. No detector " "found with id '" << detid << "'\n"; - g_log.error() << "Please check that your detectors' ids are correct." - << '\n'; + g_log.error() + << "Please check that your detectors' ids are correct.\n"; throw Kernel::Exception::InstrumentDefinitionError( "Invalid detector id in component-link tag."); } @@ -2326,7 +2326,7 @@ void InstrumentDefinitionParser::setComponentLinks( << "'.\n"; g_log.warning() << "Parameters have been applied to detector with id '" - << detid << "'. Please check the name is correct." << '\n'; + << detid << "'. Please check the name is correct.\n"; } } } diff --git a/Framework/Geometry/src/Instrument/ParameterMap.cpp b/Framework/Geometry/src/Instrument/ParameterMap.cpp index 31bbbab230a..56f8ba08ef4 100644 --- a/Framework/Geometry/src/Instrument/ParameterMap.cpp +++ b/Framework/Geometry/src/Instrument/ParameterMap.cpp @@ -243,8 +243,8 @@ const std::string ParameterMap::diff(const ParameterMap &rhs, strOutput << "No matching RHS component name\n"; } if (componentWithSameNameRHS && !parameterWithSameNameRHS) { - strOutput << "Found matching RHS component name but not parameter name" - << '\n'; + strOutput + << "Found matching RHS component name but not parameter name\n"; } if (firstDiffOnly) return strOutput.str(); diff --git a/Framework/ICat/src/CatalogDownloadDataFiles.cpp b/Framework/ICat/src/CatalogDownloadDataFiles.cpp index 3022c108fa0..031aad86573 100644 --- a/Framework/ICat/src/CatalogDownloadDataFiles.cpp +++ b/Framework/ICat/src/CatalogDownloadDataFiles.cpp @@ -107,7 +107,7 @@ void CatalogDownloadDataFiles::exec() { } else { g_log.information() << "Unable to open file (" << *fileName - << ") from archive. Beginning to download over Internet." << '\n'; + << ") from archive. Beginning to download over Internet.\n"; progress(prog / 2, "getting the url ...."); // Obtain URL for related file to download from net. const std::string url = catalogInfoService->getDownloadURL(*fileID); diff --git a/Framework/ICat/src/ICat3/ICat3Helper.cpp b/Framework/ICat/src/ICat3/ICat3Helper.cpp index d474c07cce8..d7d686d8a24 100644 --- a/Framework/ICat/src/ICat3/ICat3Helper.cpp +++ b/Framework/ICat/src/ICat3/ICat3Helper.cpp @@ -45,8 +45,8 @@ int CICatHelper::doSearch(ICATPortBindingProxy &icat, } clock_t end = clock(); float diff = float(end - start) / CLOCKS_PER_SEC; - g_log.information() << " Time taken to do search is " << diff << " seconds " - << '\n'; + g_log.information() << " Time taken to do search is " << diff + << " seconds \n"; return ret_advsearch; } @@ -395,8 +395,7 @@ void CICatHelper::doMyDataSearch(API::ITableWorkspace_sptr &ws_sptr) { } if (response.return_.empty()) { g_log.information() - << "ICat Mydata search is complete.There are no results to display" - << '\n'; + << "ICat Mydata search is complete.There are no results to display\n"; return; } // save response to a table workspace diff --git a/Framework/ICat/test/CatalogDownloadDataFilesTest.h b/Framework/ICat/test/CatalogDownloadDataFilesTest.h index 9a07cd2c90f..958ea66403a 100644 --- a/Framework/ICat/test/CatalogDownloadDataFilesTest.h +++ b/Framework/ICat/test/CatalogDownloadDataFilesTest.h @@ -40,7 +40,7 @@ public: status = WEXITSTATUS(status); if (status != 0) { - std::cout << "Skipping test since '" << cmdstring << "' FAILED!" << '\n'; + std::cout << "Skipping test since '" << cmdstring << "' FAILED!\n"; return true; } return false; @@ -93,7 +93,7 @@ public: "download_time.txt"); } ofs << "Time taken to download files with investigation id 12576918 is " - << std::fixed << std::setprecision(2) << diff << " seconds" << '\n'; + << std::fixed << std::setprecision(2) << diff << " seconds\n"; ICatTestHelper::logout(); @@ -151,7 +151,7 @@ public: "download_time.txt"); } ofs << "Time taken to download files with investigation id 24070400 is " - << std::fixed << std::setprecision(2) << diff << " seconds" << '\n'; + << std::fixed << std::setprecision(2) << diff << " seconds\n"; // ofs.close(); ICatTestHelper::logout(); @@ -209,7 +209,7 @@ public: "download_time.txt"); } ofs << "Time taken to download files with investigation id 24022007 is " - << std::fixed << std::setprecision(2) << diff << " seconds" << '\n'; + << std::fixed << std::setprecision(2) << diff << " seconds\n"; ICatTestHelper::logout(); diff --git a/Framework/Kernel/src/ConfigService.cpp b/Framework/Kernel/src/ConfigService.cpp index d01760f0510..e26c62059dc 100644 --- a/Framework/Kernel/src/ConfigService.cpp +++ b/Framework/Kernel/src/ConfigService.cpp @@ -414,8 +414,7 @@ void ConfigServiceImpl::configureLogging() { if (fp == nullptr) { std::cerr << "Error writing to log file path given in properties file: \"" - << m_logFilePath << "\". Will use a default path instead." - << '\n'; + << m_logFilePath << "\". Will use a default path instead.\n"; // Clear the path; this will make it use the default m_logFilePath = ""; } else @@ -423,7 +422,7 @@ void ConfigServiceImpl::configureLogging() { } catch (std::exception &) { std::cerr << "Error writing to log file path given in properties file: \"" - << m_logFilePath << "\". Will use a default path instead." << '\n'; + << m_logFilePath << "\". Will use a default path instead.\n"; // ERROR! Maybe the file is not writable! // Clear the path; this will make it use the default m_logFilePath = ""; @@ -648,40 +647,31 @@ void ConfigServiceImpl::createUserPropertiesFile() const { "found in the Mantid.Properties file\n"; filestr << "# As this file will not be replaced with futher installations " "of Mantid it is a safe place to put \n"; - filestr << "# properties that suit your particular installation." << '\n'; + filestr << "# properties that suit your particular installation.\n"; filestr << "#\n"; filestr << "# See here for a list of possible options:\n"; filestr << "# " "http://www.mantidproject.org/" - "Properties_File#Mantid.User.Properties\n"; - filestr << '\n'; + "Properties_File#Mantid.User.Properties\n\n"; filestr << "##\n"; filestr << "## GENERAL\n"; - filestr << "##\n"; - filestr << '\n'; - filestr << "## Set the number of algorithm properties to retain" << '\n'; - filestr << "#algorithms.retained=90\n"; - filestr << '\n'; - filestr << "## Hides catagories from the algorithm list in MantidPlot" - << '\n'; - filestr << "#algorithms.catagories.hidden=Muons,Inelastic\n"; - filestr << '\n'; - filestr << "## Set the maximum number of coures used to run algorithms over" - << '\n'; - filestr << "#MultiThreaded.MaxCores=4\n"; - filestr << '\n'; + filestr << "##\n\n"; + filestr << "## Set the number of algorithm properties to retain\n"; + filestr << "#algorithms.retained=90\n\n"; + filestr << "## Hides catagories from the algorithm list in MantidPlot\n"; + filestr << "#algorithms.catagories.hidden=Muons,Inelastic\n\n"; + filestr + << "## Set the maximum number of coures used to run algorithms over\n"; + filestr << "#MultiThreaded.MaxCores=4\n\n"; filestr << "##\n"; filestr << "## FACILITY AND INSTRUMENT\n"; - filestr << "##\n"; - filestr << '\n'; + filestr << "##\n\n"; filestr << "## Sets the default facility\n"; filestr << "## e.g.: ISIS, SNS, ILL\n"; - filestr << "default.facility=\n"; - filestr << '\n'; + filestr << "default.facility=\n\n"; filestr << "## Sets the default instrument\n"; filestr << "## e.g. IRIS, HET, NIMROD\n"; - filestr << "default.instrument=\n"; - filestr << '\n'; + filestr << "default.instrument=\n\n"; filestr << '\n'; filestr << "## Sets the Q.convention\n"; filestr << "## Set to Crystallography for kf-ki instead of default " @@ -689,52 +679,39 @@ void ConfigServiceImpl::createUserPropertiesFile() const { filestr << "#Q.convention=Crystallography\n"; filestr << "##\n"; filestr << "## DIRECTORIES\n"; - filestr << "##\n"; - filestr << '\n'; + filestr << "##\n\n"; filestr << "## Sets a list of directories (separated by semi colons) to " "search for data\n"; - filestr << "#datasearch.directories=../data;../isis/data\n"; - filestr << '\n'; + filestr << "#datasearch.directories=../data;../isis/data\n\n"; filestr << "## Set a list (separated by semi colons) of directories to " "look for additional Python scripts\n"; - filestr << "#pythonscripts.directories=../scripts;../docs/MyScripts" - << '\n'; - filestr << '\n'; - filestr << "## Uncomment to enable archive search - ICat and Orbiter" - << '\n'; - filestr << "#datasearch.searcharchive=On\n"; - filestr << '\n'; + filestr << "#pythonscripts.directories=../scripts;../docs/MyScripts\n\n"; + filestr << "## Uncomment to enable archive search - ICat and Orbiter\n"; + filestr << "#datasearch.searcharchive=On\n\n"; filestr << "## Sets default save directory\n"; - filestr << "#defaultsave.directory=../data\n"; - filestr << '\n'; + filestr << "#defaultsave.directory=../data\n\n"; filestr << "##\n"; filestr << "## LOGGING\n"; - filestr << "##\n"; - filestr << '\n'; + filestr << "##\n\n"; filestr << "## Uncomment to change logging level\n"; filestr << "## Default is information\n"; - filestr << "## Valid values are: error, warning, notice, information, debug" - << '\n'; - filestr << "#logging.loggers.root.level=information\n"; - filestr << '\n'; - filestr << "## Sets the lowest level messages to be logged to file" << '\n'; + filestr + << "## Valid values are: error, warning, notice, information, debug\n"; + filestr << "#logging.loggers.root.level=information\n\n"; + filestr << "## Sets the lowest level messages to be logged to file\n"; filestr << "## Default is warning\n"; - filestr << "## Valid values are: error, warning, notice, information, debug" - << '\n'; - filestr << "#logging.channels.fileFilterChannel.level=debug\n"; - filestr << '\n'; + filestr + << "## Valid values are: error, warning, notice, information, debug\n"; + filestr << "#logging.channels.fileFilterChannel.level=debug\n\n"; filestr << "## Sets the file to write logs to\n"; - filestr << "#logging.channels.fileChannel.path=../mantid.log\n"; - filestr << '\n'; + filestr << "#logging.channels.fileChannel.path=../mantid.log\n\n"; filestr << "##\n"; filestr << "## MantidPlot\n"; - filestr << "##\n"; - filestr << '\n'; + filestr << "##\n\n"; filestr << "## Show invisible workspaces\n"; filestr << "#MantidOptions.InvisibleWorkspaces=0\n"; filestr << "## Re-use plot instances for different plot types\n"; - filestr << "#MantidOptions.ReusePlotInstances=Off\n"; - filestr << '\n'; + filestr << "#MantidOptions.ReusePlotInstances=Off\n\n"; filestr << "## Uncomment to disable use of OpenGL to render unwrapped " "instrument views\n"; filestr << "#MantidOptions.InstrumentView.UseOpenGL=Off\n"; diff --git a/Framework/Kernel/src/FacilityInfo.cpp b/Framework/Kernel/src/FacilityInfo.cpp index eda2c90cdd0..1711ef76e2f 100644 --- a/Framework/Kernel/src/FacilityInfo.cpp +++ b/Framework/Kernel/src/FacilityInfo.cpp @@ -194,7 +194,7 @@ const InstrumentInfo &FacilityInfo::instrument(std::string iName) const { if (boost::iequals(instrument.name(), iName)) // Case-insensitive search { g_log.debug() << "Instrument '" << iName << "' found as " - << instrument.name() << " at " << name() << "." << '\n'; + << instrument.name() << " at " << name() << ".\n"; return instrument; } } @@ -205,7 +205,7 @@ const InstrumentInfo &FacilityInfo::instrument(std::string iName) const { iName)) // Case-insensitive search { g_log.debug() << "Instrument '" << iName << "' found as " - << instrument.name() << " at " << name() << "." << '\n'; + << instrument.name() << " at " << name() << ".\n"; return instrument; } } diff --git a/Framework/Kernel/src/PropertyManager.cpp b/Framework/Kernel/src/PropertyManager.cpp index b0b633178f2..c207a258c13 100644 --- a/Framework/Kernel/src/PropertyManager.cpp +++ b/Framework/Kernel/src/PropertyManager.cpp @@ -447,8 +447,7 @@ bool PropertyManager::validateProperties() const { //"" means no error if (!error.empty()) { g_log.error() << "Property \"" << property.first - << "\" is not set to a valid value: \"" << error << "\"." - << '\n'; + << "\" is not set to a valid value: \"" << error << "\".\n"; allValid = false; } } diff --git a/Framework/Kernel/test/ConfigServiceTest.h b/Framework/Kernel/test/ConfigServiceTest.h index 4f90ce7fd23..25f43456ccd 100644 --- a/Framework/Kernel/test/ConfigServiceTest.h +++ b/Framework/Kernel/test/ConfigServiceTest.h @@ -88,7 +88,7 @@ public: TS_ASSERT(log1.getEnabled()); TS_ASSERT_THROWS_NOTHING(log1.fatal("you are allowed to see this")); TS_ASSERT_THROWS_NOTHING( - log1.fatal() << "you are allowed to see this via a stream" << '\n';); + log1.fatal() << "you are allowed to see this via a stream\n";); } void testLogLevelOffset() { diff --git a/Framework/Kernel/test/DiskBufferISaveableTest.h b/Framework/Kernel/test/DiskBufferISaveableTest.h index d18cc789785..873796a94bc 100644 --- a/Framework/Kernel/test/DiskBufferISaveableTest.h +++ b/Framework/Kernel/test/DiskBufferISaveableTest.h @@ -439,8 +439,7 @@ public: dbuf.toWrite(data[i]); data[i]->setBusy(false); } - std::cout << " Elapsed : " << tim << " to load " << num << " into MRU." - << '\n'; + std::cout << " Elapsed : " << tim << " to load " << num << " into MRU.\n"; } // void test_smallCache_no_writeBuffer() { diff --git a/Framework/Kernel/test/LogParserTest.h b/Framework/Kernel/test/LogParserTest.h index 510c91eeed7..738faac6b1e 100644 --- a/Framework/Kernel/test/LogParserTest.h +++ b/Framework/Kernel/test/LogParserTest.h @@ -692,66 +692,66 @@ private: void mkICP() { std::ofstream f(icp_file.path().c_str()); int dt = 0; - f << "2000-09-05T12:22:28 START_SE_WAIT" << '\n'; - f << "2000-09-05T12:22:33 BEGIN" << '\n'; + f << "2000-09-05T12:22:28 START_SE_WAIT\n"; + f << "2000-09-05T12:22:33 BEGIN\n"; dt += 8; - f << "2000-09-05T12:22:41 PAUSE" << '\n'; + f << "2000-09-05T12:22:41 PAUSE\n"; dt += 4; - f << "2000-09-05T12:22:55 CHANGE PERIOD 2" << '\n'; + f << "2000-09-05T12:22:55 CHANGE PERIOD 2\n"; dt += 3; - f << "2000-09-05T12:22:58 RESUME" << '\n'; + f << "2000-09-05T12:22:58 RESUME\n"; dt += 6; - f << "2000-09-05T12:23:04 PAUSE" << '\n'; + f << "2000-09-05T12:23:04 PAUSE\n"; dt += 4; - f << "2000-09-05T12:23:08 CHANGE PERIOD 1" << '\n'; + f << "2000-09-05T12:23:08 CHANGE PERIOD 1\n"; dt += 2; - f << "2000-09-05T12:23:10 RESUME" << '\n'; + f << "2000-09-05T12:23:10 RESUME\n"; dt += 8; - f << "2000-09-05T12:23:18 START_SE_WAIT" << '\n'; + f << "2000-09-05T12:23:18 START_SE_WAIT\n"; dt += 4; - f << "2000-09-05T12:23:22 CHANGE PERIOD 2" << '\n'; + f << "2000-09-05T12:23:22 CHANGE PERIOD 2\n"; dt += 5; - f << "2000-09-05T12:23:27 RESUME" << '\n'; + f << "2000-09-05T12:23:27 RESUME\n"; dt += 7; - f << "2000-09-05T12:23:34 ABORT" << '\n'; + f << "2000-09-05T12:23:34 ABORT\n"; dt += 3; - f << "2000-09-05T12:23:37 CHANGE PERIOD 1" << '\n'; + f << "2000-09-05T12:23:37 CHANGE PERIOD 1\n"; dt += 5; - f << "2000-09-05T12:23:42 END_SE_WAIT" << '\n'; - f << "2000-09-05T14:03:54 END" << '\n'; + f << "2000-09-05T12:23:42 END_SE_WAIT\n"; + f << "2000-09-05T14:03:54 END\n"; f.close(); } void mkICPVariant() { std::ofstream f(icp_file.path().c_str()); int dt = 0; - f << "2000-09-05T12:22:28 START_SE_WAIT" << '\n'; - f << "2000-09-05T12:22:33 BEGIN" << '\n'; + f << "2000-09-05T12:22:28 START_SE_WAIT\n"; + f << "2000-09-05T12:22:33 BEGIN\n"; dt += 8; - f << "2000-09-05T12:22:41 PAUSE" << '\n'; + f << "2000-09-05T12:22:41 PAUSE\n"; dt += 4; - f << "2000-09-05T12:22:55 CHANGE_PERIOD 2" << '\n'; + f << "2000-09-05T12:22:55 CHANGE_PERIOD 2\n"; dt += 3; - f << "2000-09-05T12:22:58 RESUME" << '\n'; + f << "2000-09-05T12:22:58 RESUME\n"; dt += 6; - f << "2000-09-05T12:23:04 PAUSE" << '\n'; + f << "2000-09-05T12:23:04 PAUSE\n"; dt += 4; - f << "2000-09-05T12:23:08 CHANGE_PERIOD 1" << '\n'; + f << "2000-09-05T12:23:08 CHANGE_PERIOD 1\n"; dt += 2; - f << "2000-09-05T12:23:10 RESUME" << '\n'; + f << "2000-09-05T12:23:10 RESUME\n"; dt += 8; - f << "2000-09-05T12:23:18 START_SE_WAIT" << '\n'; + f << "2000-09-05T12:23:18 START_SE_WAIT\n"; dt += 4; - f << "2000-09-05T12:23:22 CHANGE_PERIOD 2" << '\n'; + f << "2000-09-05T12:23:22 CHANGE_PERIOD 2\n"; dt += 5; - f << "2000-09-05T12:23:27 RESUME" << '\n'; + f << "2000-09-05T12:23:27 RESUME\n"; dt += 7; - f << "2000-09-05T12:23:34 ABORT" << '\n'; + f << "2000-09-05T12:23:34 ABORT\n"; dt += 3; - f << "2000-09-05T12:23:37 CHANGE_PERIOD 1" << '\n'; + f << "2000-09-05T12:23:37 CHANGE_PERIOD 1\n"; dt += 5; - f << "2000-09-05T12:23:42 END_SE_WAIT" << '\n'; - f << "2000-09-05T14:03:54 END" << '\n'; + f << "2000-09-05T12:23:42 END_SE_WAIT\n"; + f << "2000-09-05T14:03:54 END\n"; f.close(); } diff --git a/Framework/LiveData/src/ISISLiveEventDataListener.cpp b/Framework/LiveData/src/ISISLiveEventDataListener.cpp index d383b94cbb4..e0498f60ea5 100644 --- a/Framework/LiveData/src/ISISLiveEventDataListener.cpp +++ b/Framework/LiveData/src/ISISLiveEventDataListener.cpp @@ -84,16 +84,15 @@ bool ISISLiveEventDataListener::connect( try { m_socket.connect(tempAddress); // BLOCKING connect } catch (...) { - g_log.error() << "Connection to " << tempAddress.toString() << " failed." - << '\n'; + g_log.error() << "Connection to " << tempAddress.toString() + << " failed.\n"; return false; } } else { try { m_socket.connect(address); // BLOCKING connect } catch (...) { - g_log.debug() << "Connection to " << address.toString() << " failed." - << '\n'; + g_log.debug() << "Connection to " << address.toString() << " failed.\n"; return false; } } @@ -421,7 +420,7 @@ void ISISLiveEventDataListener::loadInstrument(const std::string &instrName) { } const char *warningMessage = "Failed to load instrument "; try { - g_log.notice() << "Loading instrument " << instrName << " ... " << '\n'; + g_log.notice() << "Loading instrument " << instrName << " ... \n"; API::Algorithm_sptr alg = API::AlgorithmFactory::Instance().create("LoadInstrument", -1); alg->initialize(); diff --git a/Framework/LiveData/src/LoadLiveData.cpp b/Framework/LiveData/src/LoadLiveData.cpp index f7710561593..cc2e2d2f280 100644 --- a/Framework/LiveData/src/LoadLiveData.cpp +++ b/Framework/LiveData/src/LoadLiveData.cpp @@ -99,8 +99,7 @@ LoadLiveData::runProcessing(Mantid::API::Workspace_sptr inputWS, // What is the name of the input workspace property if (alg->existsProperty("InputWorkspace")) { g_log.debug() - << "Using InputWorkspace as the input workspace property name." - << '\n'; + << "Using InputWorkspace as the input workspace property name.\n"; alg->setPropertyValue("InputWorkspace", inputName); } else { // Look for the first Workspace property that is marked INPUT. diff --git a/Framework/LiveData/src/MonitorLiveData.cpp b/Framework/LiveData/src/MonitorLiveData.cpp index bc59119dcf8..7657079f888 100644 --- a/Framework/LiveData/src/MonitorLiveData.cpp +++ b/Framework/LiveData/src/MonitorLiveData.cpp @@ -234,9 +234,9 @@ void MonitorLiveData::exec() { seconds = DateAndTime::secondsFromDuration(now - lastTime); if (seconds > UpdateEvery) g_log.warning() << "Cannot process live data as quickly as requested: " - "requested every " << UpdateEvery - << " seconds but it takes " << seconds << " seconds!" - << '\n'; + "requested every " + << UpdateEvery << " seconds but it takes " << seconds + << " seconds!\n"; } // loop until aborted // Set the outputs (only applicable when RunTransitionBehavior is "Stop") diff --git a/Framework/LiveData/src/SNSLiveEventDataListener.cpp b/Framework/LiveData/src/SNSLiveEventDataListener.cpp index 64367fc0129..428ddc6f69b 100644 --- a/Framework/LiveData/src/SNSLiveEventDataListener.cpp +++ b/Framework/LiveData/src/SNSLiveEventDataListener.cpp @@ -140,16 +140,15 @@ bool SNSLiveEventDataListener::connect(const Poco::Net::SocketAddress &address) try { m_socket.connect(tempAddress); // BLOCKING connect } catch (...) { - g_log.error() << "Connection to " << tempAddress.toString() << " failed." - << '\n'; + g_log.error() << "Connection to " << tempAddress.toString() + << " failed.\n"; return false; } } else { try { m_socket.connect(address); // BLOCKING connect } catch (...) { - g_log.debug() << "Connection to " << address.toString() << " failed." - << '\n'; + g_log.debug() << "Connection to " << address.toString() << " failed.\n"; return false; } } @@ -478,11 +477,11 @@ bool SNSLiveEventDataListener::rxPacket(const ADARA::BeamMonitorPkt &pkt) { if (monitorID > 5) { // Currently, we only handle monitors 0-5. At the present time, that's // sufficient. - g_log.error() << "Mantid cannot handle monitor ID's higher than 5. If " - << monitorID << " is actually valid, then an appropriate " - "entry must be made to the " - << " ADDABLE list at the top of Framework/API/src/Run.cpp" - << '\n'; + g_log.error() + << "Mantid cannot handle monitor ID's higher than 5. If " + << monitorID << " is actually valid, then an appropriate " + "entry must be made to the " + << " ADDABLE list at the top of Framework/API/src/Run.cpp\n"; } else { std::string monName("monitor"); monName += static_cast<char>( @@ -860,11 +859,10 @@ bool SNSLiveEventDataListener::rxPacket(const ADARA::VariableU32Pkt &pkt) { m_nameMap.find(std::make_pair(devId, pvId)); if (it == m_nameMap.end()) { - g_log.error() - << "Ignoring variable value packet for device " << devId - << ", variable " << pvId - << " because we haven't received a device descriptor packet for it." - << '\n'; + g_log.error() << "Ignoring variable value packet for device " << devId + << ", variable " << pvId + << " because we haven't received a device descriptor " + "packet for it.\n"; } else { { std::lock_guard<std::mutex> scopedLock(m_mutex); @@ -911,11 +909,10 @@ bool SNSLiveEventDataListener::rxPacket(const ADARA::VariableDoublePkt &pkt) { m_nameMap.find(std::make_pair(devId, pvId)); if (it == m_nameMap.end()) { - g_log.error() - << "Ignoring variable value packet for device " << devId - << ", variable " << pvId - << " because we haven't received a device descriptor packet for it." - << '\n'; + g_log.error() << "Ignoring variable value packet for device " << devId + << ", variable " << pvId + << " because we haven't received a device descriptor " + "packet for it.\n"; } else { { std::lock_guard<std::mutex> scopedLock(m_mutex); @@ -965,11 +962,10 @@ bool SNSLiveEventDataListener::rxPacket(const ADARA::VariableStringPkt &pkt) { m_nameMap.find(std::make_pair(devId, pvId)); if (it == m_nameMap.end()) { - g_log.error() - << "Ignoring variable value packet for device " << devId - << ", variable " << pvId - << " because we haven't received a device descriptor packet for it." - << '\n'; + g_log.error() << "Ignoring variable value packet for device " << devId + << ", variable " << pvId + << " because we haven't received a device descriptor " + "packet for it.\n"; } else { { std::lock_guard<std::mutex> scopedLock(m_mutex); @@ -1076,7 +1072,7 @@ bool SNSLiveEventDataListener::rxPacket(const ADARA::DeviceDescriptorPkt &pkt) { pvName = "<UNKNOWN>"; } g_log.warning() << "Ignoring process variable " << pvName - << " because it was missing required fields." << '\n'; + << " because it was missing required fields.\n"; } else { // Check the nameMap - we may have already received a description for // this diff --git a/Framework/LiveData/src/TOPAZLiveEventDataListener.cpp b/Framework/LiveData/src/TOPAZLiveEventDataListener.cpp index bad9418efa3..e3926cb8464 100644 --- a/Framework/LiveData/src/TOPAZLiveEventDataListener.cpp +++ b/Framework/LiveData/src/TOPAZLiveEventDataListener.cpp @@ -217,8 +217,7 @@ bool TOPAZLiveEventDataListener::connect( try { m_tcpSocket.connect(address); // BLOCKING connect } catch (...) { - g_log.error() << "Connection to " << address.toString() << " failed." - << '\n'; + g_log.error() << "Connection to " << address.toString() << " failed.\n"; return false; } @@ -348,8 +347,8 @@ void TOPAZLiveEventDataListener::run() { (hdr->iTotalBytes - hdr->Spare1) / sizeof(NEUTRON_EVENT); g_log.debug() << "Received UDP Packet. " << bytesRead << " bytes " - << num_pulse_ids << " pulses " << num_events << " events" - << '\n'; + << num_pulse_ids << " pulses " << num_events + << " events\n"; PULSE_ID_PTR pid = reinterpret_cast<PULSE_ID_PTR>(m_udpBuf + sizeof(COMMAND_HEADER)); diff --git a/Framework/LiveData/test/FakeEventDataListenerTest.h b/Framework/LiveData/test/FakeEventDataListenerTest.h index 4f225f4417b..6141da87a59 100644 --- a/Framework/LiveData/test/FakeEventDataListenerTest.h +++ b/Framework/LiveData/test/FakeEventDataListenerTest.h @@ -91,7 +91,7 @@ public: // Check it's a valid workspace TS_ASSERT(buffer) } - std::cout << tim << " to call extactData() " << num << " times" << '\n'; + std::cout << tim << " to call extactData() " << num << " times\n"; } private: diff --git a/Framework/MDAlgorithms/src/AccumulateMD.cpp b/Framework/MDAlgorithms/src/AccumulateMD.cpp index e3a15fe314c..58a7c59b03a 100644 --- a/Framework/MDAlgorithms/src/AccumulateMD.cpp +++ b/Framework/MDAlgorithms/src/AccumulateMD.cpp @@ -354,8 +354,8 @@ void AccumulateMD::exec() { IMDEventWorkspace_sptr out_ws = createMDWorkspace( input_data, psi, gl, gs, efix, out_filename, filebackend); this->setProperty("OutputWorkspace", out_ws); - g_log.notice() << this->name() << " successfully created a clean workspace" - << '\n'; + g_log.notice() << this->name() + << " successfully created a clean workspace\n"; this->progress(1.0); return; // POSSIBLE EXIT POINT } diff --git a/Framework/MDAlgorithms/src/CentroidPeaksMD.cpp b/Framework/MDAlgorithms/src/CentroidPeaksMD.cpp index 767ab6f775e..3eb78e2be6a 100644 --- a/Framework/MDAlgorithms/src/CentroidPeaksMD.cpp +++ b/Framework/MDAlgorithms/src/CentroidPeaksMD.cpp @@ -89,10 +89,10 @@ void CentroidPeaksMD::integrate(typename MDEventWorkspace<MDE, nd>::sptr ws) { int CoordinatesToUse = ws->getSpecialCoordinateSystem(); if (CoordinatesToUse == 1 && CoordinatesToUseStr != "Q (lab frame)") g_log.warning() << "Warning: used Q (lab frame) coordinates for MD " - "workspace, not CoordinatesToUse from input " << '\n'; + "workspace, not CoordinatesToUse from input \n"; else if (CoordinatesToUse == 2 && CoordinatesToUseStr != "Q (sample frame)") g_log.warning() << "Warning: used Q (sample frame) coordinates for MD " - "workspace, not CoordinatesToUse from input " << '\n'; + "workspace, not CoordinatesToUse from input \n"; else if (CoordinatesToUse == 3 && CoordinatesToUseStr != "HKL") g_log.warning() << "Warning: used HKL coordinates for MD workspace, not " "CoordinatesToUse from input \n"; @@ -162,8 +162,7 @@ void CentroidPeaksMD::integrate(typename MDEventWorkspace<MDE, nd>::sptr ws) { << CoordinatesToUse << '\n'; } else { g_log.information() << "Peak " << i << " at " << pos - << " had no signal, and could not be centroided." - << '\n'; + << " had no signal, and could not be centroided.\n"; } } diff --git a/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp b/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp index e1c089a96dc..679854a62ff 100644 --- a/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp +++ b/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp @@ -151,8 +151,7 @@ void CentroidPeaksMD2::integrate(typename MDEventWorkspace<MDE, nd>::sptr ws) { << CoordinatesToUse << '\n'; } else { g_log.information() << "Peak " << i << " at " << pos - << " had no signal, and could not be centroided." - << '\n'; + << " had no signal, and could not be centroided.\n"; } } diff --git a/Framework/MDAlgorithms/src/CloneMDWorkspace.cpp b/Framework/MDAlgorithms/src/CloneMDWorkspace.cpp index f286f8c6485..c252b363c5b 100644 --- a/Framework/MDAlgorithms/src/CloneMDWorkspace.cpp +++ b/Framework/MDAlgorithms/src/CloneMDWorkspace.cpp @@ -69,7 +69,7 @@ void CloneMDWorkspace::doClone( if (bc->isFileBacked()) { if (ws->fileNeedsUpdating()) { // Data was modified! You need to save first. - g_log.notice() << "InputWorkspace's file-backend being updated. " << '\n'; + g_log.notice() << "InputWorkspace's file-backend being updated. \n"; IAlgorithm_sptr alg = createChildAlgorithm("SaveMD", 0.0, 0.4, false); alg->setProperty("InputWorkspace", ws); alg->setPropertyValue("UpdateFileBackEnd", "1"); diff --git a/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp b/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp index 08b5a0dd802..c1a9e698faf 100644 --- a/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp +++ b/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp @@ -338,9 +338,9 @@ void ConvertToDiffractionMDWorkspace::exec() { bool lorentzDone = boost::lexical_cast<bool, std::string>(prop->value()); if (lorentzDone) { LorentzCorrection = false; - g_log.warning() << "Lorentz Correction was already done for this " - "workspace. LorentzCorrection was changed to false." - << '\n'; + g_log.warning() + << "Lorentz Correction was already done for this " + "workspace. LorentzCorrection was changed to false.\n"; } } } diff --git a/Framework/MDAlgorithms/src/FindPeaksMD.cpp b/Framework/MDAlgorithms/src/FindPeaksMD.cpp index 53263e234df..03a3bf3a531 100644 --- a/Framework/MDAlgorithms/src/FindPeaksMD.cpp +++ b/Framework/MDAlgorithms/src/FindPeaksMD.cpp @@ -367,7 +367,7 @@ void FindPeaksMD::findPeaks(typename MDEventWorkspace<MDE, nd>::sptr ws) { if (!badBox) { if (numBoxesFound++ >= m_maxPeaks) { g_log.notice() << "Number of peaks found exceeded the limit of " - << m_maxPeaks << ". Stopping peak finding." << '\n'; + << m_maxPeaks << ". Stopping peak finding.\n"; break; } @@ -533,7 +533,7 @@ void FindPeaksMD::findPeaksHisto( if (!badBox) { if (numBoxesFound++ >= m_maxPeaks) { g_log.notice() << "Number of peaks found exceeded the limit of " - << m_maxPeaks << ". Stopping peak finding." << '\n'; + << m_maxPeaks << ". Stopping peak finding.\n"; break; } diff --git a/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp b/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp index 20370cf12e4..af74a5e6390 100644 --- a/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp +++ b/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp @@ -175,11 +175,11 @@ void IntegratePeaksMD::integrate(typename MDEventWorkspace<MDE, nd>::sptr ws) { if (CoordinatesToUse == Kernel::QLab && CoordinatesToUseStr != "Q (lab frame)") g_log.warning() << "Warning: used Q (lab frame) coordinates for MD " - "workspace, not CoordinatesToUse from input " << '\n'; + "workspace, not CoordinatesToUse from input \n"; else if (CoordinatesToUse == Kernel::QSample && CoordinatesToUseStr != "Q (sample frame)") g_log.warning() << "Warning: used Q (sample frame) coordinates for MD " - "workspace, not CoordinatesToUse from input " << '\n'; + "workspace, not CoordinatesToUse from input \n"; else if (CoordinatesToUse == Kernel::HKL && CoordinatesToUseStr != "HKL") g_log.warning() << "Warning: used HKL coordinates for MD workspace, not " "CoordinatesToUse from input \n"; diff --git a/Framework/MDAlgorithms/src/LoadILLAsciiHelper.cpp b/Framework/MDAlgorithms/src/LoadILLAsciiHelper.cpp index 1470fdbfa97..80f2d14387a 100644 --- a/Framework/MDAlgorithms/src/LoadILLAsciiHelper.cpp +++ b/Framework/MDAlgorithms/src/LoadILLAsciiHelper.cpp @@ -360,11 +360,11 @@ std::vector<int> ILLParser::parseFieldISpec(int fieldWith) { * Just for debug purposes. */ void ILLParser::showHeader() { - std::cout << "* Global header" << '\n'; + std::cout << "* Global header\n"; for (auto &value : header) std::cout << value.first << " => " << value.second << '\n'; - std::cout << "* Spectrum header" << '\n'; + std::cout << "* Spectrum header\n"; int i = 0; std::vector<std::map<std::string, std::string>>::const_iterator s; for (s = spectraHeaders.begin(); s != spectraHeaders.end(); ++s) { @@ -376,7 +376,7 @@ void ILLParser::showHeader() { i++; } - std::cout << "* Spectrum list" << '\n'; + std::cout << "* Spectrum list\n"; std::vector<std::vector<int>>::const_iterator l; for (l = spectraList.begin(); l != spectraList.end(); ++l) { std::cout << "From " << (*l)[0] << " to " << (*l)[l->size() - 1] << " => " diff --git a/Framework/MDAlgorithms/src/LoadMD.cpp b/Framework/MDAlgorithms/src/LoadMD.cpp index c509000be38..5edaf98243a 100644 --- a/Framework/MDAlgorithms/src/LoadMD.cpp +++ b/Framework/MDAlgorithms/src/LoadMD.cpp @@ -564,7 +564,7 @@ void LoadMD::doLoad(typename MDEventWorkspace<MDE, nd>::sptr ws) { bc->getFileIO()->setWriteBufferSize(cacheMemory); g_log.information() << "Setting a DiskBuffer cache size of " << mb - << " MB, or " << cacheMemory << " events." << '\n'; + << " MB, or " << cacheMemory << " events.\n"; } } // Not file back end else if (!m_BoxStructureAndMethadata) { @@ -599,8 +599,8 @@ void LoadMD::doLoad(typename MDEventWorkspace<MDE, nd>::sptr ws) { } else // box structure and metadata only { } - g_log.debug() << tim << " to create all the boxes and fill them with events." - << '\n'; + g_log.debug() << tim + << " to create all the boxes and fill them with events.\n"; // Box of ID 0 is the head box. ws->setBox(boxTree[0]); diff --git a/Framework/MDAlgorithms/src/LoadSQW.cpp b/Framework/MDAlgorithms/src/LoadSQW.cpp index 072b511188a..d88f420de35 100644 --- a/Framework/MDAlgorithms/src/LoadSQW.cpp +++ b/Framework/MDAlgorithms/src/LoadSQW.cpp @@ -140,8 +140,7 @@ void LoadSQW::exec() { if ((m_nDataPoints * sizeof(MDEvent<4>) * 2 / 1024) < stat.availMem()) g_log.notice() << "You have enough memory available to load the " << m_nDataPoints << " points into memory; this would be " - "faster than using a file back-end." - << '\n'; + "faster than using a file back-end.\n"; IAlgorithm_sptr saver = this->createChildAlgorithm("SaveMD", 0.01, 0.05, true); @@ -167,8 +166,7 @@ void LoadSQW::exec() { g_log.warning() << "You may not have enough physical memory available to load the " << m_nDataPoints << " points into memory. You can cancel and specify " - "OutputFilename to load to a file back-end." - << '\n'; + "OutputFilename to load to a file back-end.\n"; } if (bc->isFileBacked()) { @@ -195,7 +193,7 @@ void LoadSQW::exec() { pWs->refreshCache(); if (!m_outputFile.empty()) { - g_log.notice() << "Starting SaveMD to update the file back-end." << '\n'; + g_log.notice() << "Starting SaveMD to update the file back-end.\n"; IAlgorithm_sptr saver = this->createChildAlgorithm("SaveMD", 0.76, 1.00); saver->setProperty("InputWorkspace", ws); saver->setProperty("UpdateFileBackEnd", true); @@ -227,8 +225,7 @@ void LoadSQW::readEvents( const size_t pixel_width = ncolumns * column_size; const size_t data_buffer_size = pixel_width * m_nDataPoints; - g_log.information() << m_nDataPoints << " data points in this SQW file." - << '\n'; + g_log.information() << m_nDataPoints << " data points in this SQW file.\n"; // Load from the input file is smallish blocks size_t blockSize = pixel_width * 1000000; diff --git a/Framework/MDAlgorithms/src/MergeMDFiles.cpp b/Framework/MDAlgorithms/src/MergeMDFiles.cpp index aba65ddd917..52f4ebd6314 100644 --- a/Framework/MDAlgorithms/src/MergeMDFiles.cpp +++ b/Framework/MDAlgorithms/src/MergeMDFiles.cpp @@ -311,7 +311,7 @@ void MergeMDFiles::finalizeOutput(const std::string &outputFile) { g_log.information() << overallTime << " to run refreshCache().\n"; if (!outputFile.empty()) { - g_log.notice() << "Starting SaveMD to update the file back-end." << '\n'; + g_log.notice() << "Starting SaveMD to update the file back-end.\n"; // create or open WS group and put there additional information about WS and // its dimensions bool old_data_there; @@ -336,7 +336,7 @@ void MergeMDFiles::finalizeOutput(const std::string &outputFile) { // Save box structure; m_BoxStruct.saveBoxStructure(outputFile); - g_log.information() << overallTime << " to run SaveMD structure" << '\n'; + g_log.information() << overallTime << " to run SaveMD structure\n"; } } diff --git a/Framework/MDAlgorithms/src/SaveZODS.cpp b/Framework/MDAlgorithms/src/SaveZODS.cpp index db0498e7730..179dd35b18b 100644 --- a/Framework/MDAlgorithms/src/SaveZODS.cpp +++ b/Framework/MDAlgorithms/src/SaveZODS.cpp @@ -68,9 +68,8 @@ void SaveZODS::exec() { "one bin in the 3rd dimension is OK)."); if (ws->getDimension(0)->getName() != "[H,0,0]") - g_log.warning() - << "SaveZODS expects the workspace to be in HKL space! Saving anyway..." - << '\n'; + g_log.warning() << "SaveZODS expects the workspace to be in HKL space! " + "Saving anyway...\n"; // Create a HDF5 file auto file = new ::NeXus::File(Filename, NXACC_CREATE5); diff --git a/Framework/PythonInterface/mantid/api/src/PythonAlgorithm/AlgorithmAdapter.cpp b/Framework/PythonInterface/mantid/api/src/PythonAlgorithm/AlgorithmAdapter.cpp index e2f84744720..c9e074f4c25 100644 --- a/Framework/PythonInterface/mantid/api/src/PythonAlgorithm/AlgorithmAdapter.cpp +++ b/Framework/PythonInterface/mantid/api/src/PythonAlgorithm/AlgorithmAdapter.cpp @@ -99,8 +99,7 @@ const std::string AlgorithmAdapter<BaseAlgorithm>::category() const { this->getLogger().warning() << "Python Algorithm " << name << " v" << version << " does not have a category defined. See " - "http://www.mantidproject.org/Basic_PythonAlgorithm_Structure" - << '\n'; + "http://www.mantidproject.org/Basic_PythonAlgorithm_Structure\n"; } return algCategory; } diff --git a/Framework/RemoteAlgorithms/src/DownloadRemoteFile.cpp b/Framework/RemoteAlgorithms/src/DownloadRemoteFile.cpp index 53d7940cd8e..2ba710096fb 100644 --- a/Framework/RemoteAlgorithms/src/DownloadRemoteFile.cpp +++ b/Framework/RemoteAlgorithms/src/DownloadRemoteFile.cpp @@ -80,7 +80,7 @@ void DownloadRemoteFile::exec() { outfile.close(); g_log.information() << "Downloaded '" << getPropertyValue("RemoteFileName") << "' to '" - << getPropertyValue("LocalFileName") << "'" << '\n'; + << getPropertyValue("LocalFileName") << "'\n"; } else { throw(std::runtime_error( std::string("Failed to open " + getPropertyValue("LocalFileName")))); diff --git a/Framework/RemoteAlgorithms/src/DownloadRemoteFile2.cpp b/Framework/RemoteAlgorithms/src/DownloadRemoteFile2.cpp index 6c3966680eb..2ad5e560315 100644 --- a/Framework/RemoteAlgorithms/src/DownloadRemoteFile2.cpp +++ b/Framework/RemoteAlgorithms/src/DownloadRemoteFile2.cpp @@ -58,8 +58,7 @@ void DownloadRemoteFile2::exec() { const std::string local = getPropertyValue("LocalFileName"); jobManager->downloadRemoteFile(tid, remote, local); - g_log.information() << "Downloaded '" << remote << "' to '" << local << "'" - << '\n'; + g_log.information() << "Downloaded '" << remote << "' to '" << local << "'\n"; } } // end namespace RemoteAlgorithms diff --git a/Framework/RemoteAlgorithms/src/SCARFTomoReconstruction.cpp b/Framework/RemoteAlgorithms/src/SCARFTomoReconstruction.cpp index e5e1540c208..c4b5cd4933d 100644 --- a/Framework/RemoteAlgorithms/src/SCARFTomoReconstruction.cpp +++ b/Framework/RemoteAlgorithms/src/SCARFTomoReconstruction.cpp @@ -257,7 +257,8 @@ void SCARFTomoReconstruction::exec() { jobId = getPropertyValue("CancelJobID"); } catch (std::runtime_error & /*e*/) { g_log.error() << "To cancel a job you need to give the ID of a job " - "running on " << m_SCARFComputeResource << "." << '\n'; + "running on " + << m_SCARFComputeResource << ".\n"; throw; } doCancel(username, jobId); @@ -274,7 +275,8 @@ void SCARFTomoReconstruction::exec() { destDir = getPropertyValue("DestinationDirectory"); } catch (std::runtime_error & /*e*/) { g_log.error() << "To upload a file you need to provide a destination " - "directory on " << m_SCARFComputeResource << "." << '\n'; + "directory on " + << m_SCARFComputeResource << ".\n"; throw; } doUploadFile(username, destDir, filename); @@ -284,7 +286,8 @@ void SCARFTomoReconstruction::exec() { jobId = getPropertyValue("DownloadJobID"); } catch (std::runtime_error & /*e*/) { g_log.error() << "To download a file you need to give the ID of a job " - "running on " << m_SCARFComputeResource << "." << '\n'; + "running on " + << m_SCARFComputeResource << ".\n"; throw; } try { @@ -453,7 +456,7 @@ void SCARFTomoReconstruction::doSubmit(const std::string &username) { g_log.error() << "You did not specify a the path to the parameter file " "which is required to create a new reconstruction job. " "Please provide " - "a valid tomography reconstruction parameter file" << '\n'; + "a valid tomography reconstruction parameter file\n"; throw; } diff --git a/Framework/RemoteAlgorithms/src/StartRemoteTransaction.cpp b/Framework/RemoteAlgorithms/src/StartRemoteTransaction.cpp index af54f8d72b1..d806aaafc15 100644 --- a/Framework/RemoteAlgorithms/src/StartRemoteTransaction.cpp +++ b/Framework/RemoteAlgorithms/src/StartRemoteTransaction.cpp @@ -57,7 +57,7 @@ void StartRemoteTransaction::exec() { std::string transId; resp["TransID"].getValue(transId); setPropertyValue("TransactionID", transId); - g_log.information() << "Transaction ID " << transId << " started." << '\n'; + g_log.information() << "Transaction ID " << transId << " started.\n"; } else { std::string errMsg; resp["Err_Msg"].getValue(errMsg); diff --git a/Framework/RemoteAlgorithms/src/StopRemoteTransaction.cpp b/Framework/RemoteAlgorithms/src/StopRemoteTransaction.cpp index 61292ec673c..1311ece17b5 100644 --- a/Framework/RemoteAlgorithms/src/StopRemoteTransaction.cpp +++ b/Framework/RemoteAlgorithms/src/StopRemoteTransaction.cpp @@ -56,7 +56,7 @@ void StopRemoteTransaction::exec() { std::istream &respStream = jobManager->httpGet( "/transaction", std::string("Action=Stop&TransID=") + transId); if (jobManager->lastStatus() == Poco::Net::HTTPResponse::HTTP_OK) { - g_log.information() << "Transaction ID " << transId << " stopped." << '\n'; + g_log.information() << "Transaction ID " << transId << " stopped.\n"; } else { JSONObject resp; initFromStream(resp, respStream); diff --git a/Framework/RemoteJobManagers/src/MantidWebServiceAPIJobManager.cpp b/Framework/RemoteJobManagers/src/MantidWebServiceAPIJobManager.cpp index 2ce2d834d20..36ee1eee02c 100644 --- a/Framework/RemoteJobManagers/src/MantidWebServiceAPIJobManager.cpp +++ b/Framework/RemoteJobManagers/src/MantidWebServiceAPIJobManager.cpp @@ -354,7 +354,7 @@ std::string MantidWebServiceAPIJobManager::startRemoteTransaction() { } std::string transId; resp["TransID"].getValue(transId); - g_log.information() << "Transaction ID " << transId << " started." << '\n'; + g_log.information() << "Transaction ID " << transId << " started.\n"; return transId; } @@ -375,7 +375,7 @@ void MantidWebServiceAPIJobManager::stopRemoteTransaction( httpGet("/transaction", std::string("Action=Stop&TransID=") + transId); if (lastStatus() == Poco::Net::HTTPResponse::HTTP_OK) { - g_log.information() << "Transaction ID " << transId << " stopped." << '\n'; + g_log.information() << "Transaction ID " << transId << " stopped.\n"; } else { JSONObject resp; initFromStream(resp, respStream); diff --git a/Framework/SINQ/src/PoldiAutoCorrelation5.cpp b/Framework/SINQ/src/PoldiAutoCorrelation5.cpp index f574471b53f..c43f02d4c9c 100644 --- a/Framework/SINQ/src/PoldiAutoCorrelation5.cpp +++ b/Framework/SINQ/src/PoldiAutoCorrelation5.cpp @@ -131,23 +131,21 @@ void PoldiAutoCorrelation5::logConfigurationInformation( for (size_t i = 0; i < chopper->slitPositions().size(); ++i) { g_log.information() << "_Poldi - Slits: " << i << ": Position = " << chopper->slitPositions()[i] - << "\t Time = " << chopper->slitTimes()[i] << " µs" - << '\n'; + << "\t Time = " << chopper->slitTimes()[i] + << " µs\n"; } } g_log.information() - << "_Poldi detector conf ------------------------------ " << '\n'; + << "_Poldi detector conf ------------------------------ \n"; g_log.information() << "_Poldi - Element count: " << cleanDetector->elementCount() << '\n'; g_log.information() << "_Poldi - Central element: " << cleanDetector->centralElement() << '\n'; g_log.information() << "_Poldi - 2Theta(central): " - << cleanDetector->twoTheta(199) / M_PI * 180.0 << "°" - << '\n'; + << cleanDetector->twoTheta(199) / M_PI * 180.0 << "°\n"; g_log.information() << "_Poldi - Distance(central): " - << cleanDetector->distanceFromSample(199) << " mm" - << '\n'; + << cleanDetector->distanceFromSample(199) << " mm\n"; std::set<int> deadWires = cleanDetector->deadWires(); g_log.information() << "_Poldi - Number of dead wires: " diff --git a/Framework/SINQ/src/PoldiIndexKnownCompounds.cpp b/Framework/SINQ/src/PoldiIndexKnownCompounds.cpp index b6c3b17ad56..be3b87c5da3 100644 --- a/Framework/SINQ/src/PoldiIndexKnownCompounds.cpp +++ b/Framework/SINQ/src/PoldiIndexKnownCompounds.cpp @@ -537,7 +537,7 @@ PoldiIndexKnownCompounds::getAllIndexCandidatePairs( g_log.information() << " Peak at d=" << static_cast<double>(currentPeak->d()) << " has " - << currentCandidates.size() << " candidates." << '\n'; + << currentCandidates.size() << " candidates.\n"; } return candidates; @@ -675,8 +675,7 @@ void PoldiIndexKnownCompounds::assignCandidates( if (inPeakSet(usedExpectedPeaks, expectedPeak)) { unassignedMeasuredPeaks.insert(measuredPeak); g_log.information() - << " Candidate rejected: Candidate has been already used." - << '\n'; + << " Candidate rejected: Candidate has been already used.\n"; } else { /* Otherwise, the indexed candidate is accepted and the measured peak * is removed from the set of peaks that are waiting for another @@ -695,7 +694,7 @@ void PoldiIndexKnownCompounds::assignCandidates( } else { g_log.information() << " Candidate rejected: peak has already been indexed: [" - << MillerIndicesIO::toString(measuredPeak->hkl()) << "]." << '\n'; + << MillerIndicesIO::toString(measuredPeak->hkl()) << "].\n"; } } diff --git a/Framework/SINQ/src/PoldiPeakSearch.cpp b/Framework/SINQ/src/PoldiPeakSearch.cpp index 008f125bdb1..7e1f7368605 100644 --- a/Framework/SINQ/src/PoldiPeakSearch.cpp +++ b/Framework/SINQ/src/PoldiPeakSearch.cpp @@ -564,13 +564,12 @@ void PoldiPeakSearch::exec() { if (xUnit->caption() == "") { g_log.information() - << " Workspace does not have unit, defaulting to MomentumTransfer." - << '\n'; + << " Workspace does not have unit, defaulting to MomentumTransfer.\n"; xUnit = UnitFactory::Instance().create("MomentumTransfer"); } else { - g_log.information() << " Unit of workspace is " << xUnit->caption() << "." - << '\n'; + g_log.information() << " Unit of workspace is " << xUnit->caption() + << ".\n"; } setMinimumDistance(getProperty("MinimumPeakSeparation")); @@ -586,7 +585,7 @@ void PoldiPeakSearch::exec() { MantidVec summedNeighborCounts = getNeighborSums(correlatedCounts); g_log.information() << " Neighboring counts summed, contains " - << summedNeighborCounts.size() << " data points." << '\n'; + << summedNeighborCounts.size() << " data points.\n"; std::list<MantidVec::const_iterator> peakPositionsSummed = findPeaks(summedNeighborCounts.begin(), summedNeighborCounts.end()); @@ -603,8 +602,8 @@ void PoldiPeakSearch::exec() { mapPeakPositionsToCorrelationData(peakPositionsSummed, summedNeighborCounts.begin(), correlatedCounts.begin()); - g_log.information() << " Peak positions transformed to original spectrum." - << '\n'; + g_log.information() + << " Peak positions transformed to original spectrum.\n"; /* Since intensities are required for filtering, they are extracted from the * original count data, diff --git a/Framework/SINQ/src/PoldiTruncateData.cpp b/Framework/SINQ/src/PoldiTruncateData.cpp index b4ad5f3afd5..8206e562226 100644 --- a/Framework/SINQ/src/PoldiTruncateData.cpp +++ b/Framework/SINQ/src/PoldiTruncateData.cpp @@ -167,8 +167,7 @@ void PoldiTruncateData::exec() { } } catch (std::invalid_argument) { m_log.error() - << "Cannot crop workspace. Please check the timing information." - << '\n'; + << "Cannot crop workspace. Please check the timing information.\n"; m_log.error() << " Calculated bin count: " << getCalculatedBinCount() << '\n'; m_log.error() << " Bin count in the workspace: " << getActualBinCount() diff --git a/Framework/SINQ/src/PoldiUtilities/PoldiAutoCorrelationCore.cpp b/Framework/SINQ/src/PoldiUtilities/PoldiAutoCorrelationCore.cpp index 469e204bf3b..434bfbee4dd 100644 --- a/Framework/SINQ/src/PoldiUtilities/PoldiAutoCorrelationCore.cpp +++ b/Framework/SINQ/src/PoldiUtilities/PoldiAutoCorrelationCore.cpp @@ -195,8 +195,8 @@ DataObjects::Workspace2D_sptr PoldiAutoCorrelationCore::calculate( double sumOfCorrelatedIntensities = std::accumulate( rawCorrelatedIntensities.begin(), rawCorrelatedIntensities.end(), 0.0); double sumOfCounts = getSumOfCounts(m_timeBinCount, m_detectorElements); - m_logger.information() << " Summing intensities (" << sumOfCounts << ")..." - << '\n'; + m_logger.information() << " Summing intensities (" << sumOfCounts + << ")...\n"; m_correlationBackground = calculateCorrelationBackground(sumOfCorrelatedIntensities, sumOfCounts); diff --git a/Framework/SINQ/src/SINQHMListener.cpp b/Framework/SINQ/src/SINQHMListener.cpp index 10aff37516c..6f3af35f324 100644 --- a/Framework/SINQ/src/SINQHMListener.cpp +++ b/Framework/SINQ/src/SINQHMListener.cpp @@ -235,7 +235,7 @@ void SINQHMListener::readHMData(IMDHistoWorkspace_sptr ws) { } istr.read(reinterpret_cast<char *>(data), length * sizeof(int)); if (!istr.good()) { - std::cout << "Encountered Problem before reading all SINQHM data" << '\n'; + std::cout << "Encountered Problem before reading all SINQHM data\n"; } for (int i = 0; i < length; i++) { data[i] = ntohl(data[i]); diff --git a/Framework/ScriptRepository/src/ScriptRepositoryImpl.cpp b/Framework/ScriptRepository/src/ScriptRepositoryImpl.cpp index 2e358b90b17..32e4c2f1f7c 100644 --- a/Framework/ScriptRepository/src/ScriptRepositoryImpl.cpp +++ b/Framework/ScriptRepository/src/ScriptRepositoryImpl.cpp @@ -254,8 +254,7 @@ ScriptRepositoryImpl::ScriptRepositoryImpl(const std::string &local_rep, } } catch (Poco::FileNotFoundException & /*ex*/) { g_log.error() - << "Testing the existence of repository.json and local.json failed" - << '\n'; + << "Testing the existence of repository.json and local.json failed\n"; return; } @@ -325,13 +324,13 @@ void ScriptRepositoryImpl::install(const std::string &path) { // download the repository json doDownloadFile(std::string(remote_url).append("repository.json"), rep_json_file); - g_log.debug() << "ScriptRepository downloaded repository information" << '\n'; + g_log.debug() << "ScriptRepository downloaded repository information\n"; // creation of the instance of local_json file if (!fileExists(local_json_file)) { writeStringFile(local_json_file, "{\n}", "ScriptRepository failed to create local repository"); - g_log.debug() << "ScriptRepository created the local repository information" - << '\n'; + g_log.debug() + << "ScriptRepository created the local repository information\n"; } #if defined(_WIN32) || defined(_WIN64) @@ -767,8 +766,7 @@ void ScriptRepositoryImpl::download_file(const std::string &file_path, } updateLocalJson(file_path, entry); /// FIXME: performance! - g_log.debug() << "ScriptRepository download " << local_path << " success!" - << '\n'; + g_log.debug() << "ScriptRepository download " << local_path << " success!\n"; } /** @@ -817,8 +815,7 @@ void ScriptRepositoryImpl::upload(const std::string &file_path, { using namespace Poco::Net; try { - g_log.notice() << "ScriptRepository uploading " << file_path << " ..." - << '\n'; + g_log.notice() << "ScriptRepository uploading " << file_path << " ...\n"; Kernel::InternetHelper inetHelper; @@ -887,8 +884,7 @@ void ScriptRepositoryImpl::upload(const std::string &file_path, detail.append("\nFrom Command: ").append(cmd); if (info == "success") { - g_log.notice() << "ScriptRepository:" << file_path << " uploaded!" - << '\n'; + g_log.notice() << "ScriptRepository:" << file_path << " uploaded!\n"; // update the file RepositoryEntry &entry = repo.at(file_path); @@ -916,7 +912,7 @@ void ScriptRepositoryImpl::upload(const std::string &file_path, if (!published_date.empty()) remote_entry.pub_date = DateAndTime(published_date); remote_entry.status = BOTH_UNCHANGED; - g_log.debug() << "ScriptRepository updating repository json " << '\n'; + g_log.debug() << "ScriptRepository updating repository json \n"; updateRepositoryJson(file_path, remote_entry); } else @@ -1041,8 +1037,7 @@ void ScriptRepositoryImpl::remove(const std::string &file_path, if (raise_exc) throw ScriptRepoException(ss.str()); - g_log.information() << "ScriptRepository deleting " << file_path << " ..." - << '\n'; + g_log.information() << "ScriptRepository deleting " << file_path << " ...\n"; { // request to remove the file from the central repository @@ -1228,8 +1223,8 @@ std::vector<std::string> ScriptRepositoryImpl::check4Update() { f.moveTo(backup); } try { - g_log.debug() << "Download information from the Central Repository status" - << '\n'; + g_log.debug() + << "Download information from the Central Repository status\n"; doDownloadFile(std::string(remote_url).append("repository.json"), rep_json_file); } catch (...) { diff --git a/Framework/WorkflowAlgorithms/src/DgsReduction.cpp b/Framework/WorkflowAlgorithms/src/DgsReduction.cpp index 7887c5803dd..014583cecc4 100644 --- a/Framework/WorkflowAlgorithms/src/DgsReduction.cpp +++ b/Framework/WorkflowAlgorithms/src/DgsReduction.cpp @@ -695,7 +695,7 @@ void DgsReduction::exec() { const std::string reductionManagerName = this->getProperty("ReductionProperties"); if (reductionManagerName.empty()) { - g_log.error() << "ERROR: Reduction Property Manager name is empty" << '\n'; + g_log.error() << "ERROR: Reduction Property Manager name is empty\n"; return; } this->reductionManager = boost::make_shared<PropertyManager>(); diff --git a/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction.cpp b/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction.cpp index 8708c790799..fcb36a553b9 100644 --- a/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction.cpp +++ b/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction.cpp @@ -148,8 +148,7 @@ void EQSANSDarkCurrentSubtraction::exec() { output_message += "\n Could not find proton charge or duration in sample logs"; g_log.error() - << "ERROR: Could not find proton charge or duration in sample logs" - << '\n'; + << "ERROR: Could not find proton charge or duration in sample logs\n"; }; progress.report("Scaling dark current"); diff --git a/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction2.cpp b/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction2.cpp index 002ca936b39..bc6eae21943 100644 --- a/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction2.cpp +++ b/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction2.cpp @@ -82,8 +82,7 @@ void EQSANSDarkCurrentSubtraction2::exec() { if (inputEventWS) { g_log.error() << "To use this version of EQSANSDarkCurrentSubtraction, " << "you need to make sure EQSANSLoad produces histograms. " - << "You can also turn the dark current subtraction off." - << '\n'; + << "You can also turn the dark current subtraction off.\n"; throw std::invalid_argument( "EQSANSDarkCurrentSubtraction-v2 only works on histograms."); } @@ -170,8 +169,7 @@ void EQSANSDarkCurrentSubtraction2::exec() { output_message += "\n Could not find proton charge or duration in sample logs"; g_log.error() - << "ERROR: Could not find proton charge or duration in sample logs" - << '\n'; + << "ERROR: Could not find proton charge or duration in sample logs\n"; }; // The scaling factor should account for the TOF cuts on each side of a frame // The EQSANSLoad algorithm cuts the beginning and end of the TOF distribution @@ -202,15 +200,13 @@ void EQSANSDarkCurrentSubtraction2::exec() { const int numberOfDarkSpectra = static_cast<int>(scaledDarkWS->getNumberHistograms()); if (numberOfSpectra != numberOfDarkSpectra) { - g_log.error() - << "Incompatible number of pixels between sample run and dark current" - << '\n'; + g_log.error() << "Incompatible number of pixels between sample run and " + "dark current\n"; } const int nBins = static_cast<int>(inputWS->readY(0).size()); const int xLength = static_cast<int>(inputWS->readX(0).size()); if (xLength != nBins + 1) { - g_log.error() << "The input workspaces are expected to be histograms" - << '\n'; + g_log.error() << "The input workspaces are expected to be histograms\n"; } progress.report("Subtracting dark current"); diff --git a/Framework/WorkflowAlgorithms/src/EQSANSLoad.cpp b/Framework/WorkflowAlgorithms/src/EQSANSLoad.cpp index 71cf818a5b3..39ec27fba99 100644 --- a/Framework/WorkflowAlgorithms/src/EQSANSLoad.cpp +++ b/Framework/WorkflowAlgorithms/src/EQSANSLoad.cpp @@ -451,7 +451,7 @@ void EQSANSLoad::exec() { "or an input workspace must be provided"); } else if (fileName.size() > 0 && inputEventWS) { g_log.error() << "EQSANSLoad input error: Either a valid file path or an " - "input workspace must be provided, but not both" << '\n'; + "input workspace must be provided, but not both\n"; throw std::runtime_error("EQSANSLoad input error: Either a valid file path " "or an input workspace must be provided, but not " "both"); @@ -553,10 +553,10 @@ void EQSANSLoad::exec() { sdd = sample_det_dist; } else { if (!dataWS->run().hasProperty("detectorZ")) { - g_log.error() << "Could not determine Z position: the " - "SampleDetectorDistance property was not set " - "and the run logs do not contain the detectorZ property" - << '\n'; + g_log.error() + << "Could not determine Z position: the " + "SampleDetectorDistance property was not set " + "and the run logs do not contain the detectorZ property\n"; throw std::invalid_argument( "Could not determine Z position: stopping execution"); } @@ -588,8 +588,7 @@ void EQSANSLoad::exec() { mvAlg->setProperty("Z", sdd / 1000.0); mvAlg->setProperty("RelativePosition", false); mvAlg->executeAsChildAlg(); - g_log.information() << "Moving detector to " << sdd / 1000.0 << " meters" - << '\n'; + g_log.information() << "Moving detector to " << sdd / 1000.0 << " meters\n"; m_output_message += " Detector position: " + Poco::NumberFormatter::format(sdd / 1000.0, 3) + " m\n"; @@ -631,8 +630,7 @@ void EQSANSLoad::exec() { if (use_config) { if (m_moderator_position > -13.0) g_log.error() - << "Moderator position seems close to the sample, please check" - << '\n'; + << "Moderator position seems close to the sample, please check\n"; g_log.information() << "Moving moderator to " << m_moderator_position << '\n'; m_output_message += " Moderator position: " + diff --git a/Framework/WorkflowAlgorithms/src/EQSANSMonitorTOF.cpp b/Framework/WorkflowAlgorithms/src/EQSANSMonitorTOF.cpp index 5c8721b1ce4..454052cb6c2 100644 --- a/Framework/WorkflowAlgorithms/src/EQSANSMonitorTOF.cpp +++ b/Framework/WorkflowAlgorithms/src/EQSANSMonitorTOF.cpp @@ -63,7 +63,7 @@ void EQSANSMonitorTOF::exec() { mon = inputWS->getInstrument()->getDetector(monitor_list[0]); } catch (Exception::NotFoundError &) { g_log.error() << "Spectrum number " << monitor_list[0] - << " has no detector assigned to it - discarding" << '\n'; + << " has no detector assigned to it - discarding\n"; return; } @@ -419,8 +419,7 @@ double EQSANSMonitorTOF::getTofOffset(MatrixWorkspace_const_sptr inputWS, double frame_tof0 = frame_srcpulse_wl_1 / 3.9560346 * source_to_monitor; g_log.information() << "Frame width " << tmp_frame_width << '\n'; - g_log.information() << "TOF offset = " << frame_tof0 << " microseconds" - << '\n'; + g_log.information() << "TOF offset = " << frame_tof0 << " microseconds\n"; g_log.information() << "Band defined by T1-T4 " << frame_wl_1 << " " << frame_wl_2; if (frame_skipping) @@ -428,11 +427,12 @@ double EQSANSMonitorTOF::getTofOffset(MatrixWorkspace_const_sptr inputWS, << '\n'; else g_log.information() << '\n'; - g_log.information() << "Chopper Actual Phase Lambda1 Lambda2" - << '\n'; - for (int i = 0; i < 4; i++) - g_log.information() << i << " " << chopper_actual_phase[i] << " " - << chopper_wl_1[i] << " " << chopper_wl_2[i] << '\n'; + g_log.information() + << "Chopper Actual Phase Lambda1 Lambda2\n" for (int i = 0; + i < 4; i++) + g_log.information() + << i << " " << chopper_actual_phase[i] << " " << chopper_wl_1[i] + << " " << chopper_wl_2[i] << '\n'; setProperty("FrameSkipping", frame_skipping); diff --git a/Framework/WorkflowAlgorithms/src/EQSANSPatchSensitivity.cpp b/Framework/WorkflowAlgorithms/src/EQSANSPatchSensitivity.cpp index 29de09fe798..fb0bd02bb28 100644 --- a/Framework/WorkflowAlgorithms/src/EQSANSPatchSensitivity.cpp +++ b/Framework/WorkflowAlgorithms/src/EQSANSPatchSensitivity.cpp @@ -122,8 +122,7 @@ void EQSANSPatchSensitivity::exec() { pmap.addBool(det, "masked", false); } } catch (Kernel::Exception::NotFoundError &e) { - g_log.warning() << e.what() << " Found while setting mask bit" - << '\n'; + g_log.warning() << e.what() << " Found while setting mask bit\n"; } } } diff --git a/Framework/WorkflowAlgorithms/src/HFIRLoad.cpp b/Framework/WorkflowAlgorithms/src/HFIRLoad.cpp index 8103b0f49e0..b7dafbc3278 100644 --- a/Framework/WorkflowAlgorithms/src/HFIRLoad.cpp +++ b/Framework/WorkflowAlgorithms/src/HFIRLoad.cpp @@ -81,8 +81,7 @@ void HFIRLoad::moveToBeamCenter(API::MatrixWorkspace_sptr &dataWS, center_y = default_ctr_y_pix; g_log.information() << "Setting beam center to [" << Poco::NumberFormatter::format(center_x, 1) << ", " - << Poco::NumberFormatter::format(center_y, 1) << "]" - << '\n'; + << Poco::NumberFormatter::format(center_y, 1) << "]\n"; return; } diff --git a/Framework/WorkflowAlgorithms/src/RefReduction.cpp b/Framework/WorkflowAlgorithms/src/RefReduction.cpp index 40528bde6c4..26f5f8b2e11 100644 --- a/Framework/WorkflowAlgorithms/src/RefReduction.cpp +++ b/Framework/WorkflowAlgorithms/src/RefReduction.cpp @@ -175,8 +175,7 @@ MatrixWorkspace_sptr RefReduction::processData(const std::string polarization) { const std::vector<int> peakRange = getProperty("SignalPeakPixelRange"); if (peakRange.size() < 2) { g_log.error() - << "SignalPeakPixelRange parameter should be a vector of two values" - << '\n'; + << "SignalPeakPixelRange parameter should be a vector of two values\n"; throw std::invalid_argument( "SignalPeakPixelRange parameter should be a vector of two values"); } @@ -671,9 +670,8 @@ double RefReduction::calculateAngleREFM(MatrixWorkspace_sptr workspace) { if (ref_pix == 0 || isEmpty(ref_pix)) { const std::vector<int> peakRange = getProperty("SignalPeakPixelRange"); if (peakRange.size() < 2) { - g_log.error() - << "SignalPeakPixelRange parameter should be a vector of two values" - << '\n'; + g_log.error() << "SignalPeakPixelRange parameter should be a vector of " + "two values\n"; throw std::invalid_argument( "SignalPeakPixelRange parameter should be a vector of two values"); } diff --git a/Framework/WorkflowAlgorithms/src/RefRoi.cpp b/Framework/WorkflowAlgorithms/src/RefRoi.cpp index bb620e8e518..0de6a0ef827 100644 --- a/Framework/WorkflowAlgorithms/src/RefRoi.cpp +++ b/Framework/WorkflowAlgorithms/src/RefRoi.cpp @@ -143,8 +143,7 @@ void RefRoi::extract2D() { // Check that the X-axis is in wavelength units const std::string unit = inputWS->getAxis(0)->unit()->caption(); if (Poco::icompare(unit, "Wavelength") != 0) { - g_log.error() << "RefRoi expects units of wavelength to convert to Q" - << '\n'; + g_log.error() << "RefRoi expects units of wavelength to convert to Q\n"; throw std::runtime_error( "RefRoi expects units of wavelength to convert to Q"); } diff --git a/Framework/WorkflowAlgorithms/src/SANSSolidAngleCorrection.cpp b/Framework/WorkflowAlgorithms/src/SANSSolidAngleCorrection.cpp index dfcb3279e96..0df754ed555 100644 --- a/Framework/WorkflowAlgorithms/src/SANSSolidAngleCorrection.cpp +++ b/Framework/WorkflowAlgorithms/src/SANSSolidAngleCorrection.cpp @@ -116,7 +116,7 @@ void SANSSolidAngleCorrection::exec() { det = inputWS->getDetector(i); } catch (Exception::NotFoundError &) { g_log.warning() << "Workspace index " << i - << " has no detector assigned to it - discarding" << '\n'; + << " has no detector assigned to it - discarding\n"; // Catch if no detector. Next line tests whether this happened - test // placed // outside here because Mac Intel compiler doesn't like 'continue' in a @@ -186,7 +186,7 @@ void SANSSolidAngleCorrection::execEvent() { det = outputEventWS->getDetector(i); } catch (Exception::NotFoundError &) { g_log.warning() << "Workspace index " << i - << " has no detector assigned to it - discarding" << '\n'; + << " has no detector assigned to it - discarding\n"; // Catch if no detector. Next line tests whether this happened - test // placed // outside here because Mac Intel compiler doesn't like 'continue' in a diff --git a/Framework/WorkflowAlgorithms/src/SetupEQSANSReduction.cpp b/Framework/WorkflowAlgorithms/src/SetupEQSANSReduction.cpp index 4ba1a252448..736a7be6042 100644 --- a/Framework/WorkflowAlgorithms/src/SetupEQSANSReduction.cpp +++ b/Framework/WorkflowAlgorithms/src/SetupEQSANSReduction.cpp @@ -581,7 +581,7 @@ void SetupEQSANSReduction::exec() { // Reduction property manager const std::string reductionManagerName = getProperty("ReductionProperties"); if (reductionManagerName.size() == 0) { - g_log.error() << "ERROR: Reduction Property Manager name is empty" << '\n'; + g_log.error() << "ERROR: Reduction Property Manager name is empty\n"; return; } boost::shared_ptr<PropertyManager> reductionManager = diff --git a/Framework/WorkflowAlgorithms/src/SetupHFIRReduction.cpp b/Framework/WorkflowAlgorithms/src/SetupHFIRReduction.cpp index 91cc79d9bd1..dadcc3761db 100644 --- a/Framework/WorkflowAlgorithms/src/SetupHFIRReduction.cpp +++ b/Framework/WorkflowAlgorithms/src/SetupHFIRReduction.cpp @@ -620,7 +620,7 @@ void SetupHFIRReduction::exec() { // Reduction property manager const std::string reductionManagerName = getProperty("ReductionProperties"); if (reductionManagerName.size() == 0) { - g_log.error() << "ERROR: Reduction Property Manager name is empty" << '\n'; + g_log.error() << "ERROR: Reduction Property Manager name is empty\n"; return; } boost::shared_ptr<PropertyManager> reductionManager = diff --git a/Framework/WorkflowAlgorithms/src/SetupILLD33Reduction.cpp b/Framework/WorkflowAlgorithms/src/SetupILLD33Reduction.cpp index d5a649a1414..3a4297a17ad 100644 --- a/Framework/WorkflowAlgorithms/src/SetupILLD33Reduction.cpp +++ b/Framework/WorkflowAlgorithms/src/SetupILLD33Reduction.cpp @@ -484,7 +484,7 @@ void SetupILLD33Reduction::exec() { // Reduction property manager const std::string reductionManagerName = getProperty("ReductionProperties"); if (reductionManagerName.size() == 0) { - g_log.error() << "ERROR: Reduction Property Manager name is empty" << '\n'; + g_log.error() << "ERROR: Reduction Property Manager name is empty\n"; return; } boost::shared_ptr<PropertyManager> reductionManager = diff --git a/MantidPlot/src/ApplicationWindow.cpp b/MantidPlot/src/ApplicationWindow.cpp index 2c7c86051f5..aa148639c41 100644 --- a/MantidPlot/src/ApplicationWindow.cpp +++ b/MantidPlot/src/ApplicationWindow.cpp @@ -627,14 +627,13 @@ bool ApplicationWindow::shouldWeShowFirstTimeSetup( const Mantid::Kernel::InstrumentInfo &instrumentInfo = config.getInstrument(instrument); g_log.information() << "Default facility '" << facilityInfo.name() - << "', instrument '" << instrumentInfo.name() << "'" - << '\n'; + << "', instrument '" << instrumentInfo.name() + << "'\n"; } catch (Mantid::Kernel::Exception::NotFoundError &) { // failed to find the facility or instrument g_log.error() << "Could not find your default facility '" << facility << "' or instrument '" << instrument - << "' in facilities.xml, showing please select again." - << '\n'; + << "' in facilities.xml, showing please select again.\n"; return true; } } diff --git a/MantidPlot/src/Mantid/MantidUI.cpp b/MantidPlot/src/Mantid/MantidUI.cpp index 3d865f316b8..3bb68ac5851 100644 --- a/MantidPlot/src/Mantid/MantidUI.cpp +++ b/MantidPlot/src/Mantid/MantidUI.cpp @@ -3113,8 +3113,8 @@ MultiLayer *MantidUI::plot1D(const QMultiMap<QString, int> &toPlot, g->setDistribution(firstCurve->isDistribution()); } } catch (Mantid::Kernel::Exception::NotFoundError &) { - g_log.warning() << "Workspace " << it.key().toStdString() << " not found" - << '\n'; + g_log.warning() << "Workspace " << it.key().toStdString() + << " not found\n"; } catch (std::exception &ex) { g_log.warning() << ex.what() << '\n'; } diff --git a/MantidPlot/src/main.cpp b/MantidPlot/src/main.cpp index 7a26c836cab..276d554ff0d 100644 --- a/MantidPlot/src/main.cpp +++ b/MantidPlot/src/main.cpp @@ -176,7 +176,7 @@ int main(int argc, char **argv) { QString str(argv[1]); if (str == "-v" || str == "--version") { std::cout << Mantid::Kernel::MantidVersion::version() << " (" - << Mantid::Kernel::MantidVersion::releaseDate() << ")" << '\n'; + << Mantid::Kernel::MantidVersion::releaseDate() << ")\n"; exit(0); } else if (str == "-r" || str == "--revision") // Print abbreviated git SHA-1 diff --git a/MantidQt/CustomInterfaces/src/DataComparison.cpp b/MantidQt/CustomInterfaces/src/DataComparison.cpp index bbc0330ed9c..a40d74aab6a 100644 --- a/MantidQt/CustomInterfaces/src/DataComparison.cpp +++ b/MantidQt/CustomInterfaces/src/DataComparison.cpp @@ -140,8 +140,7 @@ void DataComparison::addDataItem(Workspace_const_sptr ws) { MatrixWorkspace_const_sptr matrixWs = boost::dynamic_pointer_cast<const MatrixWorkspace>(ws); if (!matrixWs) { - g_log.error() << "Workspace " << ws->name() << "is of incorrect type!" - << '\n'; + g_log.error() << "Workspace " << ws->name() << "is of incorrect type!\n"; return; } diff --git a/MantidQt/CustomInterfaces/src/EnggDiffraction/EnggDiffractionPresenter.cpp b/MantidQt/CustomInterfaces/src/EnggDiffraction/EnggDiffractionPresenter.cpp index b18523c6c28..a3dc0b8bfb4 100644 --- a/MantidQt/CustomInterfaces/src/EnggDiffraction/EnggDiffractionPresenter.cpp +++ b/MantidQt/CustomInterfaces/src/EnggDiffraction/EnggDiffractionPresenter.cpp @@ -425,8 +425,7 @@ void EnggDiffractionPresenter::processFocusBasic() { int focusMode = m_view->currentMultiRunMode(); if (focusMode == 0) { - g_log.debug() << " focus mode selected Individual Run Files Separately " - << '\n'; + g_log.debug() << " focus mode selected Individual Run Files Separately \n"; // start focusing startFocusing(multi_RunNo, banks, "", ""); @@ -466,8 +465,7 @@ void EnggDiffractionPresenter::processFocusCropped() { int focusMode = m_view->currentMultiRunMode(); if (focusMode == 0) { - g_log.debug() << " focus mode selected Individual Run Files Separately " - << '\n'; + g_log.debug() << " focus mode selected Individual Run Files Separately \n"; startFocusing(multi_RunNo, banks, specNos, ""); @@ -504,8 +502,7 @@ void EnggDiffractionPresenter::processFocusTexture() { int focusMode = m_view->currentMultiRunMode(); if (focusMode == 0) { - g_log.debug() << " focus mode selected Individual Run Files Separately " - << '\n'; + g_log.debug() << " focus mode selected Individual Run Files Separately \n"; startFocusing(multi_RunNo, std::vector<bool>(), "", dgFile); } else if (focusMode == 1) { @@ -946,7 +943,7 @@ void EnggDiffractionPresenter::setDifcTzero(MatrixWorkspace_sptr wks) const { void EnggDiffractionPresenter::doFitting(const std::string &focusedRunNo, const std::string &ExpectedPeaks) { g_log.notice() << "EnggDiffraction GUI: starting new fitting with file " - << focusedRunNo << ". This may take a few seconds... " << '\n'; + << focusedRunNo << ". This may take a few seconds... \n"; MatrixWorkspace_sptr focusedWS; m_fittingFinishedOK = false; @@ -1001,8 +998,7 @@ void EnggDiffractionPresenter::doFitting(const std::string &focusedRunNo, // bank name "Error description: " + static_cast<std::string>(re.what()) + - " Please check also the log message for detail." - << '\n'; + " Please check also the log message for detail.\n"; } try { @@ -1403,9 +1399,9 @@ void EnggDiffractionPresenter::plotFitPeaksCurves() { m_view->showStatus("Peaks fitted successfully"); } else { - g_log.notice() << "Focused workspace has been plotted to the " - "graph; further peaks can be adding using Peak Tools." - << '\n'; + g_log.notice() + << "Focused workspace has been plotted to the " + "graph; further peaks can be adding using Peak Tools.\n"; g_log.warning() << "Peaks could not be plotted as the fitting process " "did not finish correctly.\n"; m_view->showStatus("No peaks could be fitted"); @@ -1427,8 +1423,7 @@ void EnggDiffractionPresenter::fittingFinished() { return; if (!m_fittingFinishedOK) { - g_log.warning() << "The single peak fitting did not finish correctly." - << '\n'; + g_log.warning() << "The single peak fitting did not finish correctly.\n"; if (m_workerThread) { delete m_workerThread; m_workerThread = NULL; @@ -1507,8 +1502,7 @@ void EnggDiffractionPresenter::processStopFocus() { g_abortThread = true; g_log.warning() << "Focus Stop has been clicked, please wait until " - "current focus run process has been completed. " - << '\n'; + "current focus run process has been completed. \n"; } } } @@ -1877,8 +1871,8 @@ void EnggDiffractionPresenter::calibrationFinished() { const std::string ceriaNo = isValidRunNumber(m_view->newCeriaNo()); updateCalibParmsTable(); m_view->newCalibLoaded(vanNo, ceriaNo, m_calibFullPath); - g_log.notice() << "Calibration finished and ready as 'current calibration'." - << '\n'; + g_log.notice() + << "Calibration finished and ready as 'current calibration'.\n"; m_view->showStatus("Calibration finished succesfully. Ready"); } if (m_workerThread) { @@ -2489,7 +2483,7 @@ void EnggDiffractionPresenter::focusingFinished() { "log messages for details\n"; m_view->showStatus("Focusing didn't finish succesfully. Ready"); } else { - g_log.notice() << "Focusing finished - focused run(s) are ready." << '\n'; + g_log.notice() << "Focusing finished - focused run(s) are ready.\n"; m_view->showStatus("Focusing finished succesfully. Ready"); } if (m_workerThread) { @@ -2592,8 +2586,7 @@ void EnggDiffractionPresenter::doFocusing(const EnggDiffCalibSettings &cs, "cannot not be processed\n"; } else { g_log.notice() - << "Load alogirthm has successfully merged the files provided" - << '\n'; + << "Load alogirthm has successfully merged the files provided\n"; } } else { @@ -3023,8 +3016,8 @@ void EnggDiffractionPresenter::doRebinningTime(const std::string &runNo, m_rebinningFinishedOK = false; const Workspace_sptr inWS = loadToPreproc(runNo); if (!inWS) - g_log.error() << "Error: could not load the input workspace for rebinning." - << '\n'; + g_log.error() + << "Error: could not load the input workspace for rebinning.\n"; const std::string rebinName = "Rebin"; try { @@ -3126,8 +3119,8 @@ void EnggDiffractionPresenter::doRebinningPulses(const std::string &runNo, m_rebinningFinishedOK = false; const Workspace_sptr inWS = loadToPreproc(runNo); if (!inWS) - g_log.error() << "Error: could not load the input workspace for rebinning." - << '\n'; + g_log.error() + << "Error: could not load the input workspace for rebinning.\n"; const std::string rebinName = "RebinByPulseTimes"; try { @@ -3198,8 +3191,7 @@ void EnggDiffractionPresenter::rebinningFinished() { if (!m_rebinningFinishedOK) { g_log.warning() << "The pre-processing (re-binning) did not finish " - "correctly. Check previous log messages for details" - << '\n'; + "correctly. Check previous log messages for details\n"; m_view->showStatus("Rebinning didn't finish succesfully. Ready"); } else { g_log.notice() << "Pre-processing (re-binning) finished - the output " @@ -3809,8 +3801,7 @@ void EnggDiffractionPresenter::copyToUser(const Poco::Path &source, Poco::File file(source); if (!file.exists() || !file.canRead()) { g_log.warning() << "Cannot copy the file " << source.toString() - << " to the user directories because it cannot be read." - << '\n'; + << " to the user directories because it cannot be read.\n"; return; } diff --git a/MantidQt/CustomInterfaces/src/Indirect/IndirectDataReduction.cpp b/MantidQt/CustomInterfaces/src/Indirect/IndirectDataReduction.cpp index 6a4c89da13e..1dd6e8bce7d 100644 --- a/MantidQt/CustomInterfaces/src/Indirect/IndirectDataReduction.cpp +++ b/MantidQt/CustomInterfaces/src/Indirect/IndirectDataReduction.cpp @@ -238,9 +238,8 @@ IndirectDataReduction::loadInstrumentIfNotExist(std::string instrumentName, return instWorkspace; } catch (std::exception &ex) { g_log.warning() << "Failed to load instrument with error: " << ex.what() - << ". The current facility may not be fully supported." - << '\n'; - return MatrixWorkspace_sptr(); + << ". The current facility may not be fully " + "supported.\n" return MatrixWorkspace_sptr(); } } diff --git a/MantidQt/CustomInterfaces/src/MantidEVWorker.cpp b/MantidQt/CustomInterfaces/src/MantidEVWorker.cpp index 3373cd19a29..4b229090001 100644 --- a/MantidQt/CustomInterfaces/src/MantidEVWorker.cpp +++ b/MantidQt/CustomInterfaces/src/MantidEVWorker.cpp @@ -205,7 +205,7 @@ bool MantidEVWorker::loadAndConvertToMD( g_log.error() << "Error:" << e.what() << '\n'; return false; } catch (...) { - g_log.error() << "Error: Could Not load file and convert to MD" << '\n'; + g_log.error() << "Error: Could Not load file and convert to MD\n"; return false; } return true; @@ -822,8 +822,7 @@ bool MantidEVWorker::sphereIntegrate( g_log.error() << "Error:" << e.what() << '\n'; return false; } catch (...) { - g_log.error() << "Error: Could Not Integrated temporary MD workspace" - << '\n'; + g_log.error() << "Error: Could Not Integrated temporary MD workspace\n"; return false; } } @@ -896,8 +895,7 @@ bool MantidEVWorker::fitIntegrate(const std::string &peaks_ws_name, g_log.error() << "Error:" << e.what() << '\n'; return false; } catch (...) { - g_log.error() << "Error: Could Not Integrated temporary FIT workspace" - << '\n'; + g_log.error() << "Error: Could Not Integrated temporary FIT workspace\n"; return false; } return false; diff --git a/MantidQt/CustomInterfaces/src/SANSDiagnostics.cpp b/MantidQt/CustomInterfaces/src/SANSDiagnostics.cpp index b41731a4e73..05d5173b73f 100644 --- a/MantidQt/CustomInterfaces/src/SANSDiagnostics.cpp +++ b/MantidQt/CustomInterfaces/src/SANSDiagnostics.cpp @@ -408,18 +408,16 @@ void SANSDiagnostics::getSpectraList( } catch (std::out_of_range &) { if (detNum == 0) { g_log.error() - << "Error : The instrument does not have any RectangularDetectors " - << '\n'; + << "Error : The instrument does not have any RectangularDetectors \n"; } else if (detNum == 1) { g_log.error() - << "Error : The instrument have only one RectangularDetector" - << '\n'; + << "Error : The instrument have only one RectangularDetector\n"; } return; } if (!rectDet) { - g_log.error() << "Error when accessing the details of rectangular detector" - << '\n'; + g_log.error() + << "Error when accessing the details of rectangular detector\n"; return; } @@ -588,8 +586,7 @@ bool SANSDiagnostics::isValidSpectra(const QString &specMin, spec_max = boost::lexical_cast<int>(specMax.toStdString()); } catch (boost::bad_lexical_cast &) { g_log.error() - << "Inavlid spectrum number found in the selected detector bank " - << '\n'; + << "Inavlid spectrum number found in the selected detector bank \n"; return false; } if (spec_min < 1) { @@ -1230,7 +1227,7 @@ bool SANSDiagnostics::runsumRowColumn(const QString ipwsName, } catch (Exception::NotFoundError &) { g_log.error() << "Error when trying to access the workspace " - << ipwsName.toStdString() << " which is not loaded" << '\n'; + << ipwsName.toStdString() << " which is not loaded\n"; return false; } if (opwsName.isEmpty()) { diff --git a/MantidQt/CustomInterfaces/src/Tomography/ImggFormatsConvertPresenter.cpp b/MantidQt/CustomInterfaces/src/Tomography/ImggFormatsConvertPresenter.cpp index f111bc37ac7..a4fb00fff43 100644 --- a/MantidQt/CustomInterfaces/src/Tomography/ImggFormatsConvertPresenter.cpp +++ b/MantidQt/CustomInterfaces/src/Tomography/ImggFormatsConvertPresenter.cpp @@ -117,7 +117,7 @@ void ImggFormatsConvertPresenter::processConvert() { } else { std::stringstream msg; msg << "No images could be found in input path: " << inPS - << " with format " << inFormat << ". 0 images converted." << '\n'; + << " with format " << inFormat << ". 0 images converted.\n"; g_log.notice() << msg.str(); m_view->userWarning("No images could be found", msg.str()); } diff --git a/MantidQt/MantidWidgets/src/IndirectInstrumentConfig.cpp b/MantidQt/MantidWidgets/src/IndirectInstrumentConfig.cpp index 4450526ae01..bda081dff96 100644 --- a/MantidQt/MantidWidgets/src/IndirectInstrumentConfig.cpp +++ b/MantidQt/MantidWidgets/src/IndirectInstrumentConfig.cpp @@ -177,7 +177,7 @@ void IndirectInstrumentConfig::setInstrument(const QString &instrumentName) { m_instrumentSelector->setCurrentIndex(index); } else { g_log.information() << "Instrument " << instrumentName.toStdString() - << " not found in current list, using default" << '\n'; + << " not found in current list, using default\n"; } } @@ -203,7 +203,7 @@ void IndirectInstrumentConfig::setAnalyser(const QString &analyserName) { m_uiForm.cbAnalyser->setCurrentIndex(index); } else { g_log.information() << "Analyser " << analyserName.toStdString() - << " not found in current list, using default" << '\n'; + << " not found in current list, using default\n"; } } @@ -229,7 +229,7 @@ void IndirectInstrumentConfig::setReflection(const QString &reflectionName) { m_uiForm.cbReflection->setCurrentIndex(index); } else { g_log.information() << "Reflection " << reflectionName.toStdString() - << " not found in current list, using default" << '\n'; + << " not found in current list, using default\n"; } } diff --git a/MantidQt/MantidWidgets/src/InstrumentView/PanelsSurface.cpp b/MantidQt/MantidWidgets/src/InstrumentView/PanelsSurface.cpp index 2c3b516d0cf..32bd39b561a 100644 --- a/MantidQt/MantidWidgets/src/InstrumentView/PanelsSurface.cpp +++ b/MantidQt/MantidWidgets/src/InstrumentView/PanelsSurface.cpp @@ -398,8 +398,8 @@ void PanelsSurface::addObjCompAssemblies(ComponentID bankId) { objCompAssembly->getChild(1)->getPos(); vector.normalize(); if (fabs(vector.scalar_prod(normal)) > Mantid::Kernel::Tolerance) { - g_log.warning() << "Assembly " << assembly->getName() << " isn't flat." - << '\n'; + g_log.warning() << "Assembly " << assembly->getName() + << " isn't flat.\n"; return; } } @@ -455,8 +455,8 @@ void PanelsSurface::addCompAssembly(ComponentID bankId) { x = y.cross_prod(normal); normalFound = true; } else { - g_log.warning() << "Assembly " << assembly->getName() << " isn't flat." - << '\n'; + g_log.warning() << "Assembly " << assembly->getName() + << " isn't flat.\n"; return; } } diff --git a/MantidQt/SpectrumViewer/src/MatrixWSDataSource.cpp b/MantidQt/SpectrumViewer/src/MatrixWSDataSource.cpp index ff27eb8cbd4..3906981dd20 100644 --- a/MantidQt/SpectrumViewer/src/MatrixWSDataSource.cpp +++ b/MantidQt/SpectrumViewer/src/MatrixWSDataSource.cpp @@ -268,8 +268,7 @@ std::vector<std::string> MatrixWSDataSource::getInfoList(double x, double y) { auto det = m_matWs->getDetector(row); if (det == 0) { - g_log.debug() << "No DETECTOR for row " << row << " in MatrixWorkspace" - << '\n'; + g_log.debug() << "No DETECTOR for row " << row << " in MatrixWorkspace\n"; return list; } @@ -341,7 +340,7 @@ std::vector<std::string> MatrixWSDataSource::getInfoList(double x, double y) { } } catch (std::runtime_error &) { g_log.debug() << "Failed to get Efixed from detector ID: " - << det->getID() << " in MatrixWSDataSource" << '\n'; + << det->getID() << " in MatrixWSDataSource\n"; efixed = 0; } } diff --git a/Vates/VatesAPI/src/vtkMDHexFactory.cpp b/Vates/VatesAPI/src/vtkMDHexFactory.cpp index cc290d93d7a..282e1c3d912 100644 --- a/Vates/VatesAPI/src/vtkMDHexFactory.cpp +++ b/Vates/VatesAPI/src/vtkMDHexFactory.cpp @@ -190,8 +190,7 @@ void vtkMDHexFactory::doCreate( } if (VERBOSE) - std::cout << tim << " to create " << imageSizeActual << " hexahedrons." - << '\n'; + std::cout << tim << " to create " << imageSizeActual << " hexahedrons.\n"; } //------------------------------------------------------------------------------------------------- -- GitLab