• Stephan Bergmann's avatar
    Avoid unhelpful -Wunused-variable · e2618814
    Stephan Bergmann yazdı
    ...at least from "g++ (GCC) 5.1.1 20150618 (Red Hat 5.1.1-4)" with
    --disable-debug, when a namespace-scope const variable with a "complex"
    initializer declared in an include file remains unused.
    
    Avoid that warning via SAL_CONSTEXPR, which in turn requires large parts of
    o3tl::is_typed_flags to be SAL_CONSTEXPR, which in turn requires a new
    HAVE_CXX14_CONSTEXPR to allow assert in constexpr functions, which in turn
    requires using -std=c++14 instead of -std=c++11 where available, which in turn
    (a) requires to /not/ use -std=c++14 if it would run into a bug between Clang
    and libstdc++ discussed at <https://llvm.org/bugs/show_bug.cgi?id=24115>
    "llvm-nm fails to build with gcc 5.1's libstdc++" (and which hits us in
    sfx2/source/control/thumbnailview.cxx), and (b) requires a new
    HAVE_CXX14_SIZED_DEALLOCATION to work around GCC 5.1 -Werror=sized-deallocation
    (where Clang >= 3.7 only supports C++14 sized deallocation when explictly
    enabled via -fsized-deallocation, btw).
    
    This effectively reverts ff6462e6 "avoid unused
    variable warning:" again.
    
    Change-Id: I424e3561452a3e6d8c8a9604d6c737cab49840c4
    Reviewed-on: https://gerrit.libreoffice.org/18918Reviewed-by: 's avatarStephan Bergmann <sbergman@redhat.com>
    Tested-by: 's avatarStephan Bergmann <sbergman@redhat.com>
    e2618814
Adı
Son kayıt (commit)
Son güncelleme
..
.gitignore Loading commit data...
README Loading commit data...
config_buildid.h.in Loading commit data...
config_cairo_canvas.h.in Loading commit data...
config_clang.h.in Loading commit data...
config_cups.h.in Loading commit data...
config_dconf.h.in Loading commit data...
config_eot.h.in Loading commit data...
config_extension_update.h.in Loading commit data...
config_features.h.in Loading commit data...
config_folders.h.in Loading commit data...
config_gcc.h.in Loading commit data...
config_global.h.in Loading commit data...
config_graphite.h.in Loading commit data...
config_java.h.in Loading commit data...
config_kde4.h.in Loading commit data...
config_lgpl.h.in Loading commit data...
config_liblangtag.h.in Loading commit data...
config_locales.h.in Loading commit data...
config_mingw.h.in Loading commit data...
config_mpl.h.in Loading commit data...
config_oauth2.h.in Loading commit data...
config_oox.h.in Loading commit data...
config_opengl.h.in Loading commit data...
config_options.h.in Loading commit data...
config_orcus.h.in Loading commit data...
config_poppler.h.in Loading commit data...
config_probes.h.in Loading commit data...
config_python.h.in Loading commit data...
config_telepathy.h.in Loading commit data...
config_test.h.in Loading commit data...
config_typesizes.h.in Loading commit data...
config_vcl.h.in Loading commit data...
config_vclplug.h.in Loading commit data...
config_version.h.in Loading commit data...