mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-03 15:16:14 +00:00
LibJS+LibWeb: Return non-const types from Ptr class operators
Even if the pointer value is const, the value they point to is not necessarily const, so these functions should not add the qualifier. This also removes the redundant non-const implementations of these operators.
This commit is contained in:
@@ -121,7 +121,7 @@ WebIDL::ExceptionOr<void> CanvasRenderingContext2D::draw_image_internal(CanvasIm
|
||||
if (usability == CanvasImageSourceUsability::Bad)
|
||||
return {};
|
||||
|
||||
auto const* bitmap = image.visit([](auto const& source) { return source->bitmap(); });
|
||||
auto const* bitmap = image.visit([](auto const& source) -> Gfx::Bitmap const* { return source->bitmap(); });
|
||||
if (!bitmap)
|
||||
return {};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user