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

List:       kde-core-devel
Subject:    Re: kdialogbase.h
From:       Espen Sand <espensa () online ! no>
Date:       2000-08-12 8:36:47
[Download RAW message or body]

On Sat, 12 Aug 2000,  Harri Porten wrote:
> Package: kdelibs
> Version: CVS 20000812
> 
> Thomas Leitner reported a warning issued by his compiler when including
> kdialogbase.h.
> 
> > Here's a small annoyance with QT 2.2 beta 1 and the Compaq C++ Compiler
> > under Tru64 (osf1-cxx-shared config):
> > 
> > cxx -DHAVE_CONFIG_H -I. -I. -I.. -I../dcop -I../kdecore -I../kdeui
> > -I/home6/kde2d/qt-copy/include -I. -I/usr/local/kde2/include
> > -I/usr/local/include -std gnu -O2 -DAES_SOURCE -D__USE_STD_IOSTREAM
> > -D__STDC__=1 -D__DECC__ -I /home6/kde2d/cxxinc -DQT_CLEAN_NAMESPACE
> > -DQT_NO_COMPAT -DQT_NO_ASCII_CAST -c kpassdlg.cpp   -DPIC -o
> > .libs/kpassdlg.o
> > cxx: Warning: /home6/kde2d/qt-copy/include/qlist.h, line 94: delete of
> > pointer to incomplete class detected during instantiation of 
> > "void QList<type>::deleteItem(QCollection::Item) [with type=KDialogBaseButton]" 
> >     if ( del_item ) delete (type *)d;
> > ---------------------------^
> 
> I don't know how serious this is (or will be with future compilers) but
> it might be worthwile fixing it. The problem stems from a
> QList<KDialogBaseButton> member where KDialogBaseButton is only forward
> declarated. Unfortunately, it's real declaration is in kdialobase_priv.h
> :(

Well, the quick (and only?) fix would be to include the kdialogbase_priv.h in
kdiaologbase.h then, especially if this will happen for every file that includes
kdialogbase.h. l'll guess passdlg.cpp is nothing special so the above warning
will happen for every class that use KDialogBase

Perhaps we should rather make the KDialogBaseButton an internal class in 
KDialogBase.

-- 
Espen Sand

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

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