Bug 122184 - void is imported as class and not datatypes
Summary: void is imported as class and not datatypes
Status: RESOLVED FIXED
Alias: None
Product: umbrello
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR wishlist
Target Milestone: ---
Assignee: Umbrello Development Group
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-02-17 22:06 UTC by Yan Morin
Modified: 2006-02-18 20:41 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Yan Morin 2006-02-17 22:07:00 UTC
Version:           1.5.2 (using KDE KDE 3.5.1)
Installed from:    Compiled From Sources
OS:                Linux

When I import a .h from a C++ project in a umbrello, it creates a 'void' class and not the 'void' DataType. I don't know how I could use a void class ;p
Comment 1 Oliver Kellogg 2006-02-18 20:41:15 UTC
SVN commit 511080 by okellogg:

insertMethod(): Don't set the return type if it is "void".
BUG:122184


 M  +2 -1      import_utils.cpp  


--- branches/KDE/3.5/kdesdk/umbrello/umbrello/import_utils.cpp #511079:511080
@@ -268,7 +268,8 @@
                                bool isFriend, bool isConstructor,
                                QString comment) {
     op->setVisibility(scope);
-    if (!type.isEmpty()) {  // return type may be missing (constructor/destructor)
+    if (!type.isEmpty()     // return type may be missing (constructor/destructor)
+        && type != "void") {
         if (type == klass->getName()) {
             op->setType(klass);
         } else {