qt5: Make it compile with '-Werror=shadow'

This fixes the following issue for the GCC build with '-Werror=shadow'
in place which does not show up in the default build setup since
compiler flag '-Wno-shadow' is currently being set in
'RepositoryExternal.mk' for qt5 and kde5.
(This will be dropped in a follow-up commit.)

    .../libreoffice/vcl/qt5/Qt5SvpSurface.cxx: In constructor ‘cairo::Qt5SvpSurface::Qt5SvpSurface(const CairoSurfaceSharedPtr&)’:
    .../libreoffice/vcl/qt5/Qt5SvpSurface.cxx:24:69: error: declaration of ‘m_pSurface’ shadows a member of ‘cairo::Qt5SvpSurface’ [-Werror=shadow]
     Qt5SvpSurface::Qt5SvpSurface(const CairoSurfaceSharedPtr& m_pSurface)
                                                                         ^
    In file included from .../libreoffice/vcl/qt5/Qt5SvpSurface.cxx:12:
    .../libreoffice/vcl/inc/qt5/Qt5SvpSurface.hxx:27:27: note: shadowed declaration is here
         CairoSurfaceSharedPtr m_pSurface;
                               ^~~~~~~~~~
    cc1plus: all warnings being treated as errors

Change-Id: I501657447e02675f7c6b1c9aaca670ba81715590
Reviewed-on: https://gerrit.libreoffice.org/73891
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
This commit is contained in:
Michael Weghorn 2019-06-12 17:07:56 +02:00
parent 1436d2307d
commit cc237438f6

View file

@ -21,10 +21,10 @@
namespace cairo
{
Qt5SvpSurface::Qt5SvpSurface(const CairoSurfaceSharedPtr& m_pSurface)
Qt5SvpSurface::Qt5SvpSurface(const CairoSurfaceSharedPtr& pSurface)
: m_pGraphics(nullptr)
, m_pCairoContext(nullptr)
, m_pSurface(m_pSurface)
, m_pSurface(pSurface)
{
}