From 00a1cc83eccc357c96c347abba28d53ce6395789 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Thu, 26 Nov 2020 08:29:35 +0100 Subject: shiboken6: Fix generation of protected enums without protected hack The cast was no longer generated due to a bug in Amends3ec934419b1217e2a623e2f91336a8a5628ec5fe. Change-Id: I27bb554ae24bedf2625654409d8b9b365b47c3c1 Reviewed-by: Cristian Maureira-Fredes --- sources/shiboken6/generator/shiboken/cppgenerator.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sources/shiboken6/generator/shiboken/cppgenerator.cpp b/sources/shiboken6/generator/shiboken/cppgenerator.cpp index edf6bb4a4..d4aa6d242 100644 --- a/sources/shiboken6/generator/shiboken/cppgenerator.cpp +++ b/sources/shiboken6/generator/shiboken/cppgenerator.cpp @@ -3656,6 +3656,8 @@ void CppGenerator::writeMethodCall(TextStream &s, const AbstractMetaFunction *fu enumName = func->type().cppSignature(); const QString methodCall = enumName + QLatin1Char('(') + mc.toString() + QLatin1Char(')'); + mc.clear(); + mc << methodCall; s << enumName; writeReturnType = false; } -- cgit v1.2.3