Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-3610

Code completion for nested struct/unions

    XMLWordPrintable

Details

    • 080bf4ecb8b7b70d6410e3342e37dacd5aef8ff3

    Description

      I just did a test with Qt Creator 2.0.94 (2.1.0-rc1) Linux and there is still a problem with completing nested structs/union (see attached picture).

      Thanks in advance.

      #include "mainwindow.h"
      #include "ui_mainwindow.h"
      
      typedef union {
      	int Word;
      	struct {
      		int Test1: 1;
      		int Test2: 1;
      		int Test3: 1;
      		int Test4: 1;
      	} Bit;
      } TTestUnion;
      
      MainWindow::MainWindow(QWidget *parent) :
      	QMainWindow(parent),
      	ui(new Ui::MainWindow)
      {
      	ui->setupUi(this);
      }
      
      MainWindow::~MainWindow()
      {
      	delete ui;
      }
      
      void MainWindow::on_pushButton_clicked()
      {
      	TTestUnion tu;
      
      	tu.Bit.Test1 = 1;
      }
      

      Attachments

        1. creator21rc.png
          creator21rc.png
          68 kB
        2. test.png
          test.png
          86 kB

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              erikv Erik Verbruggen
              aha_1980 André Hartmann
              Votes:
              2 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes