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

List:       kde-bindings
Subject:    [Kde-bindings] [smokegen] generators/smoke: QFlags references are valid unless they are return types
From:       Arno Rehn <arno () arnorehn ! de>
Date:       2012-06-10 20:31:02
Message-ID: 20120610203102.1BA1BA60C9 () git ! kde ! org
[Download RAW message or body]

Git commit 7b67ac626f27e1d405ab92a2d2a8bb91ffa98c2d by Arno Rehn.
Committed on 10/06/2012 at 22:27.
Pushed by arnorehn into branch 'master'.

QFlags references are valid unless they are return types of field
accessors.

Fixes compilation of smokekde.

CCMAIL: kde-bindings@kde.org

M  +1    -1    generators/smoke/helpers.cpp

http://commits.kde.org/smokegen/7b67ac626f27e1d405ab92a2d2a8bb91ffa98c2d

diff --git a/generators/smoke/helpers.cpp b/generators/smoke/helpers.cpp
index b15791d..4fb2c98 100644
--- a/generators/smoke/helpers.cpp
+++ b/generators/smoke/helpers.cpp
@@ -609,7 +609,7 @@ void Util::addAccessorMethods(const Field& field, QSet<Type*> \
*usedTypes)  {
     Class* klass = field.getClass();
     Type* type = field.type();
-    if (type->getClass() && type->pointerDepth() == 0) {
+    if (type->getClass() && type->pointerDepth() == 0 && !(ParserOptions::qtMode && \
type->getClass()->name() == "QFlags")) {  Type newType = *type;
         newType.setIsRef(true);
         type = Type::registerType(newType);
_______________________________________________
Kde-bindings mailing list
Kde-bindings@kde.org
https://mail.kde.org/mailman/listinfo/kde-bindings


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

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