Bug 303504
| Summary: | REGRESSION(303805@main) GCC 12 build broken as the new generated RenderStyle::display() is not constexpr | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Lauro Moura <lmoura> |
| Component: | WebCore Misc. | Assignee: | Nobody <webkit-unassigned> |
| Status: | RESOLVED DUPLICATE | ||
| Severity: | Normal | CC: | bugs-noreply, sam |
| Priority: | P2 | ||
| Version: | WebKit Nightly Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Bug Depends on: | 303398 | ||
| Bug Blocks: | |||
Lauro Moura
The GCC 12 stable bots for WPE and GTK broke after 303805@main with the following error:
```
In file included from ../../../Source/WebCore/rendering/style/RenderStyleSetters.h:29,
from WebCore/DerivedSources/StyleBuilderGenerated.cpp:8,
from WebCore/DerivedSources/unified-sources/UnifiedSource-3a52ce78-198.cpp:8:
../../../Source/WebCore/rendering/style/RenderStyleInlines.h: In member function ‘constexpr bool WebCore::RenderStyle::isDisplayRegionType() const’:
../../../Source/WebCore/rendering/style/RenderStyleInlines.h:228:19: error: call to non-‘constexpr’ function ‘WebCore::DisplayType WebCore::RenderStyle::display() const’
228 | return display() == DisplayType::Block
| ~~~~~~~^~
In file included from ../../../Source/WebCore/rendering/style/RenderStyleInlines.h:70:
WebCore/PrivateHeaders/WebCore/RenderStyleInlinesGenerated.h:63:20: note: ‘WebCore::DisplayType WebCore::RenderStyle::display() const’ declared here
63 | inline DisplayType RenderStyle::display() const
| ^~~~~~~~~~~
../../../Source/WebCore/rendering/style/RenderStyleInlines.h: In member function ‘constexpr bool WebCore::RenderStyle::doesDisplayGenerateBlockContainer() const’:
../../../Source/WebCore/rendering/style/RenderStyleInlines.h:270:33: error: call to non-‘constexpr’ function ‘WebCore::DisplayType WebCore::RenderStyle::display() const’
270 | auto display = this->display();
| ~~~~~~~~~~~~~^~
<snip long list>
```
As commented by Claudio in the PR[1] earlier today, this is happening because `RenderStyle::display()` lost the constexpr tag as this method is now generated:
```
- constexpr DisplayType display() const { return static_cast<DisplayType>(m_nonInheritedFlags.effectiveDisplay); }
+ inline DisplayType display() const;
```
[1] https://github.com/WebKit/WebKit/pull/54710#pullrequestreview-3534814541
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Lauro Moura
*** This bug has been marked as a duplicate of bug 303398 ***