mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-25 17:10:23 +00:00
LibDraw: Fix building with clang
This commit is contained in:
parent
f5ecb31fc8
commit
7d06e37a63
Notes:
sideshowbarker
2024-07-19 09:37:50 +09:00
Author: https://github.com/jcs Commit: https://github.com/SerenityOS/serenity/commit/7d06e37a636 Pull-request: https://github.com/SerenityOS/serenity/pull/1177
1 changed files with 10 additions and 0 deletions
|
@ -37,7 +37,17 @@
|
|||
#include <stdio.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#if defined(__GNUC__) && !defined(__clang__)
|
||||
#pragma GCC optimize("O3")
|
||||
#endif
|
||||
|
||||
#ifndef ALWAYS_INLINE
|
||||
#if __has_attribute(always_inline)
|
||||
#define ALWAYS_INLINE __attribute__((always_inline))
|
||||
#else
|
||||
#define ALWAYS_INLINE inline
|
||||
#endif
|
||||
#endif
|
||||
|
||||
template<GraphicsBitmap::Format format = GraphicsBitmap::Format::Invalid>
|
||||
static ALWAYS_INLINE Color get_pixel(const GraphicsBitmap& bitmap, int x, int y)
|
||||
|
|
Loading…
Reference in a new issue