[Webkit-unassigned] [Bug 230795] Add implementation for CSSNumericValue math functions
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed Nov 24 20:45:50 PST 2021
https://bugs.webkit.org/show_bug.cgi?id=230795
--- Comment #14 from Qiaosong Zhou <johnson.zhou.sh at icloud.com> ---
(In reply to Simon Fraser (smfr) from comment #11)
> Comment on attachment 445099 [details]
>
> > Source/WebCore/css/typedom/CSSNumericValue.h:55
> > Ref<CSSNumericValue> add(Vector<CSSNumberish>&&);
> > Ref<CSSNumericValue> sub(Vector<CSSNumberish>&&);
> > Ref<CSSNumericValue> mul(Vector<CSSNumberish>&&);
> > - Ref<CSSNumericValue> div(Vector<CSSNumberish>&&);
> > + ExceptionOr<Ref<CSSNumericValue>> div(Vector<CSSNumberish>&&);
> > Ref<CSSNumericValue> min(Vector<CSSNumberish>&&);
> > Ref<CSSNumericValue> max(Vector<CSSNumberish>&&);
>
> I think these should all be const functions, right? They don't change the
> value of |this|. Ideally we'd name them something different to make this
> more clear, but this naming matches the spec.
>
> > Source/WebCore/css/typedom/CSSNumericValue.h:69
> > + Ref<CSSNumericValue> addImpl(Vector<Ref<CSSNumericValue>>&&);
> > + Ref<CSSNumericValue> mulImpl(Vector<Ref<CSSNumericValue>>&&);
>
> Can these be const?
I can't seem to make them const because I'm converting *this into a Ref that is then prepended into the Vector.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20211125/2a0a1663/attachment-0001.htm>
More information about the webkit-unassigned
mailing list