[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: New santizer warning in KF 5.98 headers
From:       Michael Reeves <reeves.87 () gmail ! com>
Date:       2023-01-11 19:49:52
Message-ID: CANp6eRkFdA2Swn8A50+rc0YzC5vBQKWhyRUUbunze1gAcfKQ4g () mail ! gmail ! com
[Download RAW message or body]

That looks a lot better. Weird magic numbers are what enums are ment to
avoid.

On Wed, Jan 11, 2023 at 7:26 AM Nicolas Fella <nicolas.fella@gmx.de> wrote:

> On 1/10/23 22:49, Michael Reeves wrote:
> > /usr/include/KF5/KConfigWidgets/kstandardaction.h:261:64: runtime
> > error: load of value 4294967295, which is not a valid value for type
> > 'Qt::ConnectionType'
> >
> > SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior
> > /usr/include/KF5/KConfigWidgets/kstandardaction.h:261:64 in
> >
> > The issue stems for assigning an int to a enum which is internally
> > considered unsigned and possibly smaller than the four byte int. If
> > this is doing what we expect than I need a way to shut off the warning.
> Looks like
> https://invent.kde.org/frameworks/kconfigwidgets/-/merge_requests/175
> aims to address this?
>

[Attachment #3 (text/html)]

<div dir="ltr">That looks a lot better. Weird magic numbers are what enums are ment \
to avoid.<br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On \
Wed, Jan 11, 2023 at 7:26 AM Nicolas Fella &lt;<a \
href="mailto:nicolas.fella@gmx.de">nicolas.fella@gmx.de</a>&gt; \
wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px \
0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 1/10/23 22:49, \
Michael Reeves wrote:<br> &gt; \
/usr/include/KF5/KConfigWidgets/kstandardaction.h:261:64: runtime<br> &gt; error: \
load of value 4294967295, which is not a valid value for type<br> &gt; \
&#39;Qt::ConnectionType&#39;<br> &gt;<br>
&gt; SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior<br>
&gt; /usr/include/KF5/KConfigWidgets/kstandardaction.h:261:64 in<br>
&gt;<br>
&gt; The issue stems for assigning an int to a enum which is internally<br>
&gt; considered unsigned and possibly smaller than the four byte int. If<br>
&gt; this is doing what we expect than I need a way to shut off the warning.<br>
Looks like<br>
<a href="https://invent.kde.org/frameworks/kconfigwidgets/-/merge_requests/175" \
rel="noreferrer" target="_blank">https://invent.kde.org/frameworks/kconfigwidgets/-/merge_requests/175</a><br>
 aims to address this?<br>
</blockquote></div>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic