Some fixes for new gcc/clang

Minor fixes for newer gcc/clang. These issues were seen when using ubuntu-latest (Ubuntu 22.04) on Github Actions.
This commit is contained in:
Magne Sjaastad 2022-11-25 08:59:10 +01:00 committed by GitHub
parent 69ccce225c
commit dfa1bc2cd0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
12 changed files with 24 additions and 14 deletions

View File

@ -27,6 +27,10 @@
#ifdef _MSC_VER
#pragma warning( disable : 4996 )
#endif
#ifdef __GNUC__
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------

View File

@ -23,6 +23,9 @@
#ifdef _MSC_VER
#pragma warning( disable : 4996 )
#endif
#ifdef __GNUC__
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
//==================================================================================================
//

View File

@ -26,6 +26,9 @@
#ifdef _MSC_VER
#pragma warning( disable : 4996 )
#endif
#ifdef __GNUC__
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
//--------------------------------------------------------------------------------------------------
///

View File

@ -676,9 +676,6 @@ void RicWellPathExportMswCompletionsImpl::generateFishbonesMswExportInfo(
double maxSegmentLength = enableSegmentSplitting ? mswParameters->maxSegmentLength()
: std::numeric_limits<double>::infinity();
double subStartMD = wellPath->fishbonesCollection()->startMD();
double subStartTVD = RicMswTableFormatterTools::tvdFromMeasuredDepth( branch->wellPath(), subStartMD );
auto unitSystem = exportInfo->unitSystem();
for ( RimFishbones* subs : fishbonesSubs )
@ -808,9 +805,6 @@ void RicWellPathExportMswCompletionsImpl::generateFishbonesMswExportInfo(
segmentOnParentBranch->addCompletion( std::move( icdCompletion ) );
}
}
subStartMD = subEndMD;
subStartTVD = subEndTVD;
}
}
exportInfo->setHasSubGridIntersections( exportInfo->hasSubGridIntersections() || foundSubGridIntersections );

View File

@ -22,6 +22,10 @@
#ifdef _MSC_VER
#pragma warning( disable : 4996 )
#endif
#ifdef __GNUC__
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------

View File

@ -199,7 +199,7 @@ const RifRftSegmentData* RifRftSegment::segmentData( int segmentNumber ) const
//--------------------------------------------------------------------------------------------------
const RifRftSegmentData* RifRftSegment::segmentDataByIndex( int segmentIndex ) const
{
CVF_ASSERT( segmentIndex < m_topology.size() );
CVF_ASSERT( segmentIndex < static_cast<int>( m_topology.size() ) );
return &( m_topology[segmentIndex] );
}

View File

@ -29,6 +29,9 @@
#ifdef _MSC_VER
#pragma warning( disable : 4996 )
#endif
#ifdef __GNUC__
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
CAF_PDM_SOURCE_INIT( RimProcess, "RimProcess" );
@ -146,7 +149,6 @@ bool RimProcess::execute()
QObject::connect( proc, SIGNAL( started() ), m_monitor, SLOT( started() ) );
bool retval = false;
proc->start( cmd );
if ( proc->waitForStarted( -1 ) )
{

View File

@ -2901,7 +2901,7 @@ void RigCaseCellResultsData::computeCompletionTypeForTimeStep( size_t timeStep )
// If permeabilities are generated by calculations, make sure that generated data is calculated
// See RicExportFractureCompletionsImpl::generateCompdatValues()
for ( const QString& propertyName : { "PERMX", "PERMY", "PERMZ" } )
for ( const QString propertyName : { "PERMX", "PERMY", "PERMZ" } )
{
for ( auto userCalculation : RimProject::current()->gridCalculationCollection()->calculations() )
{

View File

@ -99,7 +99,8 @@ private:
SourceAddress( QString primary = "",
QString secondary = "",
QString units = RiaWellLogUnitTools<double>::noUnitString() )
: primary( primary )
: resType( RIG_NODAL )
, primary( primary )
, secondary( secondary )
, units( units )
{

View File

@ -100,8 +100,7 @@ class RiuBarChartScaleDraw : public QwtScaleDraw
public:
struct RiuBarChartTick
{
RiuBarChartTick() = default;
RiuBarChartTick( const RiuBarChartTick& rhs ) = default;
RiuBarChartTick() = default;
RiuBarChartTick( QwtScaleDiv::TickType tickType, const QString& label, bool oppositeSide = false )
: tickType( tickType )
, label( label )

View File

@ -25,7 +25,7 @@ class RiuMdiSubWindow : public QMdiSubWindow
{
Q_OBJECT
public:
RiuMdiSubWindow( QWidget* parent = nullptr, Qt::WindowFlags flags = nullptr );
RiuMdiSubWindow( QWidget* parent = nullptr, Qt::WindowFlags flags = Qt::WindowFlags() );
~RiuMdiSubWindow() override;

View File

@ -58,7 +58,7 @@ public:
const QGLFormat& format,
QWidget* parent,
OpenGLWidget* shareWidget = nullptr,
Qt::WindowFlags f = nullptr );
Qt::WindowFlags f = Qt::WindowFlags() );
OpenGLWidget( OpenGLWidget* shareWidget, QWidget* parent, Qt::WindowFlags f = Qt::WindowFlags() );
cvf::OpenGLContext* cvfOpenGLContext() const;