Commit eeeb3814 authored by Chris Cantwell's avatar Chris Cantwell

Merge branch 'master' into feature/documentation-updates

parents 8e7b2f73 cefef744
Pipeline #1112 skipped with stage
......@@ -80,7 +80,11 @@ MACRO(SET_COMMON_PROPERTIES name)
TARGET_COMPILE_DEFINITIONS(${name} PRIVATE _WIN32_WINNT=0x0601)
ELSE ()
# Enable all warnings
TARGET_COMPILE_OPTIONS(${name} PRIVATE -Wpedantic -Wall -Wextra)
TARGET_COMPILE_OPTIONS(${name} PRIVATE -Wall -Wextra)
IF (CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
# For GNU compilers add pedantic warnings
TARGET_COMPILE_OPTIONS(${name} PRIVATE -Wpedantic)
ENDIF()
# Temporarily disable warnings about comparing signed and unsigned
TARGET_COMPILE_OPTIONS(${name} PRIVATE -Wno-sign-compare)
# Temporarily disable warnings about narrowing of data types
......@@ -88,6 +92,12 @@ MACRO(SET_COMMON_PROPERTIES name)
IF (NOT CMAKE_CXX_COMPILER_ID MATCHES "Clang")
TARGET_COMPILE_OPTIONS(${name} PRIVATE -fpermissive)
ENDIF()
# Disable dignostic about partially overloaded virtual functions
IF (CMAKE_CXX_COMPILER_ID STREQUAL "Intel")
TARGET_COMPILE_OPTIONS(${name} PRIVATE -diag-disable 654)
ENDIF()
IF ( NEKTAR_ERROR_ON_WARNINGS )
TARGET_COMPILE_OPTIONS(${name} PRIVATE -Werror)
ENDIF()
......
......@@ -92,8 +92,9 @@ void OutputInfo::Process(po::variables_map &vm)
{
boost::format pad("P%1$07d.%2$s");
pad % p % "fld";
std::string s = pad.str();
fs::path fullpath = pinfilename / pad.str();
fs::path fullpath = pinfilename / s;
string fname = LibUtilities::PortablePath(fullpath);
LibUtilities::DataSourceSharedPtr dataSource =
LibUtilities::XmlDataSource::create(fname);
......@@ -114,7 +115,7 @@ void OutputInfo::Process(po::variables_map &vm)
}
ElementIDs.push_back(PartElmtIDs);
filenames.push_back(pad.str());
filenames.push_back(s);
}
// Write the Info.xml file
......
......@@ -131,13 +131,17 @@ namespace Nektar
/// This operator performs range checking.
typename boost::call_traits<DataType>::reference operator()(unsigned int i)
{
ASSERTL0( (i>=0) && (i<dim::Value), "Invalid access to NekPoint data via parenthesis operator: index out of range");
ASSERTL0(i < dim::Value,
"Invalid access to NekPoint data via parenthesis "
"operator: index out of range");
return m_data[i];
}
typename boost::call_traits<DataType>::const_reference operator()(unsigned int i) const
{
ASSERTL0( (i>=0) && (i<dim::Value), "Invalid access to NekPoint data via parenthesis operator: index out of range");
ASSERTL0(i < dim::Value,
"Invalid access to NekPoint data via parenthesis "
"operator: index out of range");
return m_data[i];
}
......
......@@ -250,7 +250,8 @@ namespace Nektar
template<typename DataType>
typename boost::call_traits<DataType>::reference NekVector<DataType>::operator()(unsigned int i)
{
ASSERTL1((i >= 0) && (i < this->GetDimension()), "Invalid access to m_data via parenthesis operator");
ASSERTL1(i < this->GetDimension(),
"Invalid access to m_data via parenthesis operator");
return this->GetData()[i];
}
......@@ -336,7 +337,8 @@ namespace Nektar
template<typename DataType>
typename boost::call_traits<DataType>::const_reference NekVector<DataType>::operator()(unsigned int i) const
{
ASSERTL1(( i >= 0) && (i < GetDimension()), "Invalid access to m_data via parenthesis operator");
ASSERTL1(i < GetDimension(),
"Invalid access to m_data via parenthesis operator");
return m_data[i];
}
......
......@@ -202,7 +202,7 @@ void MeshGraphXml::PartitionMesh(
vector<set<unsigned int>> elmtIDs;
vector<unsigned int> parts(nParts);
for (int i = 0; i < nParts; ++i)
for (i = 0; i < nParts; ++i)
{
vector<unsigned int> elIDs;
set<unsigned int> tmp;
......
......@@ -906,7 +906,7 @@ void MeshGraphXmlCompressed::ReadElements3D()
Nqfaces++;
}
}
ASSERTL0((Ntfaces == 4) && (Nqfaces = 1),
ASSERTL0((Ntfaces == 4) && (Nqfaces == 1),
"Did not identify the correct number of "
"triangular and quadrilateral faces for a "
"pyramid");
......@@ -952,7 +952,7 @@ void MeshGraphXmlCompressed::ReadElements3D()
Nqfaces++;
}
}
ASSERTL0((Ntfaces == 2) && (Nqfaces = 3),
ASSERTL0((Ntfaces == 2) && (Nqfaces == 3),
"Did not identify the correct number of "
"triangular and quadrilateral faces for a "
"prism");
......
......@@ -256,7 +256,7 @@ void OUTPUT(int m_xpoints,
Array <OneD, NekDouble > test (m_xpoints, 0.0);
NekDouble dd, dm, scale, flg;
NekDouble dd, dm, scale;
NekDouble xcher, ycher;
int index = -1;
......@@ -269,11 +269,6 @@ void OUTPUT(int m_xpoints,
dm = ff[3][i-1] - ff[1][i-1];
dd = ff[3][i] - ff[1][i];
sumd = sumd + 0.5 * (xx[i] - xx[i-1]) * (dd + dm);
if ((ff[1][i] > 0.999) && (flg < 1.0))
{
flg = 2.0;
}
}
scale = sumd;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment