<div dir="ltr"><div>> I think we then had discussions when moving from Qt 4 to Qt 5, that we will start requiring RTTI.</div><div><br></div><div>However this was never promoted, and now you're saying people who ported their projects with no-rtti to Qt5 had to enable rtti years ago or expect crashes?)</div><div><br></div><div>Thanks to Alberto for pointing this issue now, when the majority didn't switch to the new LTS yet.<br></div><div>I, for example, didn't know the issue with dynamic_cast across dll boundaries is not an issue anymore.</div><div><br></div><div>Plz make sure the documentation is up to date and `CONFIG += rtti_off` does nothing as of 5.15.</div><div></div><br clear="all"><div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature">Regards,<br>Konstantin</div></div><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">вс, 21 июн. 2020 г. в 14:23, Lars Knoll <<a href="mailto:lars.knoll@qt.io">lars.knoll@qt.io</a>>:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br>
<br>
> On 21 Jun 2020, at 13:10, Giuseppe D'Angelo via Development <<a href="mailto:development@qt-project.org" target="_blank">development@qt-project.org</a>> wrote:<br>
> <br>
> Il 20/06/20 22:45, Thiago Macieira ha scritto:<br>
>> On Saturday, 20 June 2020 11:31:25 PDT Alberto Mardegan wrote:<br>
>>> I think I missed an announcement about Qt applications having to use<br>
>>> RTTI; on the opposite, I thought that the whole point of QMetaObject was<br>
>>> not to require RTTI support; has this changed?<br>
>> As you can see from the commit, no provision was made for no-RTTI builds. I<br>
>> don't think they've ben allowed since 5.0.<br>
> <br>
> The Qt coding policy document still says that no RTTI facilities are allowed within Qt:<br>
> <br>
>> <a href="https://wiki.qt.io/Coding_Conventions" rel="noreferrer" target="_blank">https://wiki.qt.io/Coding_Conventions</a><br>
> <br>
> (Unchanged since 2015; before, I'm sure that document was somewhere else, with the same contents regarding this matter.)<br>
> <br>
> Where/when was such a change of policy decided?<br>
<br>
We didn’t want it in earlier versions of Qt for mainly two reasons. Early implementations had quite an overhead on library size, and dynamic_cast didn’t work reliable between DLL boundaries on Windows. Both problems have gone away many years ago.<br>
<br>
I have to go by what I remember now, but I think we then had discussions when moving from Qt 4 to Qt 5, that we will start requiring RTTI. The reasons where that dynamic_cast<> and typeid require it and it has very little overhead on library size (as opposed to exceptions which are still optional). By that time (or maybe even earlier), we also started compiling Qt with RTTI enabled on all platforms.<br>
<br>
But it looks like nobody ever adjusted the wiki page :/<br>
<br>
We are making use of dynamic_cast and typeid in Qt nowadays, so I guess it’s high time we adjust the wiki.<br>
<br>
Cheers,<br>
Lars<br>
<br>
_______________________________________________<br>
Development mailing list<br>
<a href="mailto:Development@qt-project.org" target="_blank">Development@qt-project.org</a><br>
<a href="https://lists.qt-project.org/listinfo/development" rel="noreferrer" target="_blank">https://lists.qt-project.org/listinfo/development</a><br>
</blockquote></div>