Browse Source

Silence override warnings on recent GCC

pcb_db
Jon Evans 11 months ago
parent
commit
07bd497d9c
  1. 22
      pcbnew/pcb_track.cpp
  2. 6
      pcbnew/pcb_track.h

22
pcbnew/pcb_track.cpp

@ -227,6 +227,17 @@ bool PCB_ARC::operator==( const BOARD_ITEM& aBoardItem ) const
}
bool PCB_ARC::operator==( const PCB_TRACK& aOther ) const
{
if( aOther.Type() != Type() )
return false;
const PCB_ARC& other = static_cast<const PCB_ARC&>( aOther );
return *this == other;
}
bool PCB_ARC::operator==( const PCB_ARC& aOther ) const
{
return m_Start == aOther.m_Start
@ -284,6 +295,17 @@ bool PCB_VIA::operator==( const BOARD_ITEM& aBoardItem ) const
}
bool PCB_VIA::operator==( const PCB_TRACK& aOther ) const
{
if( aOther.Type() != Type() )
return false;
const PCB_VIA& other = static_cast<const PCB_VIA&>( aOther );
return *this == other;
}
bool PCB_VIA::operator==( const PCB_VIA& aOther ) const
{
return m_Start == aOther.m_Start

6
pcbnew/pcb_track.h

@ -357,6 +357,9 @@ protected:
virtual void swapData( BOARD_ITEM* aImage ) override;
private:
// Silence GCC warning about overriding the base class method
bool operator==( const PCB_TRACK& aOther ) const override;
VECTOR2I m_Mid; ///< Arc mid point, halfway between start and end
};
@ -657,6 +660,9 @@ protected:
wxString layerMaskDescribe() const override;
private:
// Silence GCC warning about hiding the PCB_TRACK base method
bool operator==( const PCB_TRACK& aOther ) const override;
VIATYPE m_viaType; ///< through, blind/buried or micro
PADSTACK m_padStack;

Loading…
Cancel
Save