Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:15.2:Update
chromium.13745
chromium-clang_lto_visibility_public.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File chromium-clang_lto_visibility_public.patch of Package chromium.13745
From 4e380a0e486c080f36adad5b035787d64cfedb3e Mon Sep 17 00:00:00 2001 From: Stephan Hartmann <stha09@googlemail.com> Date: Sat, 27 Jun 2020 13:59:20 +0000 Subject: [PATCH] GCC: fix mixing __attribute__ with C++ attributes GCC does not support mixing __attribute__ with [[...]] attributes. On the other hand [[clang::lto_visibility_public]] isn't supported by GCC and only emits a warning. Therefore define Clang specific attribute and leave it empty for GCC. --- base/compiler_specific.h | 6 ++++++ third_party/blink/renderer/core/frame/frame_view.h | 3 ++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/base/compiler_specific.h b/base/compiler_specific.h index c8a7649..8fd2252 100644 --- a/base/compiler_specific.h +++ b/base/compiler_specific.h @@ -292,4 +292,10 @@ inline constexpr bool AnalyzerAssumeTrue(bool arg) { #endif // defined(__clang_analyzer__) +#if defined(__clang__) +#define LTO_VISIBILITY_PUBLIC [[clang::lto_visibility_public]] +#else +#define LTO_VISIBILITY_PUBLIC +#endif + #endif // BASE_COMPILER_SPECIFIC_H_ diff --git a/third_party/blink/renderer/core/frame/frame_view.h b/third_party/blink/renderer/core/frame/frame_view.h index aa5e42a..ec93d89 100644 --- a/third_party/blink/renderer/core/frame/frame_view.h +++ b/third_party/blink/renderer/core/frame/frame_view.h @@ -5,6 +5,7 @@ #ifndef THIRD_PARTY_BLINK_RENDERER_CORE_FRAME_FRAME_VIEW_H_ #define THIRD_PARTY_BLINK_RENDERER_CORE_FRAME_FRAME_VIEW_H_ +#include "base/compiler_specific.h" #include "third_party/blink/public/mojom/frame/lifecycle.mojom-blink.h" #include "third_party/blink/public/platform/viewport_intersection_state.h" #include "third_party/blink/renderer/core/frame/embedded_content_view.h" @@ -20,7 +21,7 @@ struct IntrinsicSizingInfo; // clang::lto_visibility_public is necessary to prevent the compiler from // performing a vtable optimization that crashes the renderer. See // crbug.com/1062006. -class CORE_EXPORT [[clang::lto_visibility_public]] FrameView +class CORE_EXPORT LTO_VISIBILITY_PUBLIC FrameView : public EmbeddedContentView { public: FrameView(const IntRect& frame_rect) : EmbeddedContentView(frame_rect) {} -- 2.26.2
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor