summaryrefslogtreecommitdiffstats
path: root/languages/cpp/cppcodecompletion.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'languages/cpp/cppcodecompletion.cpp')
-rw-r--r--languages/cpp/cppcodecompletion.cpp209
1 files changed, 105 insertions, 104 deletions
diff --git a/languages/cpp/cppcodecompletion.cpp b/languages/cpp/cppcodecompletion.cpp
index 2e1e67f2..d09602c0 100644
--- a/languages/cpp/cppcodecompletion.cpp
+++ b/languages/cpp/cppcodecompletion.cpp
@@ -358,7 +358,7 @@ struct PopupFillerHelpStruct {
memType = "enum";
TQString txt = i18n( "Jump to %1 %2" ).arg( memType ).arg( cleanForMenu( d.name ) );
- int id = parent->insertItem( txt, receiver, TQT_SLOT( popupAction( int ) ) );
+ int id = parent->insertItem( txt, receiver, TQ_SLOT( popupAction( int ) ) );
receiver->m_popupActions.insert( id, d.decl );
}
@@ -448,12 +448,12 @@ struct PopupFillerHelpStruct {
}
}
- int id = parent->insertItem( txt1, receiver, TQT_SLOT( popupAction( int ) ) );
+ int id = parent->insertItem( txt1, receiver, TQ_SLOT( popupAction( int ) ) );
if ( d.resolved() )
receiver->m_popupActions.insert( id, d.resolved() ->getDeclarationInfo() );
if ( !txt2.isEmpty() ) {
- int id2 = parent->insertItem( txt2, receiver, TQT_SLOT( popupDefinitionAction( int ) ) );
+ int id2 = parent->insertItem( txt2, receiver, TQ_SLOT( popupDefinitionAction( int ) ) );
if ( d.resolved() )
receiver->m_popupDefinitionActions.insert( id2, d.resolved() ->getDeclarationInfo() );
}
@@ -538,7 +538,7 @@ struct PopupClassViewFillerHelpStruct {
memType = "enum";
TQString txt = i18n( "Show %1 %2" ).arg( memType ).arg( cleanForMenu( d.name ) );
- int id = parent->insertItem( txt, receiver, TQT_SLOT( popupClassViewAction( int ) ) );
+ int id = parent->insertItem( txt, receiver, TQ_SLOT( popupClassViewAction( int ) ) );
receiver->m_popupClassViewActions.insert( id, dom );
}
@@ -597,7 +597,7 @@ struct PopupClassViewFillerHelpStruct {
}
}
- int id = parent->insertItem( txt, receiver, TQT_SLOT( popupClassViewAction( int ) ) );
+ int id = parent->insertItem( txt, receiver, TQ_SLOT( popupClassViewAction( int ) ) );
if ( dom )
receiver->m_popupClassViewActions.insert( id, dom );
@@ -645,7 +645,7 @@ class PopupFiller {
//kdDebug( 9007 ) << "found include-file \"" << includeFile << "\"" << endl;
}
- int id = parent->insertItem( i18n( "#include \"%1\" ( defines %2 )" ).arg ( includeFile ).arg( decl.name ), struk.receiver, TQT_SLOT( popupAction( int ) ) );
+ int id = parent->insertItem( i18n( "#include \"%1\" ( defines %2 )" ).arg ( includeFile ).arg( decl.name ), struk.receiver, TQ_SLOT( popupAction( int ) ) );
DeclarationInfo fakeDec;
fakeDec.name = decl.name;
fakeDec.file = includeFile;
@@ -671,7 +671,7 @@ class PopupFiller {
f.type = d.desc();
f.memberType = SimpleTypeImpl::MemberInfo::Variable;
- /*int id = m->insertItem( i18n("jump to variable-declaration \"%1\"").arg( type.sourceVariable.name ) , this, TQT_SLOT( popupAction( int ) ) );
+ /*int id = m->insertItem( i18n("jump to variable-declaration \"%1\"").arg( type.sourceVariable.name ) , this, TQ_SLOT( popupAction( int ) ) );
m_popupActions.insert( id, type.sourceVariable );*/
struk.insertItem( parent, f, prefix );
@@ -683,7 +683,7 @@ class PopupFiller {
parent->insertItem( i18n( "Comment on %1" ).arg( sourceVariable.name ), m );
TQStringList ls = prepareTextForMenu( sourceVariable.comment, 15, 100 );
for ( TQStringList::iterator it = ls.begin(); it != ls.end(); ++it ) {
- m->insertItem( *it, 0, TQT_SLOT( popupClassViewAction( int ) ) );
+ m->insertItem( *it, 0, TQ_SLOT( popupClassViewAction( int ) ) );
}
parent->insertSeparator();
}
@@ -764,7 +764,7 @@ class PopupFiller {
mo->insertItem( i18n( "Comment" ), m );
TQStringList ls = prepareTextForMenu( ( *it ).first.decl.comment, 15, 100 );
for ( TQStringList::iterator it = ls.begin(); it != ls.end(); ++it ) {
- m->insertItem( *it, 0, TQT_SLOT( popupClassViewAction( int ) ) );
+ m->insertItem( *it, 0, TQ_SLOT( popupClassViewAction( int ) ) );
}
}
@@ -796,7 +796,7 @@ class PopupFiller {
parent->insertItem( i18n( "Comment on %1" ).arg( cleanForMenu( d->name() ) ), m );
TQStringList ls = prepareTextForMenu( d->resolved() ->comment(), 15, 100 );
for ( TQStringList::iterator it = ls.begin(); it != ls.end(); ++it ) {
- m->insertItem( *it, 0, TQT_SLOT( popupClassViewAction( int ) ) );
+ m->insertItem( *it, 0, TQ_SLOT( popupClassViewAction( int ) ) );
}
}
}
@@ -856,14 +856,14 @@ struct CppCodeCompletionData {
if ( recoveryPoints.count() == 0 )
return 0;
- TQPair<int, int> pt = tqMakePair( line, column );
+ TQPair<int, int> pt = qMakePair( line, column );
TQPtrListIterator<RecoveryPoint> it( recoveryPoints );
RecoveryPoint* recPt = 0;
while ( it.current() ) {
- TQPair<int, int> startPt = tqMakePair( it.current() ->startLine, it.current() ->startColumn );
- TQPair<int, int> endPt = tqMakePair( it.current() ->endLine, it.current() ->endColumn );
+ TQPair<int, int> startPt = qMakePair( it.current() ->startLine, it.current() ->startColumn );
+ TQPair<int, int> endPt = qMakePair( it.current() ->endLine, it.current() ->endColumn );
if ( pt < startPt ) {
break;
@@ -896,7 +896,7 @@ m_codeCompleteCh2Rx( "(->)|(\\:\\:)" ) {
m_pSupport = part;
- connect( m_pSupport->codeCompletionConfig(), TQT_SIGNAL( stored() ), this, TQT_SLOT( emptyCache() ) );
+ connect( m_pSupport->codeCompletionConfig(), TQ_SIGNAL( stored() ), this, TQ_SLOT( emptyCache() ) );
m_activeCursor = 0;
m_activeEditor = 0;
@@ -908,17 +908,17 @@ m_codeCompleteCh2Rx( "(->)|(\\:\\:)" ) {
m_ccLine = 0;
m_ccColumn = 0;
- connect( m_ccTimer, TQT_SIGNAL( timeout() ), this, TQT_SLOT( slotTimeout() ) );
- connect( m_showStatusTextTimer, TQT_SIGNAL( timeout() ), this, TQT_SLOT( slotStatusTextTimeout() ) );
+ connect( m_ccTimer, TQ_SIGNAL( timeout() ), this, TQ_SLOT( slotTimeout() ) );
+ connect( m_showStatusTextTimer, TQ_SIGNAL( timeout() ), this, TQ_SLOT( slotStatusTextTimeout() ) );
computeFileEntryList();
CppSupportPart* cppSupport = m_pSupport;
- connect( cppSupport->project(), TQT_SIGNAL( addedFilesToProject( const TQStringList& ) ),
- this, TQT_SLOT( computeFileEntryList() ) );
- connect( cppSupport->project(), TQT_SIGNAL( removedFilesFromProject( const TQStringList& ) ),
- this, TQT_SLOT( computeFileEntryList() ) );
- connect( cppSupport, TQT_SIGNAL( synchronousParseReady( const TQString&, ParsedFilePointer ) ), this, TQT_SLOT( synchronousParseReady( const TQString&, ParsedFilePointer ) ) );
+ connect( cppSupport->project(), TQ_SIGNAL( addedFilesToProject( const TQStringList& ) ),
+ this, TQ_SLOT( computeFileEntryList() ) );
+ connect( cppSupport->project(), TQ_SIGNAL( removedFilesFromProject( const TQStringList& ) ),
+ this, TQ_SLOT( computeFileEntryList() ) );
+ connect( cppSupport, TQ_SIGNAL( synchronousParseReady( const TQString&, ParsedFilePointer ) ), this, TQ_SLOT( synchronousParseReady( const TQString&, ParsedFilePointer ) ) );
m_bArgHintShow = false;
m_bCompletionBoxShow = false;
@@ -928,9 +928,9 @@ m_codeCompleteCh2Rx( "(->)|(\\:\\:)" ) {
m_repository = new CodeInformationRepository( cppSupport->codeRepository() );
- connect( cppSupport->codeRepository(), TQT_SIGNAL(catalogRegistered( Catalog* )), this, TQT_SLOT( emptyCache() ) );
- connect( cppSupport->codeRepository(), TQT_SIGNAL(catalogUnregistered( Catalog* )), this, TQT_SLOT( emptyCache() ) );
- connect( cppSupport->codeRepository(), TQT_SIGNAL(catalogChanged( Catalog* )), this, TQT_SLOT( emptyCache() ) );
+ connect( cppSupport->codeRepository(), TQ_SIGNAL(catalogRegistered( Catalog* )), this, TQ_SLOT( emptyCache() ) );
+ connect( cppSupport->codeRepository(), TQ_SIGNAL(catalogUnregistered( Catalog* )), this, TQ_SLOT( emptyCache() ) );
+ connect( cppSupport->codeRepository(), TQ_SIGNAL(catalogChanged( Catalog* )), this, TQ_SLOT( emptyCache() ) );
setupCodeInformationRepository();
@@ -945,22 +945,22 @@ m_codeCompleteCh2Rx( "(->)|(\\:\\:)" ) {
if ( part->partController() ->activePart() )
slotActivePartChanged( part->partController() ->activePart() );
- connect( part->partController( ), TQT_SIGNAL( partAdded( KParts::Part* ) ),
- this, TQT_SLOT( slotPartAdded( KParts::Part* ) ) );
- connect( part->partController( ), TQT_SIGNAL( activePartChanged( KParts::Part* ) ),
- this, TQT_SLOT( slotActivePartChanged( KParts::Part* ) ) );
+ connect( part->partController( ), TQ_SIGNAL( partAdded( KParts::Part* ) ),
+ this, TQ_SLOT( slotPartAdded( KParts::Part* ) ) );
+ connect( part->partController( ), TQ_SIGNAL( activePartChanged( KParts::Part* ) ),
+ this, TQ_SLOT( slotActivePartChanged( KParts::Part* ) ) );
- connect( part, TQT_SIGNAL( fileParsed( const TQString& ) ),
- this, TQT_SLOT( slotFileParsed( const TQString& ) ) );
- connect( part, TQT_SIGNAL( codeModelUpdated( const TQString& ) ),
- this, TQT_SLOT( slotCodeModelUpdated( const TQString& ) ) );
+ connect( part, TQ_SIGNAL( fileParsed( const TQString& ) ),
+ this, TQ_SLOT( slotFileParsed( const TQString& ) ) );
+ connect( part, TQ_SIGNAL( codeModelUpdated( const TQString& ) ),
+ this, TQ_SLOT( slotCodeModelUpdated( const TQString& ) ) );
TDEAction * action = new TDEAction( i18n("Jump to declaration under cursor"), 0, CTRL + Key_Comma,
- this, TQT_SLOT(slotJumpToDeclCursorContext()), part->actionCollection(), "jump_to_declaration_cursor_context" );
+ this, TQ_SLOT(slotJumpToDeclCursorContext()), part->actionCollection(), "jump_to_declaration_cursor_context" );
action->plug( &m_DummyActionWidget );
action = new TDEAction( i18n("Jump to definition under cursor"), 0, CTRL + Key_Period,
- this, TQT_SLOT(slotJumpToDefCursorContext()), part->actionCollection(), "jump_to_defintion_cursor_context" );
+ this, TQ_SLOT(slotJumpToDefCursorContext()), part->actionCollection(), "jump_to_defintion_cursor_context" );
action->plug( &m_DummyActionWidget );
}
@@ -1028,13 +1028,13 @@ void CppCodeCompletion::integratePart( KParts::Part * part ) {
if ( m_pSupport ) { //The slot should connected even when automatic completion is disabled, so it can be enabled any time
kdDebug( 9007 ) << k_funcinfo << "enabling code completion" << endl;
- connect( part, TQT_SIGNAL( textChanged() ), this, TQT_SLOT( slotTextChanged() ) );
- connect( part->widget(), TQT_SIGNAL( completionDone() ), this,
- TQT_SLOT( slotCompletionBoxHidden() ) );
- connect( part->widget(), TQT_SIGNAL( completionAborted() ), this,
- TQT_SLOT( slotCompletionBoxHidden() ) );
- connect( part->widget(), TQT_SIGNAL( argHintHidden() ), this,
- TQT_SLOT( slotArgHintHidden() ) );
+ connect( part, TQ_SIGNAL( textChanged() ), this, TQ_SLOT( slotTextChanged() ) );
+ connect( part->widget(), TQ_SIGNAL( completionDone() ), this,
+ TQ_SLOT( slotCompletionBoxHidden() ) );
+ connect( part->widget(), TQ_SIGNAL( completionAborted() ), this,
+ TQ_SLOT( slotCompletionBoxHidden() ) );
+ connect( part->widget(), TQ_SIGNAL( argHintHidden() ), this,
+ TQ_SLOT( slotArgHintHidden() ) );
}
}
}
@@ -1047,7 +1047,7 @@ void CppCodeCompletion::slotActivePartChanged( KParts::Part * part ) {
emptyCache();
this->d->recoveryPoints.clear();
if ( m_activeHintInterface && m_activeView ) {
- disconnect( m_activeView , TQT_SIGNAL( needTextHint( int, int, TQString & ) ), this, TQT_SLOT( slotTextHint( int, int, TQString& ) ) );
+ disconnect( m_activeView , TQ_SIGNAL( needTextHint( int, int, TQString & ) ), this, TQ_SLOT( slotTextHint( int, int, TQString& ) ) );
m_activeHintInterface = 0;
}
@@ -1094,7 +1094,7 @@ void CppCodeCompletion::slotActivePartChanged( KParts::Part * part ) {
if ( m_activeHintInterface ) {
#ifndef DISABLETOOLTIPS
m_activeHintInterface->enableTextHints( 500 );
- connect( m_activeView, TQT_SIGNAL( needTextHint( int, int, TQString & ) ), this, TQT_SLOT( slotTextHint( int, int, TQString& ) ) );
+ connect( m_activeView, TQ_SIGNAL( needTextHint( int, int, TQString & ) ), this, TQ_SLOT( slotTextHint( int, int, TQString& ) ) );
#endif
} else {
@@ -1537,7 +1537,7 @@ void CppCodeCompletion::contextEvaluationMenus ( TQPopupMenu *popup, const Conte
else
gid = popup->insertItem( i18n( "Navigate by Macro \"%1\"" ).arg( cleanForMenu( type.macro.name() ) ), m );
- int id = m->insertItem( i18n( "Jump to %1" ).arg( cleanForMenu( type.macro.name() ) ), this, TQT_SLOT( popupAction( int ) ) );
+ int id = m->insertItem( i18n( "Jump to %1" ).arg( cleanForMenu( type.macro.name() ) ), this, TQ_SLOT( popupAction( int ) ) );
TQPopupMenu * b = PopupTracker::createPopup( m );
m->insertItem( i18n( "Body" ), b );
@@ -1551,7 +1551,7 @@ void CppCodeCompletion::contextEvaluationMenus ( TQPopupMenu *popup, const Conte
TQStringList ls = prepareTextForMenu( type.macro.body(), 20, 100 );
for ( TQStringList::iterator it = ls.begin(); it != ls.end(); ++it ) {
- b->insertItem( *it, 0, TQT_SLOT( popupClassViewAction( int ) ) );
+ b->insertItem( *it, 0, TQ_SLOT( popupClassViewAction( int ) ) );
}
}
@@ -1569,7 +1569,7 @@ void CppCodeCompletion::contextEvaluationMenus ( TQPopupMenu *popup, const Conte
else
gid = popup->insertItem( i18n( "Goto Include File: %1" ).arg( cleanForMenu( includeFileName ) ), m );
- int id = m->insertItem( i18n( "Jump to %1" ).arg( cleanForMenu( includeFilePath ) ), this, TQT_SLOT( popupAction( int ) ) );
+ int id = m->insertItem( i18n( "Jump to %1" ).arg( cleanForMenu( includeFilePath ) ), this, TQ_SLOT( popupAction( int ) ) );
DeclarationInfo i;
i.file = includeFilePath;
@@ -1617,7 +1617,7 @@ void CppCodeCompletion::contextEvaluationMenus ( TQPopupMenu *popup, const Conte
popup->setWhatsThis( gid, i18n( "<b>Navigation</b><p>Provides a menu to navigate to positions of items that are involved in this expression" ) );
/*if( type.sourceVariable && type.sourceVariable.name != "this" ) {
- int id = m->insertItem( i18n("jump to variable-declaration \"%1\"").arg( type.sourceVariable.name ) , this, TQT_SLOT( popupAction( int ) ) );
+ int id = m->insertItem( i18n("jump to variable-declaration \"%1\"").arg( type.sourceVariable.name ) , this, TQ_SLOT( popupAction( int ) ) );
m_popupActions.insert( id, type.sourceVariable );
}*/
@@ -2050,14 +2050,13 @@ void CppCodeCompletion::needRecoveryPoints() {
if ( this->d->recoveryPoints.isEmpty() ) {
kdDebug( 9007 ) << "missing recovery-points for file " << m_activeFileName << " they have to be computed now" << endl;
- m_pSupport->backgroundParser() ->lock ()
- ;
+ m_pSupport->backgroundParser() ->lock();
std::vector<CppCodeCompletion> vec;
- TranslationUnitAST * ast = *m_pSupport->backgroundParser() ->translationUnit( m_activeFileName );
+ ParsedFilePointer pTransUnit = m_pSupport->backgroundParser() ->translationUnit( m_activeFileName );
m_pSupport->backgroundParser() ->unlock();
- if ( !ast ) {
+ if ( !pTransUnit ) {
kdDebug( 9007 ) << "background-parser is missing the translation-unit. The file needs to be reparsed." << endl;
m_pSupport->parseFileAndDependencies( m_activeFileName, true );
// m_pSupport->mainWindow() ->statusBar() ->message( i18n( "Background-parser is missing the necessary translation-unit. It will be computed, but this completion will fail." ).arg( m_activeFileName ), 2000 );
@@ -2500,8 +2499,8 @@ void CppCodeCompletion::completeText( bool invokedOnDemand /*= false*/ ) {
if ( start_expr != int( contents.length() ) )
expr = contents.mid( start_expr, contents.length() - start_expr ).stripWhiteSpace();
- if ( expr.startsWith( "SIGNAL" ) || expr.startsWith( "SLOT" ) ) {
- m_completionMode = expr.startsWith( "SIGNAL" ) ? SignalCompletion : SlotCompletion;
+ if ( expr.startsWith( "TQ_SIGNAL" ) || expr.startsWith( "TQ_SLOT" ) ) {
+ m_completionMode = expr.startsWith( "TQ_SIGNAL" ) ? SignalCompletion : SlotCompletion;
showArguments = false;
int end_expr = start_expr - 1;
@@ -2684,70 +2683,74 @@ void CppCodeCompletion::completeText( bool invokedOnDemand /*= false*/ ) {
///@todo is all this necessary?
if ( !recoveredDecl.get() && !recoveredTypeSpec.get() ) {
- TranslationUnitAST * ast = *m_pSupport->backgroundParser() ->translationUnit( m_activeFileName );
- if ( AST * node = findNodeAt( ast, line, column ) ) {
- kdDebug( 9007 ) << "------------------- AST FOUND --------------------" << endl;
- kdDebug( 9007 ) << "node-kind = " << nodeTypeToString( node->nodeType() ) << endl;
+ ParsedFilePointer pTransUnit = m_pSupport->backgroundParser() ->translationUnit(m_activeFileName);
+ if (pTransUnit)
+ {
+ TranslationUnitAST *ast = *pTransUnit;
+ if ( AST * node = findNodeAt( ast, line, column ) ) {
+ kdDebug( 9007 ) << "------------------- AST FOUND --------------------" << endl;
+ kdDebug( 9007 ) << "node-kind = " << nodeTypeToString( node->nodeType() ) << endl;
- if ( FunctionDefinitionAST * def = functionDefinition( node ) ) {
- kdDebug( 9007 ) << "------> found a function definition" << endl;
+ if ( FunctionDefinitionAST * def = functionDefinition( node ) ) {
+ kdDebug( 9007 ) << "------> found a function definition" << endl;
- int startLine, startColumn;
- def->getStartPosition( &startLine, &startColumn );
+ int startLine, startColumn;
+ def->getStartPosition( &startLine, &startColumn );
- TQString contents = getText( startLine, startColumn, line, showArguments ? nCol : column );
+ TQString contents = getText( startLine, startColumn, line, showArguments ? nCol : column );
- /// @todo remove code duplication
- int start_expr = expressionAt( contents, contents.length() );
+ /// @todo remove code duplication
+ int start_expr = expressionAt( contents, contents.length() );
- // kdDebug(9007) << "start_expr = " << start_expr << endl;
- if ( start_expr != int( contents.length() ) )
- expr = contents.mid( start_expr, contents.length() - start_expr ).stripWhiteSpace();
+ // kdDebug(9007) << "start_expr = " << start_expr << endl;
+ if ( start_expr != int( contents.length() ) )
+ expr = contents.mid( start_expr, contents.length() - start_expr ).stripWhiteSpace();
- if ( expr.startsWith( "SIGNAL" ) || expr.startsWith( "SLOT" ) ) {
- m_completionMode = expr.startsWith( "SIGNAL" ) ? SignalCompletion : SlotCompletion;
+ if ( expr.startsWith( "TQ_SIGNAL" ) || expr.startsWith( "TQ_SLOT" ) ) {
+ m_completionMode = expr.startsWith( "TQ_SIGNAL" ) ? SignalCompletion : SlotCompletion;
- showArguments = false;
- int end_expr = start_expr - 1;
- while ( end_expr > 0 && contents[ end_expr ].isSpace() )
- --end_expr;
+ showArguments = false;
+ int end_expr = start_expr - 1;
+ while ( end_expr > 0 && contents[ end_expr ].isSpace() )
+ --end_expr;
- if ( contents[ end_expr ] != ',' ) {
- expr = TQString();
+ if ( contents[ end_expr ] != ',' ) {
+ expr = TQString();
+ } else {
+ start_expr = expressionAt( contents, end_expr );
+ expr = contents.mid( start_expr, end_expr - start_expr ).stripWhiteSpace();
+ }
} else {
- start_expr = expressionAt( contents, end_expr );
- expr = contents.mid( start_expr, end_expr - start_expr ).stripWhiteSpace();
- }
- } else {
- int idx = expr.length() - 1;
- while ( expr[ idx ].isLetterOrNumber() || expr[ idx ] == '_' )
- --idx;
-
- if ( idx != int( expr.length() ) - 1 ) {
- ++idx;
- word = expr.mid( idx ).stripWhiteSpace();
- expr = expr.left( idx ).stripWhiteSpace();
+ int idx = expr.length() - 1;
+ while ( expr[ idx ].isLetterOrNumber() || expr[ idx ] == '_' )
+ --idx;
+
+ if ( idx != int( expr.length() ) - 1 ) {
+ ++idx;
+ word = expr.mid( idx ).stripWhiteSpace();
+ expr = expr.left( idx ).stripWhiteSpace();
+ }
}
- }
- ctx = computeContext( def, line, column, startLine, startColumn );
+ ctx = computeContext( def, line, column, startLine, startColumn );
- TQStringList scope;
- scopeOfNode( def, scope );
- this_type = SimpleType( scope, getIncludeFiles() );
+ TQStringList scope;
+ scopeOfNode( def, scope );
+ this_type = SimpleType( scope, getIncludeFiles() );
- if ( scope.size() ) { /*
- SimpleVariable var;
- var.type = scope;
- var.name = "this";
- ctx->add( var );*/
- //kdDebug(9007) << "add variable " << var.name << " with type " << var.type << endl;
- }
+ if ( scope.size() ) { /*
+ SimpleVariable var;
+ var.type = scope;
+ var.name = "this";
+ ctx->add( var );*/
+ //kdDebug(9007) << "add variable " << var.name << " with type " << var.type << endl;
+ }
- ExpressionInfo exp( expr );
- exp.t = ( ExpressionInfo::Type ) ( ExpressionInfo::NormalExpression | ExpressionInfo::TypeExpression );
- type = evaluateExpression( exp, ctx );
+ ExpressionInfo exp( expr );
+ exp.t = ( ExpressionInfo::Type ) ( ExpressionInfo::NormalExpression | ExpressionInfo::TypeExpression );
+ type = evaluateExpression( exp, ctx );
+ }
}
}
}
@@ -4489,5 +4492,3 @@ bool CppCodeCompletion::getIncludeInfo( int line, TQString& includeFileName, TQS
#include "cppcodecompletion.moc"
-//kate: indent-mode csands; tab-width 2; space-indent off;
-