<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Assert in QTabWidgwt]]></title><description><![CDATA[<p dir="auto">Use QTableWidget like this (Qt6.8.3  msvc2022_64):</p>
<p dir="auto">#include &lt;qapplication.h&gt;<br />
#include &lt;QtWidgets/QHBoxLayout&gt;<br />
#include &lt;QtWidgets/QTreeWidget&gt;</p>
<p dir="auto">class TestWidget : public QWidget<br />
{<br />
public:<br />
TestWidget(QWidget* pParent = nullptr)<br />
: QWidget(pParent)<br />
{<br />
QHBoxLayout* mainLayout = new QHBoxLayout(this);<br />
auto* m_pTabWidget = new QTabWidget(this);<br />
mainLayout-&gt;addWidget(m_pTabWidget);<br />
QWidget* pTabDocWidget = new QWidget(m_pTabWidget);<br />
m_pTabWidget-&gt;addTab(pTabDocWidget, QString("aaa"));<br />
}<br />
};</p>
<p dir="auto">int main(int argc, char* argv[])<br />
{<br />
QApplication app(argc, argv);<br />
TestWidget wid;<br />
wid.show();<br />
return app.exec();<br />
}</p>
<p dir="auto">An assert occourred in Debug Mode at  "m_pTabWidget-&gt;addTab(pTabDocWidget, QString("aaa"));"  ,  release mode is ok.</p>
<p dir="auto">this is the callstack:<br />
<img src="https://ddgobkiprc33d.cloudfront.net/2e2b33bf-ba80-47f6-8a29-4252d9ed4a62.png" alt="d08fc456-901e-4b04-853b-4b4439a723ee-image.png" class=" img-fluid img-markdown" /></p>
<p dir="auto">Is there any problem with my codes ?</p>
]]></description><link>https://forum.qt.io/topic/164858/assert-in-qtabwidgwt</link><generator>RSS for Node</generator><lastBuildDate>Tue, 14 Jul 2026 08:17:56 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/164858.rss" rel="self" type="application/rss+xml"/><pubDate>Sun, 05 Jul 2026 12:54:29 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Assert in QTabWidgwt on Sat, 11 Jul 2026 12:19:28 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/sgaist">@<bdi>SGaist</bdi></a> said in <a href="/post/839081">Assert in QTabWidgwt</a>:</p>
<blockquote>
<p dir="auto">It's not your code that is doubted, it is whether there is a mix between your application being built in release mode but using debug libraries when running or vice versa. Can you check whether you are using the libraries matching your application build type ?</p>
</blockquote>
<p dir="auto">I use CMAKE to manage the dependencies, and do not add any lib manually. This issue just happened in Debug mode. I check (by my IDE ,  visual studio 2026 )  all  libs used in my project , all  of them are Debug mode. And i also check the libs in "Install directory",  there is no problem either. I start the exe ( double click ) in install directory,  it also  has runtime crash with the message box "Debug error! xxx.exe abort() has been called ".</p>
]]></description><link>https://forum.qt.io/post/839102</link><guid isPermaLink="true">https://forum.qt.io/post/839102</guid><dc:creator><![CDATA[Shayne]]></dc:creator><pubDate>Sat, 11 Jul 2026 12:19:28 GMT</pubDate></item><item><title><![CDATA[Reply to Assert in QTabWidgwt on Fri, 10 Jul 2026 08:55:32 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/shayne">@<bdi>Shayne</bdi></a> Hi,</p>
<p dir="auto">It's not your code that is doubted, it is whether there is a mix between your application being built in release mode but using debug libraries when running or vice versa. Can you check whether you are using the libraries matching your application build type ?</p>
]]></description><link>https://forum.qt.io/post/839081</link><guid isPermaLink="true">https://forum.qt.io/post/839081</guid><dc:creator><![CDATA[SGaist]]></dc:creator><pubDate>Fri, 10 Jul 2026 08:55:32 GMT</pubDate></item><item><title><![CDATA[Reply to Assert in QTabWidgwt on Fri, 10 Jul 2026 06:39:42 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/christian-ehrlicher">@<bdi>Christian-Ehrlicher</bdi></a> said in <a href="/post/839015">Assert in QTabWidgwt</a>:</p>
<blockquote>
<p dir="auto">Your code is correct. Either you’re mixing debug and release libraries together (for example, compiling your app in release mode but using debug Qt libraries), or you’re not showing the entire code.</p>
</blockquote>
<p dir="auto">That’s all my code above. I encountered this issue in my project using Qt 6.7.2 (compiled by myself). I simplified the code as shown above, but the issue still persists. I think it may be a bug of qt, so i  install an official release version of qt 6.8.3 and try again,  but the  issue still exists.</p>
]]></description><link>https://forum.qt.io/post/839079</link><guid isPermaLink="true">https://forum.qt.io/post/839079</guid><dc:creator><![CDATA[Shayne]]></dc:creator><pubDate>Fri, 10 Jul 2026 06:39:42 GMT</pubDate></item><item><title><![CDATA[Reply to Assert in QTabWidgwt on Sun, 05 Jul 2026 13:49:29 GMT]]></title><description><![CDATA[<p dir="auto">Your code above is correct so you either mix debug and release libraries (e.g. you compile your app in release mode but using debug Qt libs) or you don't show your full code.</p>
]]></description><link>https://forum.qt.io/post/839015</link><guid isPermaLink="true">https://forum.qt.io/post/839015</guid><dc:creator><![CDATA[Christian Ehrlicher]]></dc:creator><pubDate>Sun, 05 Jul 2026 13:49:29 GMT</pubDate></item></channel></rss>