diff options
author | Andreas Kling <awesomekling@gmail.com> | 2019-02-25 12:43:52 +0100 |
---|---|---|
committer | Andreas Kling <awesomekling@gmail.com> | 2019-02-25 12:43:52 +0100 |
commit | 2cfcbdc735e7578a22ed2f9ae25492a72abe3f3f (patch) | |
tree | ffbb4403f13fe7d105951e965180638907f3662d /SharedGraphics/GraphicsBitmap.cpp | |
parent | 0b957ed2b1cd6b4949c93c5b39b64b0caf060c12 (diff) | |
download | serenity-2cfcbdc735e7578a22ed2f9ae25492a72abe3f3f.zip |
AK: Add Retained<T>, like RetainPtr, but never null.
Also use some Clang attribute wizardry to get a warning for use-after-move.
Diffstat (limited to 'SharedGraphics/GraphicsBitmap.cpp')
-rw-r--r-- | SharedGraphics/GraphicsBitmap.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/SharedGraphics/GraphicsBitmap.cpp b/SharedGraphics/GraphicsBitmap.cpp index 40f25ee697..035f17e9a4 100644 --- a/SharedGraphics/GraphicsBitmap.cpp +++ b/SharedGraphics/GraphicsBitmap.cpp @@ -5,7 +5,7 @@ #include <errno.h> #include <stdio.h> -RetainPtr<GraphicsBitmap> GraphicsBitmap::create(Format format, const Size& size) +Retained<GraphicsBitmap> GraphicsBitmap::create(Format format, const Size& size) { return adopt(*new GraphicsBitmap(format, size)); } @@ -22,7 +22,7 @@ GraphicsBitmap::GraphicsBitmap(Format format, const Size& size) m_mmaped = true; } -RetainPtr<GraphicsBitmap> GraphicsBitmap::create_wrapper(Format format, const Size& size, RGBA32* data) +Retained<GraphicsBitmap> GraphicsBitmap::create_wrapper(Format format, const Size& size, RGBA32* data) { return adopt(*new GraphicsBitmap(format, size, data)); } |